void-packages/srcpkgs/sauerbraten/patches/flags.patch

36 lines
1.1 KiB
Diff

--- src/Makefile.orig 2017-01-12 21:54:08.156276696 -0600
+++ src/Makefile 2017-01-12 21:56:06.889752748 -0600
@@ -1,4 +1,4 @@
-CXXFLAGS= -O3 -fomit-frame-pointer
+CXXFLAGS= -O3 -fomit-frame-pointer $(CFLAGS)
override CXXFLAGS+= -Wall -fsigned-char -fno-exceptions -fno-rtti
PLATFORM= $(shell uname -s)
@@ -137,7 +137,7 @@
enet/Makefile:
cd enet; ./configure --enable-shared=no --enable-static=yes
-
+
libenet: enet/Makefile
$(MAKE) -C enet/ all
@@ -177,13 +177,13 @@
install: all
else
client: libenet $(CLIENT_OBJS)
- $(CXX) $(CXXFLAGS) -o sauer_client $(CLIENT_OBJS) $(CLIENT_LIBS)
+ $(CXX) $(CXXFLAGS) $(LDFLAGS) -o sauer_client $(CLIENT_OBJS) $(CLIENT_LIBS)
server: libenet $(SERVER_OBJS)
- $(CXX) $(CXXFLAGS) -o sauer_server $(SERVER_OBJS) $(SERVER_LIBS)
-
+ $(CXX) $(CXXFLAGS) $(LDFLAGS) -o sauer_server $(SERVER_OBJS) $(SERVER_LIBS)
+
master: libenet $(MASTER_OBJS)
- $(CXX) $(CXXFLAGS) -o sauer_master $(MASTER_OBJS) $(MASTER_LIBS)
+ $(CXX) $(CXXFLAGS) $(LDFLAGS) -o sauer_master $(MASTER_OBJS) $(MASTER_LIBS)
shared/cube2font.o: shared/cube2font.c
$(CXX) $(CXXFLAGS) -c -o $@ $< `freetype-config --cflags`