File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed
Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ local arch = defined.arch
1010local LUAJIT_ENABLE_LUA52COMPAT = defined .LUAJIT_ENABLE_LUA52COMPAT
1111local LUAJIT_NUMMODE = defined .LUAJIT_NUMMODE
1212local luajitDir = defined .luajitDir
13+ local is_old_version_luajit = defined .is_old_version_luajit
1314
1415local LJLIB_C = {
1516 luajitDir .. " /lib_base.c " ,
@@ -144,7 +145,10 @@ lm:executable("luajit/lua") {
144145 " lj_libdef.h" ,
145146 " lj_recdef.h" ,
146147 },
147- deps = has_str_hash and " lj_str_hash.c" ,
148+ deps = {
149+ has_str_hash and " lj_str_hash.c" ,
150+ not is_old_version_luajit and " luajit_h"
151+ },
148152 sources = {
149153 " luajit.c" ,
150154 " lj_*.c" ,
Original file line number Diff line number Diff line change 11local lm = require " luamake"
2- local fs = require ' bee.filesystem'
32
43local luaver = " luajit"
54local luajitDir = ' 3rd/lua/' .. luaver
65local luajitSrcDir = luajitDir .. ' /src'
76local bindir = " publish/runtime/" .. lm .runtime_platform
8- local is_old_version_luajit = fs . exists ( fs . path ( luajitSrcDir ) / ' lj_init.c ' )
7+ local is_old_version_luajit = require " compile.luajit.defined " . is_old_version_luajit
98
109lm :exe " minilua" {
1110 rootdir = luajitDir ,
@@ -181,7 +180,7 @@ lm:shared_library "luajit/luajit" {
181180 " lj_recdef" ,
182181 -- "lj_vmdef",
183182 " lj_folddef" ,
184- " luajit_h" ,
183+ not is_old_version_luajit and " luajit_h" ,
185184 },
186185 defines = {
187186 " _CRT_SECURE_NO_WARNINGS" ,
You can’t perform that action at this time.
0 commit comments