-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathlua-5.3.0-static-mingw.patch
42 lines (37 loc) · 1.5 KB
/
lua-5.3.0-static-mingw.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
diff -ru lua-5.3.0/Makefile lua-5.3.0-fixed/Makefile
--- lua-5.3.0/Makefile 2014-10-29 23:14:41.000000000 +0000
+++ lua-5.3.0-fixed/Makefile 2015-02-16 22:33:22.235524800 +0000
@@ -10,7 +10,7 @@
# so take care if INSTALL_TOP is not an absolute path. See the local target.
# You may want to make INSTALL_LMOD and INSTALL_CMOD consistent with
# LUA_ROOT, LUA_LDIR, and LUA_CDIR in luaconf.h.
-INSTALL_TOP= /usr/local
+INSTALL_TOP= ../../../mingw-w64-x86_64/x86_64-w64-mingw32
INSTALL_BIN= $(INSTALL_TOP)/bin
INSTALL_INC= $(INSTALL_TOP)/include
INSTALL_LIB= $(INSTALL_TOP)/lib
diff -ru lua-5.3.0/src/Makefile lua-5.3.0-fixed/src/Makefile
--- lua-5.3.0/src/Makefile 2015-01-05 16:04:52.000000000 +0000
+++ lua-5.3.0-fixed/src/Makefile 2015-02-16 22:29:11.134106400 +0000
@@ -6,13 +6,14 @@
# Your platform. See PLATS for possible values.
PLAT= none
-CC= gcc -std=gnu99
+CC= ../../../mingw-w64-x86_64/bin/x86_64-w64-mingw32-gcc.exe -std=gnu99
CFLAGS= -O2 -Wall -Wextra -DLUA_COMPAT_5_2 $(SYSCFLAGS) $(MYCFLAGS)
LDFLAGS= $(SYSLDFLAGS) $(MYLDFLAGS)
LIBS= -lm $(SYSLIBS) $(MYLIBS)
-AR= ar rcu
-RANLIB= ranlib
+AR= ../../../mingw-w64-x86_64/bin/x86_64-w64-mingw32-ar.exe rcu
+RANLIB= ../../../mingw-w64-x86_64/bin/x86_64-w64-mingw32-ranlib.exe
+
RM= rm -f
SYSCFLAGS=
@@ -119,7 +120,7 @@
$(MAKE) "LUAC_T=luac.exe" luac.exe
posix:
- $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_POSIX"
+ $(MAKE) $(ALL) # SYSCFLAGS="-DLUA_USE_POSIX"
solaris:
$(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_POSIX -DLUA_USE_DLOPEN -D_REENTRANT" SYSLIBS="-ldl"