Announce Lua config options with version.
To make it possible to find the right build cross compiler to use with any given firmware.
This commit is contained in:
parent
4c21bd6b9a
commit
8f83693262
|
@ -147,7 +147,7 @@ static int doargs(int argc, char* argv[])
|
|||
}
|
||||
if (version)
|
||||
{
|
||||
printf("%s %s\n",LUA_RELEASE,LUA_COPYRIGHT);
|
||||
printf("%s %s [%s]\n",LUA_RELEASE,LUA_COPYRIGHT,XLUA_OPT_STR);
|
||||
if (version==argc-1) exit(EXIT_SUCCESS);
|
||||
}
|
||||
return i;
|
||||
|
|
|
@ -875,4 +875,10 @@ union luai_Cast { double l_d; long l_l; };
|
|||
|
||||
#define LUA_DEBUG_HOOK lua_debugbreak
|
||||
|
||||
#if defined(CONFIG_LUA_NUMBER_INTEGRAL)
|
||||
# define XLUA_OPT_STR "5.1-integral"
|
||||
#else
|
||||
# define XLUA_OPT_STR "5.1-doublefp"
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
@ -161,7 +161,7 @@ static int doargs(int argc, char *argv[]) {
|
|||
argv[--i] = Output;
|
||||
}
|
||||
if (version) {
|
||||
printf("%s\n", LUA_COPYRIGHT);
|
||||
printf("%s [%s]\n", LUA_COPYRIGHT, XLUA_OPT_STR);
|
||||
if (version == argc - 1) exit(EXIT_SUCCESS);
|
||||
}
|
||||
return i;
|
||||
|
|
|
@ -244,8 +244,8 @@ static int pmain (lua_State *L) {
|
|||
print_version(L);
|
||||
}
|
||||
#else
|
||||
printf("\n%s build %s powered by %s on IDF %s\n",
|
||||
NODE_VERSION, BUILD_DATE, LUA_RELEASE, IDF_VER);
|
||||
printf("\n%s build %s powered by %s [%s] on IDF %s\n",
|
||||
NODE_VERSION, BUILD_DATE, LUA_RELEASE, XLUA_OPT_STR, IDF_VER);
|
||||
#endif
|
||||
/*
|
||||
* And last of all, kick off application initialisation. Note that if
|
||||
|
|
|
@ -441,4 +441,16 @@
|
|||
|
||||
#define LUA_DEBUG_HOOK lua_debugbreak
|
||||
|
||||
#if defined(CONFIG_LUA_NUMBER_INT64)
|
||||
# define XLUA_INT_OPT "int64"
|
||||
#else
|
||||
# define XLUA_INT_OPT "int32"
|
||||
#endif
|
||||
#if defined(CONFIG_LUA_NUMBER_DOUBLE)
|
||||
# define XLUA_FLOAT_OPT "doublefp"
|
||||
#else
|
||||
# define XLUA_FLOAT_OPT "singlefp"
|
||||
#endif
|
||||
#define XLUA_OPT_STR "5.3-" XLUA_INT_OPT "-" XLUA_FLOAT_OPT
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue