• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

patch投げ用


Commit MetaInfo

修订版2e868295eec14536354e0dddf7e84ce117b3dc42 (tree)
时间2016-02-14 01:46:48
作者SHIRAKATA Kentaro <argrath@ub32...>
CommiterSHIRAKATA Kentaro

Log Message

patch makedefs.c (no -j)

更改概述

差异

--- a/util/makedefs.c
+++ b/util/makedefs.c
@@ -25,8 +25,14 @@
2525 /* version information */
2626 #ifdef SHORT_FILENAMES
2727 #include "patchlev.h"
28+#if 1 /*JP*/
29+#include "../japanese/jpatchle.h"
30+#endif
2831 #else
2932 #include "patchlevel.h"
33+#if 1 /*JP*/
34+#include "../japanese/jpatchlevel.h"
35+#endif
3036 #endif
3137
3238 #include <ctype.h>
@@ -1188,6 +1194,25 @@ const char *build_date;
11881194 return outbuf;
11891195 }
11901196
1197+#if 1 /*JP*/
1198+static char *
1199+jversion_id_string(outbuf, build_date)
1200+char *outbuf;
1201+const char *build_date;
1202+{
1203+ char subbuf[64], versbuf[64];
1204+
1205+ subbuf[0] = '\0';
1206+#ifdef BETA
1207+ Strcat(subbuf, " Beta");
1208+#endif
1209+
1210+ Sprintf(outbuf, "%s JNetHack%s Version %s-%d.%d.", PORT_ID,
1211+ subbuf, version_string(versbuf, "."), JVERSION_MAJOR, JVERSION_MINOR);
1212+ return outbuf;
1213+}
1214+#endif
1215+
11911216 static char *
11921217 bannerc_string(outbuf, build_date)
11931218 char *outbuf;
@@ -1276,6 +1301,10 @@ do_date()
12761301 Fprintf(ofp, "#define VERSION_STRING \"%s\"\n", version_string(buf, "."));
12771302 Fprintf(ofp, "#define VERSION_ID \\\n \"%s\"\n",
12781303 version_id_string(buf, cbuf));
1304+#if 1 /*JP*/
1305+ Fprintf(ofp,"#define JVERSION_ID \\\n \"%s\"\n",
1306+ jversion_id_string(buf, cbuf));
1307+#endif
12791308 Fprintf(ofp, "#define COPYRIGHT_BANNER_C \\\n \"%s\"\n",
12801309 bannerc_string(buf, cbuf));
12811310 Fprintf(ofp, "\n");
@@ -1660,11 +1689,18 @@ do_data()
16601689 entry_cnt = line_cnt = 0;
16611690 /* read through the input file and split it into two sections */
16621691 while ((line = fgetline(ifp)) != 0) {
1692+#if 0 /*JP*/
16631693 if (d_filter(line)) {
16641694 free(line);
16651695 continue;
16661696 }
16671697 if (*line > ' ') { /* got an entry name */
1698+#else
1699+ unsigned char uc;
1700+ uc = *((unsigned char *)line);
1701+ if (d_filter(line)) continue;
1702+ if (uc > ' ') { /* got an entry name */
1703+#endif
16681704 /* first finish previous entry */
16691705 if (line_cnt)
16701706 Fprintf(ofp, "%d\n", line_cnt), line_cnt = 0;
@@ -1753,6 +1789,7 @@ char *line;
17531789 }
17541790
17551791 static const char *special_oracle[] = {
1792+#if 0 /*JP*/
17561793 "\"...it is rather disconcerting to be confronted with the",
17571794 "following theorem from [Baker, Gill, and Solovay, 1975].", "",
17581795 "Theorem 7.18 There exist recursive languages A and B such that",
@@ -1761,6 +1798,18 @@ static const char *special_oracle[] = {
17611798 "currently available will not suffice for proving that P != NP or "
17621799 " ",
17631800 "that P == NP.\" [Garey and Johnson, p. 185.]"
1801+#else
1802+ "「次の定理[Baker, Gill, and Solovay, 1975]に直面することは",
1803+ "むしろ困惑することである.",
1804+ "",
1805+ "定理 7.18 次のような再帰的言語 A,Bが存在する",
1806+ " (1) P(A) == NP(A),かつ",
1807+ " (2) P(B) != NP(B)",
1808+ "",
1809+ "これは現在 P != NPであるかまたは P == NPであるかを証明する",
1810+ "有効な手法がないことを強く示している.」",
1811+ "[Garey and Johnson, p. 185.]"
1812+#endif
17641813 };
17651814
17661815 /*