summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAkira Kakuto <kakuto@fuk.kindai.ac.jp>2014-02-04 07:48:55 +0000
committerAkira Kakuto <kakuto@fuk.kindai.ac.jp>2014-02-04 07:48:55 +0000
commit2bc219951a857706b1b0f9806d1f14728766fcba (patch)
tree3ad93eae40638ff10d10c37d57c5a3fe1b1bb6f9
parent325fd329350182b8035210b8a457c8aeb1ad386e (diff)
Change a little for luajittex
git-svn-id: svn://tug.org/texlive/trunk@32869 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Build/source/texk/web2c/luatexdir/ChangeLog4
-rw-r--r--Build/source/texk/web2c/luatexdir/lua/luainit.w17
2 files changed, 20 insertions, 1 deletions
diff --git a/Build/source/texk/web2c/luatexdir/ChangeLog b/Build/source/texk/web2c/luatexdir/ChangeLog
index 9b03742576d..185686e9878 100644
--- a/Build/source/texk/web2c/luatexdir/ChangeLog
+++ b/Build/source/texk/web2c/luatexdir/ChangeLog
@@ -1,3 +1,7 @@
+2014-02-04 Akira Kakuto <kakuto@fuk.kindai.ac.jp>
+
+ * lua/luainit.w: Change a little for LuaJITTeX.
+
2014-02-01 Peter Breitenlohner <peb@mppmu.mpg.de>
Import LuaTeX snapshot 0.78.3 from LuaTeX repository (r4772).
diff --git a/Build/source/texk/web2c/luatexdir/lua/luainit.w b/Build/source/texk/web2c/luatexdir/lua/luainit.w
index 60ec5cc5672..a65ae045f14 100644
--- a/Build/source/texk/web2c/luatexdir/lua/luainit.w
+++ b/Build/source/texk/web2c/luatexdir/lua/luainit.w
@@ -90,7 +90,11 @@ const_string LUATEX_IHELP[] = {
" --fmt=FORMAT load the format file FORMAT",
" --halt-on-error stop processing at the first error",
" --help display help and exit",
+#ifdef LuajitTeX
+ " --ini be iniluajittex, for dumping formats",
+#else
" --ini be iniluatex, for dumping formats",
+#endif
" --interaction=STRING set interaction mode (STRING=batchmode/nonstopmode/scrollmode/errorstopmode)",
" --jobname=STRING set the job name to STRING",
" --kpathsea-debug=NUMBER set path searching debugging flags according to the bits of NUMBER",
@@ -259,8 +263,13 @@ static void parse_options(int ac, char **av)
int option_index;
char *firstfile = NULL;
opterr = 0; /* dont whine */
+#ifdef LuajitTeX
+ if ((strstr(argv[0], "luajittexlua") != NULL) ||
+ (strstr(argv[0], "texluajit") != NULL)) {
+#else
if ((strstr(argv[0], "luatexlua") != NULL) ||
(strstr(argv[0], "texlua") != NULL)) {
+#endif
lua_only = 1;
luainit = 1;
}
@@ -811,7 +820,11 @@ void lua_initialize(int ac, char **av)
static char LC_CTYPE_C[] = "LC_CTYPE=C";
static char LC_COLLATE_C[] = "LC_COLLATE=C";
static char LC_NUMERIC_C[] = "LC_NUMERIC=C";
+#ifdef LuajitTeX
+ static char engine_luatex[] = "engine=luajittex";
+#else
static char engine_luatex[] = "engine=luatex";
+#endif
/* Save to pass along to topenin. */
argc = ac;
argv = av;
@@ -849,7 +862,9 @@ void lua_initialize(int ac, char **av)
if (FILESTRCASEEQ(kpse_invocation_name, "texluajitc"))
exit(luac_main(ac, av));
if (STREQ(argv[1], "--luaconly") || STREQ(argv[1], "--luac")) {
- strcpy(av[1], "luajittex");
+ char *argv1 = xmalloc (strlen ("luajittex") + 1);
+ av[1] = argv1;
+ strcpy (av[1], "luajittex");
exit(luac_main(--ac, ++av));
}
#else