aports/main/lua-socket/lua-cflags.patch
Michael Zuo 11949c7567 main/lua-socket: cleanup and upgrade to latest git
Fast-forward to pick up fixes since last release, remove patches that no longer
apply, and clean up APKBUILD to closer to the current style.
2016-04-06 19:57:34 +00:00

23 lines
769 B
Diff

diff --git a/src/makefile b/src/makefile
index adf687f..c2abddc 100644
--- a/src/makefile
+++ b/src/makefile
@@ -160,6 +160,8 @@ SOCKET_macosx=usocket.o
#------
# Compiler and linker settings
# for Linux
+LUAPC=lua$(LUAV)
+LUA_CFLAGS=$(shell pkg-config --cflags $(LUAPC))
SO_linux=so
O_linux=o
CC_linux=gcc
@@ -167,7 +169,7 @@ DEF_linux=-DLUASOCKET_$(DEBUG) \
-DLUASOCKET_API='__attribute__((visibility("default")))' \
-DUNIX_API='__attribute__((visibility("default")))' \
-DMIME_API='__attribute__((visibility("default")))'
-CFLAGS_linux= -I$(LUAINC) $(DEF) -Wall -Wshadow -Wextra \
+CFLAGS_linux= $(LUA_CFLAGS) -I$(LUAINC) $(DEF) -Wall -Wshadow -Wextra \
-Wimplicit -O2 -ggdb3 -fpic -fvisibility=hidden
LDFLAGS_linux=-O -shared -fpic -o
LD_linux=gcc