]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
fixed some issues with how D3D=1 worked in the makefile
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 19 Aug 2010 17:34:47 +0000 (17:34 +0000)
committerRudolf Polzer <divVerent@alientrap.org>
Fri, 20 Aug 2010 12:13:51 +0000 (14:13 +0200)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10406 d7cf8633-e32d-0410-b094-e92efae38249
::stable-branch::merge=819764171ec0f979dd6ab46a5d53e7b5221725db

makefile
makefile.inc

index e3b6957e8245e900fb596b369e181cc4117c2cd9..8a5bda683833ec8bb6ce2f225ca5f9ba09f113ae 100644 (file)
--- a/makefile
+++ b/makefile
@@ -163,8 +163,10 @@ ifeq ($(WIN32RELEASE), 1)
 #      TARGET=i686-pc-mingw32
 #      CC=$(TARGET)-g++
 #      WINDRES=$(TARGET)-windres
-       CPUOPTIMIZATIONS+=-march=i686 -DUSE_WSPIAPI_H
-       LDFLAGS_WINCOMMON+=-Wl,--large-address-aware
+       CPUOPTIMIZATIONS=-march=i686 -fno-math-errno -ffinite-math-only -fno-rounding-math -fno-signaling-nans -fno-trapping-math -DUSE_WSPIAPI_H
+       LDFLAGS_WINCOMMON=-Wl,--large-address-aware
+else
+       LDFLAGS_WINCOMMON=
 endif
 
 ifeq ($(WIN64RELEASE), 1)
@@ -174,12 +176,13 @@ ifeq ($(WIN64RELEASE), 1)
 endif
 
 ifeq ($(D3D), 1)
-       CPUOPTIMIZATIONS+=-DSUPPORTD3D -DSUPPORTDIRECTX
+       CFLAGS_D3D=-DSUPPORTD3D -DSUPPORTDIRECTX
        CFLAGS_WARNINGS=-Wall
-       LDFLAGS_WINCOMMON=-ld3d9
+       LDFLAGS_D3D=-ld3d9
 else
+       CFLAGS_D3D=
        CFLAGS_WARNINGS=-Wall -Wold-style-definition -Wstrict-prototypes -Wsign-compare -Wdeclaration-after-statement
-       LDFLAGS_WINCOMMON=
+       LDFLAGS_D3D=
 endif
 
 
index 4f47858b8c64c173162a3edc702cb660388dbc9a..b5a31da7c85a1cb38deb6f48fa6a3241aa53cfbf 100644 (file)
@@ -182,7 +182,7 @@ CFLAGS_LIBJPEG=-DLINK_TO_LIBJPEG
 LIB_JPEG=-ljpeg
 
 # Compilation
-CFLAGS_COMMON=$(CFLAGS_MAKEDEP) $(CFLAGS_PRELOAD) $(CFLAGS_FS) $(CFLAGS_CG) $(CFLAGS_WARNINGS) $(CFLAGS_LIBJPEG)
+CFLAGS_COMMON=$(CFLAGS_MAKEDEP) $(CFLAGS_PRELOAD) $(CFLAGS_FS) $(CFLAGS_CG) $(CFLAGS_WARNINGS) $(CFLAGS_LIBJPEG) $(CFLAGS_D3D)
 CFLAGS_DEBUG=-ggdb
 CFLAGS_PROFILE=-g -pg -ggdb -fprofile-arcs
 CFLAGS_RELEASE=
@@ -295,7 +295,7 @@ OBJ_WGL= builddate.c sys_win.o vid_wgl.o $(OBJ_SND_WIN) $(OBJ_WINCD) $(OBJ_COMMO
 
 # Link
 # see LDFLAGS_WINCOMMON in makefile
-LDFLAGS_WINCL=$(LDFLAGS_WINCOMMON) -mwindows -lwinmm -luser32 -lgdi32 -ldxguid -ldinput -lcomctl32 -lws2_32 $(LIB_JPEG)
+LDFLAGS_WINCL=$(LDFLAGS_WINCOMMON) -mwindows -lwinmm -luser32 -lgdi32 -ldxguid -ldinput -lcomctl32 -lws2_32 $(LDFLAGS_D3D) $(LIB_JPEG)
 LDFLAGS_WINSV=$(LDFLAGS_WINCOMMON) -mconsole -lwinmm -lws2_32 $(LIB_JPEG)
 LDFLAGS_WINSDL=$(LDFLAGS_WINCOMMON) $(SDLCONFIG_LIBS) $(LIB_SND_MODPLUG) -lwinmm -lws2_32 $(LIB_JPEG)
 EXE_WINCL=darkplaces.exe