diff options
author | pav <pav@FreeBSD.org> | 2005-09-18 06:48:49 +0800 |
---|---|---|
committer | pav <pav@FreeBSD.org> | 2005-09-18 06:48:49 +0800 |
commit | 228721ec33215d5016a18a19489720b00f2b09eb (patch) | |
tree | f938329e8fecd5650ca6b51e353c40b59b0f4a0c /games/xshisen/files | |
parent | 751eb23f126970fc569669f7369f626b07e1a06f (diff) | |
download | freebsd-ports-gnome-228721ec33215d5016a18a19489720b00f2b09eb.tar.gz freebsd-ports-gnome-228721ec33215d5016a18a19489720b00f2b09eb.tar.zst freebsd-ports-gnome-228721ec33215d5016a18a19489720b00f2b09eb.zip |
- Update to 1.51
PR: ports/86269
Submitted by: Ports Fury
Diffstat (limited to 'games/xshisen/files')
-rw-r--r-- | games/xshisen/files/patch-aa | 11 | ||||
-rw-r--r-- | games/xshisen/files/patch-ac | 21 | ||||
-rw-r--r-- | games/xshisen/files/patch-ad | 95 | ||||
-rw-r--r-- | games/xshisen/files/patch-ae | 11 | ||||
-rw-r--r-- | games/xshisen/files/patch-af | 159 | ||||
-rw-r--r-- | games/xshisen/files/patch-readxpm.C | 8 |
6 files changed, 4 insertions, 301 deletions
diff --git a/games/xshisen/files/patch-aa b/games/xshisen/files/patch-aa deleted file mode 100644 index d3ed5829c04a..000000000000 --- a/games/xshisen/files/patch-aa +++ /dev/null @@ -1,11 +0,0 @@ ---- configure.orig Tue Feb 27 21:29:29 1996 -+++ configure Sun Oct 10 17:49:35 1999 -@@ -1593,7 +1593,7 @@ - CPPFLAGS="${CPPFLAGS} -DLIB_DIR=\\\"\$(XSHISENLIB)\\\"" - - for i in ${mandir} /usr/share/man /usr/man /usr/local/man; do -- for j in japanese japan ja ja_JP ja_JP.eucJP ja_JP.SJIS; do -+ for j in a_JP.EUC ja_JP.SJIS ja_JP.JIS7; do - if [ -d "$i/$j" ]; then - JAPANESE="$j" - break 2; diff --git a/games/xshisen/files/patch-ac b/games/xshisen/files/patch-ac deleted file mode 100644 index 35bc8ad44e80..000000000000 --- a/games/xshisen/files/patch-ac +++ /dev/null @@ -1,21 +0,0 @@ ---- Makefile.in.orig Tue Jan 23 17:35:21 1996 -+++ Makefile.in Sat Nov 9 17:18:47 2002 -@@ -39,7 +39,7 @@ - SCF = xshisen-scores - - LIBS = @LIBS@ --CODECONV = ./$(exec_name) -KCONV jis -+CODECONV = (nkf -e | sed 's/XSHISEN_VERSION/1.36/') - - all: $(PROGS) - -@@ -64,6 +64,9 @@ - $(INSTALLD) $$file $(XSHISENLIB)/`basename $$file`; \ - done - $(INSTALLD) $(AD) $(XAD_DIR)/$(class_name) -+ @if [ ! -f $(JXAD_DIR) ]; then \ -+ $(MKDIR) $(JXAD_DIR); \ -+ fi - $(INSTALLD) $(ADJ) $(JXAD_DIR)/$(class_name) - - install.man: $(exec_name).jman $(exec_name).man diff --git a/games/xshisen/files/patch-ad b/games/xshisen/files/patch-ad deleted file mode 100644 index c7d1cbea043c..000000000000 --- a/games/xshisen/files/patch-ad +++ /dev/null @@ -1,95 +0,0 @@ - -$FreeBSD$ - ---- main.C.orig -+++ main.C -@@ -44,53 +44,53 @@ - - static XtResource gres[] = { - { "aboutString", "AboutString", XtRString, sizeof (char *), -- 0, XtRString, "XShisen " XSHISEN_VERSION " by Masaoki Kobayashi" }, -+ 0, XtRString, (XtPointer)"XShisen " XSHISEN_VERSION " by Masaoki Kobayashi" }, - { "tedumari", "Tedumari", XtRString, sizeof (char *), -- offsetof(GlobRes, tedumari), XtRString, "You can get no more pieces." }, -+ offsetof(GlobRes, tedumari), XtRString, (XtPointer)"You can get no more pieces." }, - { "width", "Width", XtRInt, sizeof (int), -- offsetof(GlobRes, Width), XtRString, "640" }, -+ offsetof(GlobRes, Width), XtRString, (XtPointer)"640" }, - { "height", "Height", XtRInt, sizeof (int), -- offsetof(GlobRes, Height), XtRString, "400" }, -+ offsetof(GlobRes, Height), XtRString, (XtPointer)"400" }, - { "timeFormat", "TimeFormat", XtRString, sizeof (char *), -- offsetof(GlobRes, timeFormat), XtRString, "Your time is %2.2d:%2.2d." }, -+ offsetof(GlobRes, timeFormat), XtRString, (XtPointer)"Your time is %2.2d:%2.2d." }, - { "displayFormat1", "DisplayFormat1", XtRString, sizeof (char *), -- offsetof(GlobRes, displayFormat1), XtRString, "Rest: " }, -+ offsetof(GlobRes, displayFormat1), XtRString, (XtPointer)"Rest: " }, - { "displayFormat2", "DisplayFormat2", XtRString, sizeof (char *), -- offsetof(GlobRes, displayFormat2), XtRString, "Time: " }, -+ offsetof(GlobRes, displayFormat2), XtRString, (XtPointer)"Time: " }, - { "scoreFile", "ScoreFile", XtRString, sizeof (char *), -- offsetof(GlobRes, scoreFile), XtRString, "%s/xshisen-scores" }, -+ offsetof(GlobRes, scoreFile), XtRString, (XtPointer)"%s/xshisen-scores" }, - { "personalScore", "PersonalScore", XtRString, sizeof (char *), -- offsetof(GlobRes, personalScoreFile), XtRString, ".xshisen-scores" }, -+ offsetof(GlobRes, personalScoreFile), XtRString, (XtPointer)".xshisen-scores" }, - { "scoreOnly", "ScoreOnly", XtRBoolean, sizeof (Boolean), -- offsetof(GlobRes, scoreOnly), XtRString, "False" }, -+ offsetof(GlobRes, scoreOnly), XtRString, (XtPointer)"False" }, - { "connectLineColor", "ConnectLineColor", XtRPixel, sizeof (Pixel), -- offsetof(GlobRes, connLineColor), XtRString, "blue" }, -+ offsetof(GlobRes, connLineColor), XtRString, (XtPointer)"blue" }, - { "connectLineTime", "ConnectLineTime", XtRInt, sizeof (int), -- offsetof(GlobRes, connLineTime), XtRString, "1000" }, -+ offsetof(GlobRes, connLineTime), XtRString, (XtPointer)"1000" }, - { "connectLineWidth", "ConnectLineWidth", XtRInt, sizeof (int), -- offsetof(GlobRes, connLineWidth), XtRString, "6" }, -+ offsetof(GlobRes, connLineWidth), XtRString, (XtPointer)"6" }, - { "autoDemo", "AutoDemo", XtRBoolean, sizeof (Boolean), -- offsetof(GlobRes, autoDemo), XtRString, "False" }, -+ offsetof(GlobRes, autoDemo), XtRString, (XtPointer)"False" }, - { "libraryDirectory", "LibraryDirectory", XtRString, sizeof (char *), -- offsetof(GlobRes, libDir), XtRString, LIB_DIR }, -+ offsetof(GlobRes, libDir), XtRString, (XtPointer)LIB_DIR }, - { "magnifyFactor", "MagnifyFactor", XtRFloat, sizeof (float), -- offsetof(GlobRes, magFactor), XtRString, "1.0" }, -+ offsetof(GlobRes, magFactor), XtRString, (XtPointer)"1.0" }, - { "fitPixmap", "FitPixmap", XtRBoolean, sizeof (Boolean), -- offsetof(GlobRes, fitPixmap), XtRString, "True" }, -+ offsetof(GlobRes, fitPixmap), XtRString, (XtPointer)"True" }, - { "colorCloseness", "ColorCloseness", XtRInt, sizeof (int), -- offsetof(GlobRes, colorCloseness), XtRString, "40000" }, -+ offsetof(GlobRes, colorCloseness), XtRString, (XtPointer)"40000" }, - { "gameSize", "GameSize", XtRInt, sizeof (int), -- offsetof(GlobRes, gameSize), XtRString, "0" }, -+ offsetof(GlobRes, gameSize), XtRString, (XtPointer)"0" }, - { "trialMode", "TrialMode", XtRBoolean, sizeof (Boolean), -- offsetof(GlobRes, trialMode), XtRString, "False" }, -+ offsetof(GlobRes, trialMode), XtRString, (XtPointer)"False" }, - { "gravityMode", "GravityMode", XtRBoolean, sizeof (Boolean), -- offsetof(GlobRes, gravityMode), XtRString, "False" }, -+ offsetof(GlobRes, gravityMode), XtRString, (XtPointer)"False" }, - { "idleTime", "IdleTime", XtRInt, sizeof (int), -- offsetof(GlobRes, idleTime), XtRString, "100000" }, -+ offsetof(GlobRes, idleTime), XtRString, (XtPointer)"100000" }, - { "kanjiCode", "KanjiCode", XtRString, sizeof (char *), -- offsetof(GlobRes, kanjiCode), XtRString, KANJICODE }, -+ offsetof(GlobRes, kanjiCode), XtRString, (XtPointer)KANJICODE }, - { "kanjiConvert", "KanjiConvert", XtRBoolean, sizeof (Boolean), -- offsetof(GlobRes, kanjiConv), XtRString, "False" } -+ offsetof(GlobRes, kanjiConv), XtRString, (XtPointer)"False" } - }; - GlobRes globRes; - -@@ -194,9 +194,9 @@ - char buffer[100], *p; - char *(*codeconv)(const char*); - -- strcpy(buffer, operation); -+ strlcpy(buffer, operation, sizeof(buffer)); - if (strchr(buffer, '-') == NULL) { -- strcat(buffer, "-" KANJICODE); -+ strlcat(buffer, "-" KANJICODE, sizeof(buffer)); - } - if (strncasecmp(buffer, "jis-euc", 7) == 0) - codeconv = jis_to_euc; diff --git a/games/xshisen/files/patch-ae b/games/xshisen/files/patch-ae deleted file mode 100644 index d8ad11132833..000000000000 --- a/games/xshisen/files/patch-ae +++ /dev/null @@ -1,11 +0,0 @@ ---- body.C.orig Sun Dec 12 14:40:15 1999 -+++ body.C Sun Dec 12 14:40:55 1999 -@@ -224,7 +224,7 @@ - int max_c; - - max_c = xsize*ysize*(xsize*ysize/PKIND - 1)/2; -- p = new (Point [max_c][2]); -+ p = new Point[max_c][2]; - t = new Point[xsize*ysize/PKIND]; - - if (hintNum == 0) diff --git a/games/xshisen/files/patch-af b/games/xshisen/files/patch-af deleted file mode 100644 index 5b4a63af10c3..000000000000 --- a/games/xshisen/files/patch-af +++ /dev/null @@ -1,159 +0,0 @@ - -$FreeBSD$ - ---- score.C.orig -+++ score.C -@@ -4,31 +4,31 @@ - - XtResource Score::resources[] = { - { "scoreTitle", "ScoreTitle", XtRString, sizeof(char *), -- 0*sizeof(char *), XtRString, "XShisen High Score\n\n" }, -+ 0*sizeof(char *), XtRString, (XtPointer)"XShisen High Score\n\n" }, - { "scoreFormat", "ScoreFormat", XtRString, sizeof(char *), -- 1*sizeof(char *), XtRString, "%2d %2.2d:%2.2d:%2.2d %-28s %s %s\n" }, -+ 1*sizeof(char *), XtRString, (XtPointer)"%2d %2.2d:%2.2d:%2.2d %-28s %s %s\n" }, - { "strPeriod", "StrPeriod", XtRString, sizeof(char *), -- 2*sizeof(char *), XtRString, "Last %d days" }, -+ 2*sizeof(char *), XtRString, (XtPointer)"Last %d days" }, - { "averagePeriod", "AveragePeriod", XtRString, sizeof(char *), -- 3*sizeof(char *), XtRString, "14" }, -+ 3*sizeof(char *), XtRString, (XtPointer)"14" }, - { "strPlayed", "StrPlayed", XtRString, sizeof(char *), -- 4*sizeof(char *), XtRString, "Played" }, -+ 4*sizeof(char *), XtRString, (XtPointer)"Played" }, - { "strCompleted", "StrCompleted", XtRString, sizeof(char *), -- 5*sizeof(char *), XtRString, "Completed" }, -+ 5*sizeof(char *), XtRString, (XtPointer)"Completed" }, - { "strTedumari", "StrTedumari", XtRString, sizeof(char *), -- 6*sizeof(char *), XtRString, "Deadlocked" }, -+ 6*sizeof(char *), XtRString, (XtPointer)"Deadlocked" }, - { "strSearched", "StrSearched", XtRString, sizeof(char *), -- 7*sizeof(char *), XtRString, "Seach used" }, -+ 7*sizeof(char *), XtRString, (XtPointer)"Search used" }, - { "strGiveUp", "StrGiveUp", XtRString, sizeof(char *), -- 8*sizeof(char *), XtRString, "Gaven up" }, -+ 8*sizeof(char *), XtRString, (XtPointer)"Given up" }, - { "strTotal", "StrTotal", XtRString, sizeof(char *), -- 9*sizeof(char *), XtRString, "Total" }, -+ 9*sizeof(char *), XtRString, (XtPointer)"Total" }, - { "strAverage", "StrAverage", XtRString, sizeof(char *), -- 10*sizeof(char *), XtRString, "Whole Average" }, -+ 10*sizeof(char *), XtRString, (XtPointer)"Whole Average" }, - { "strGames", "StrGames", XtRString, sizeof(char *), -- 11*sizeof(char *), XtRString, "games" }, -+ 11*sizeof(char *), XtRString, (XtPointer)"games" }, - { "personalTitle", "PersonalTitle", XtRString, sizeof(char *), -- 12*sizeof(char *), XtRString, "Personal Statistics for %s" } -+ 12*sizeof(char *), XtRString, (XtPointer)"Personal Statistics for %s" } - }; - - void -@@ -73,6 +73,12 @@ - date[8] = '\0'; - strncpy(time, &buffer[53], 8); - time[8] = '\0'; -+ if (date[0] == '1') { -+ for(int i=1; i<8; i++) { -+ date[i-1] = date[i]; -+ } -+ date[7] = date[6] == '0' ? '1' : '0'; -+ } - } - - void -@@ -371,10 +377,10 @@ - s1 = scoreToRegister / 1000; - ms_to_hms(scoreToRegister, h, m, s); - pw = getpwuid(getuid()); -- strcpy(gecos, pw->pw_gecos); -+ strlcpy(gecos, pw->pw_gecos, sizeof(gecos)); - if ((po = strchr(gecos, ',')) != NULL) - *po = 0; -- sprintf(namebuf, "%-8.8s (%s)", pw->pw_name, gecos); -+ snprintf(namebuf, sizeof(namebuf), "%-8.8s (%s)", pw->pw_name, gecos); - sprintf(myname, "%-28.28s", namebuf); - // Always read the latest high score - readfile(); -@@ -414,7 +420,7 @@ - strcpy(rec[inspos].name, myname); - time(&t); - tp = localtime(&t); -- sprintf(rec[i].date, "%2.2d-%2.2d-%2.2d", tp->tm_year, tp->tm_mon+1, tp->tm_mday); -+ sprintf(rec[i].date, "%2.2d-%2.2d-%2.2d", tp->tm_year%100, tp->tm_mon+1, tp->tm_mday); - sprintf(rec[i].time, "%2.2d:%2.2d:%2.2d", tp->tm_hour, tp->tm_min, tp->tm_sec); - if (writefile() == 0) - DisplayScore(game); -@@ -434,12 +440,12 @@ - return; /* Just do not record, no notifying */ - time(&t); - tp = localtime(&t); -- check_digit = flag*3 + gamesize + level*7 + tp->tm_year*3 + rest*7 -+ check_digit = flag*3 + gamesize + level*7 + (tp->tm_year%100)*3 + rest*7 - + tp->tm_mon*7 + tp->tm_mday*3 + tp->tm_hour*7 + tp->tm_min*3 + tp->tm_sec; - check_digit %= 857; - fprintf(stream, "%2.2d%2.2d%8.8d%2.2d%1.1d%2.2d%4.4d%2.2d%3.3d%3.3d%2.2d%2.2d\n", - flag, -- tp->tm_sec, result, tp->tm_min, gamesize, tp->tm_year, level, tp->tm_mon, -+ tp->tm_sec, result, tp->tm_min, gamesize, tp->tm_year%100, level, tp->tm_mon, - check_digit, rest, tp->tm_mday, tp->tm_hour); - fclose(stream); - } -@@ -492,7 +498,24 @@ - rest = -1; - c2 = f*3 + g + l*7 + year*3 + month*7 + day*3 + hour*7 + min*3 + sec; - break; -- case 34: -+ case 32: -+ // Just for compatibility with xshisen 1.10, Y2K -+ f = atoiSubstring(buf + 0, 2); -+ sec = atoiSubstring(buf + 2, 2); -+ t = atoiSubstring(buf + 4, 8); -+ min = atoiSubstring(buf + 12, 2); -+ g = atoiSubstring(buf + 14, 1); -+ year = atoiSubstring(buf + 15, 3) - 100; -+ l = atoiSubstring(buf + 18, 4); -+ month = atoiSubstring(buf + 22, 2); -+ c1 = atoiSubstring(buf + 24, 3); -+ day = atoiSubstring(buf + 27, 2); -+ hour = atoiSubstring(buf + 29, 2); -+ rest = -1; -+ c2 = f*3 + g + l*7 + (year+100)*3 + month*7 + day*3 + hour*7 + min*3 + sec -+; -+ break; -+ case 34: - // This is usual format - f = atoiSubstring(buf + 0, 2); - sec = atoiSubstring(buf + 2, 2); -@@ -509,6 +532,23 @@ - c2 = f*3 + g + l*7 + year*3 + month*7 + day*3 + hour*7 + min*3 - + sec + rest*7; - break; -+ case 35: -+ // This is usual format, Y2K -+ f = atoiSubstring(buf + 0, 2); -+ sec = atoiSubstring(buf + 2, 2); -+ t = atoiSubstring(buf + 4, 8); -+ min = atoiSubstring(buf + 12, 2); -+ g = atoiSubstring(buf + 14, 1); -+ year = atoiSubstring(buf + 15, 3) - 100; -+ l = atoiSubstring(buf + 18, 4); -+ month = atoiSubstring(buf + 22, 2); -+ c1 = atoiSubstring(buf + 24, 3); -+ rest = atoiSubstring(buf + 27, 3); -+ day = atoiSubstring(buf + 30, 2); -+ hour = atoiSubstring(buf + 32, 2); -+ c2 = f*3 + g + l*7 + (year+100)*3 + month*7 + day*3 + hour*7 + min*3 -+ + sec + rest*7; -+ break; - default: - // Someone edited this file? - continue; -@@ -537,7 +577,7 @@ - tb.tm_hour = hour; - tb.tm_mday = day; - tb.tm_mon = month; -- tb.tm_year = year; -+ tb.tm_year = year > 69 ? year : year + 100; - tm1 = mktime(&tb); // Time of the score - w1[0][f] += t; - w2[0][f]++; diff --git a/games/xshisen/files/patch-readxpm.C b/games/xshisen/files/patch-readxpm.C index 44bb429475d5..d1ac1540fe1b 100644 --- a/games/xshisen/files/patch-readxpm.C +++ b/games/xshisen/files/patch-readxpm.C @@ -1,14 +1,14 @@ $FreeBSD$ ---- readxpm.C.orig -+++ readxpm.C +--- readxpm.C.orig Sun Jul 7 01:34:47 2002 ++++ readxpm.C Thu Sep 15 13:56:38 2005 @@ -12,7 +12,7 @@ char buffer[1024]; for(int i=0; i<PKIND; i++) { -- sprintf(buffer, "%s/%s.xpm", directory, files[i]); -+ snprintf(buffer, sizeof(buffer), "%s/%s.xpm", directory, files[i]); +- sprintf(buffer, "%s/%s/%s.xpm", directory, subdir, files[i]); ++ snprintf(buffer, sizeof(buffer), "%s/%s/%s.xpm", directory, subdir, files[i]); Mp[i].ReadFile(w, buffer, i, globRes.colorCloseness); } } |