Skip to content

Commit 6340eb8

Browse files
committed
luajit: Enable 5.2 Compat take 2
1 parent be4b87a commit 6340eb8

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
group 'party.iroiro.luajava'
2-
version(System.getenv('IS_RELEASE') == 'true' ? '4.0.2' : '4.0.5-SNAPSHOT')
2+
version(System.getenv('IS_RELEASE') == 'true' ? '4.0.2' : '4.0.6-SNAPSHOT')
33

44

55

luajit/build.gradle

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -104,15 +104,15 @@ void buildLuaTargets(String... targets) {
104104
buildLuaTargets(
105105
addLuaJitTarget(Platform.Linux64,
106106
['make', 'amalg',
107-
'CC=gcc -m64 -D_FORTIFY_SOURCE=0', 'CFLAGS=-fPIC ',
107+
'CC=gcc -m64 -D_FORTIFY_SOURCE=0', 'CFLAGS=-fPIC -DLUAJIT_ENABLE_LUA52COMPAT',
108108
'TARGET_SYS=Linux']),
109109
addLuaJitTarget(Platform.AArch64,
110110
['make', 'amalg',
111-
'HOST_CC=gcc -m64 -D_FORTIFY_SOURCE=0', 'CFLAGS=-fPIC',
111+
'HOST_CC=gcc -m64 -D_FORTIFY_SOURCE=0', 'CFLAGS=-fPIC -DLUAJIT_ENABLE_LUA52COMPAT',
112112
'TARGET_SYS=Linux', 'CROSS=aarch64-linux-gnu-']),
113113
addLuaJitTarget(Platform.Win64,
114114
['make', 'amalg',
115-
'HOST_CC=gcc -m64', 'CFLAGS=-fPIC',
115+
'HOST_CC=gcc -m64', 'CFLAGS=-fPIC -DLUAJIT_ENABLE_LUA52COMPAT',
116116
'BUILDMODE=static',
117117
'CROSS=x86_64-w64-mingw32-', 'TARGET_SYS=Windows'])
118118
)
@@ -136,8 +136,6 @@ jnigen {
136136
cExcludes = ['luajit/**/*']
137137
libraries += ' -lm -lluajit '
138138
headerDirs = ['../../jni/luajava', 'luajit/src', 'mod']
139-
cFlags += ' -DLUAJIT_ENABLE_LUA52COMPAT'
140-
cppFlags += ' -DLUAJIT_ENABLE_LUA52COMPAT'
141139
}
142140

143141
add(Linux, x64, x86, {

0 commit comments

Comments
 (0)