diff options
Diffstat (limited to 'games/nehquake/files/patch-Makefile')
-rw-r--r-- | games/nehquake/files/patch-Makefile | 44 |
1 files changed, 37 insertions, 7 deletions
diff --git a/games/nehquake/files/patch-Makefile b/games/nehquake/files/patch-Makefile index 2ca60fd73b91..1d40a6b42932 100644 --- a/games/nehquake/files/patch-Makefile +++ b/games/nehquake/files/patch-Makefile @@ -1,5 +1,5 @@ ---- ./Makefile.orig Thu Nov 10 11:57:23 2005 -+++ ./Makefile Tue May 16 17:36:22 2006 +--- Makefile.orig Sat May 27 13:47:34 2006 ++++ Makefile Sat May 27 14:04:12 2006 @@ -9,9 +9,9 @@ # @@ -12,7 +12,7 @@ ifneq (,$(findstring libc6,$(shell if [ -e /lib/libc.so.6 ];then echo libc6;fi))) GLIBC=-glibc -@@ -28,32 +28,33 @@ +@@ -28,32 +28,45 @@ MOUNT_DIR=./src @@ -23,14 +23,26 @@ -CC=gcc +CC?=gcc ++ARCH := $(shell uname -m | sed -e s/i.86/i386/ -e s/sun4u/sparc/ -e s/sparc64/sparc/ -e s/arm.*/arm/ -e s/sa110/arm/ -e s/alpha/axp/) ++USE_OPTIMIZED_CFLAGS?=YES -BASE_CFLAGS=-Dstricmp=strcasecmp #-Wall -+BASE_CFLAGS=$(CFLAGS) -Dstricmp=strcasecmp #-Wall ++ifeq ($(ARCH),i386) ++USE_X86_ASM?=YES ++else ++USE_X86_ASM=NO ++endif -RELEASE_CFLAGS=$(BASE_CFLAGS) -march=i686 -O2 -ffast-math -funroll-loops \ ++BASE_CFLAGS=$(CFLAGS) -Dstricmp=strcasecmp #-Wall ++ ++ifeq ($(strip $(USE_X86_ASM)),YES) ++BASE_CFLAGS+=-Did386 ++endif ++ +RELEASE_CFLAGS=$(BASE_CFLAGS) + -+ifdef OPTIMIZED_CFLAGS ++ifeq ($(strip $(USE_OPTIMIZED_CFLAGS)),YES) +RELEASE_CFLAGS+=-O2 -ffast-math -funroll-loops \ -fomit-frame-pointer -fexpensive-optimizations -fno-strict-aliasing -DEBUG_CFLAGS=$(BASE_CFLAGS) -g @@ -60,7 +72,7 @@ DO_CC=$(CC) $(CFLAGS) -o $@ -c $< DO_DEBUG_CC=$(CC) $(DEBUG_CFLAGS) -o $@ -c $< -@@ -70,10 +71,10 @@ +@@ -70,10 +83,10 @@ ############################################################################# @@ -73,7 +85,25 @@ endif all: -@@ -182,10 +183,10 @@ +@@ -165,12 +178,15 @@ + $(BUILDDIR)/glquake/sys_linux.o \ + $(BUILDDIR)/glquake/snd_dma.o \ + $(BUILDDIR)/glquake/snd_mem.o \ +- $(BUILDDIR)/glquake/snd_mix.o \ +- \ ++ $(BUILDDIR)/glquake/snd_mix.o ++ ++ifeq ($(strip $(USE_X86_ASM)),YES) ++GLQUAKE_OBJS+= \ + $(BUILDDIR)/glquake/math.o \ + $(BUILDDIR)/glquake/worlda.o \ + $(BUILDDIR)/glquake/snd_mixa.o \ + $(BUILDDIR)/glquake/sys_dosa.o ++endif + + GLQUAKE_LNX_OBJS = \ + $(BUILDDIR)/glquake/cd_linux.o \ +@@ -182,10 +198,10 @@ GLX_OBJS=$(BUILDDIR)/glquake/gl_vidlinuxglx.o |