mirror of
https://github.com/Q3Rally-Team/q3rally.git
synced 2024-11-24 21:01:34 +00:00
Fixed compiling and patched Makefile to ioq3 r2139.
This commit is contained in:
parent
a04d06a8f3
commit
f999a31bf6
4 changed files with 258 additions and 236 deletions
404
engine/Makefile
404
engine/Makefile
|
@ -21,6 +21,9 @@ ifeq ($(COMPILE_PLATFORM),mingw32)
|
||||||
ifeq ($(COMPILE_ARCH),i386)
|
ifeq ($(COMPILE_ARCH),i386)
|
||||||
COMPILE_ARCH=x86
|
COMPILE_ARCH=x86
|
||||||
endif
|
endif
|
||||||
|
ifeq ($(COMPILE_ARCH),x86_64)
|
||||||
|
COMPILE_ARCH=x64
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifndef BUILD_STANDALONE
|
ifndef BUILD_STANDALONE
|
||||||
|
@ -166,6 +169,10 @@ ifndef USE_LOCAL_HEADERS
|
||||||
USE_LOCAL_HEADERS=1
|
USE_LOCAL_HEADERS=1
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifndef USE_RENDERER_DLOPEN
|
||||||
|
USE_RENDERER_DLOPEN=1
|
||||||
|
endif
|
||||||
|
|
||||||
ifndef DEBUG_CFLAGS
|
ifndef DEBUG_CFLAGS
|
||||||
DEBUG_CFLAGS=-g -O0
|
DEBUG_CFLAGS=-g -O0
|
||||||
endif
|
endif
|
||||||
|
@ -279,26 +286,7 @@ ifneq (,$(findstring "$(PLATFORM)", "linux" "gnu_kfreebsd" "kfreebsd-gnu"))
|
||||||
|
|
||||||
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
||||||
-pipe -DUSE_ICON
|
-pipe -DUSE_ICON
|
||||||
CLIENT_CFLAGS = $(SDL_CFLAGS)
|
CLIENT_CFLAGS += $(SDL_CFLAGS)
|
||||||
SERVER_CFLAGS =
|
|
||||||
|
|
||||||
ifeq ($(USE_OPENAL),1)
|
|
||||||
CLIENT_CFLAGS += -DUSE_OPENAL
|
|
||||||
ifeq ($(USE_OPENAL_DLOPEN),1)
|
|
||||||
CLIENT_CFLAGS += -DUSE_OPENAL_DLOPEN
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(USE_CURL),1)
|
|
||||||
CLIENT_CFLAGS += -DUSE_CURL
|
|
||||||
ifeq ($(USE_CURL_DLOPEN),1)
|
|
||||||
CLIENT_CFLAGS += -DUSE_CURL_DLOPEN
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(USE_CODEC_VORBIS),1)
|
|
||||||
CLIENT_CFLAGS += -DUSE_CODEC_VORBIS
|
|
||||||
endif
|
|
||||||
|
|
||||||
OPTIMIZEVM = -O3 -funroll-loops -fomit-frame-pointer
|
OPTIMIZEVM = -O3 -funroll-loops -fomit-frame-pointer
|
||||||
OPTIMIZE = $(OPTIMIZEVM) -ffast-math
|
OPTIMIZE = $(OPTIMIZEVM) -ffast-math
|
||||||
|
@ -338,10 +326,6 @@ ifneq (,$(findstring "$(PLATFORM)", "linux" "gnu_kfreebsd" "kfreebsd-gnu"))
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifneq ($(HAVE_VM_COMPILED),true)
|
|
||||||
BASE_CFLAGS += -DNO_VM_COMPILED
|
|
||||||
endif
|
|
||||||
|
|
||||||
SHLIBEXT=so
|
SHLIBEXT=so
|
||||||
SHLIBCFLAGS=-fPIC -fvisibility=hidden
|
SHLIBCFLAGS=-fPIC -fvisibility=hidden
|
||||||
SHLIBLDFLAGS=-shared $(LDFLAGS)
|
SHLIBLDFLAGS=-shared $(LDFLAGS)
|
||||||
|
@ -349,7 +333,8 @@ ifneq (,$(findstring "$(PLATFORM)", "linux" "gnu_kfreebsd" "kfreebsd-gnu"))
|
||||||
THREAD_LIBS=-lpthread
|
THREAD_LIBS=-lpthread
|
||||||
LIBS=-ldl -lm
|
LIBS=-ldl -lm
|
||||||
|
|
||||||
CLIENT_LIBS=$(SDL_LIBS) -lGL
|
CLIENT_LIBS=$(SDL_LIBS)
|
||||||
|
RENDERER_LIBS = $(SDL_LIBS) -lGL
|
||||||
|
|
||||||
ifeq ($(USE_OPENAL),1)
|
ifeq ($(USE_OPENAL),1)
|
||||||
ifneq ($(USE_OPENAL_DLOPEN),1)
|
ifneq ($(USE_OPENAL_DLOPEN),1)
|
||||||
|
@ -396,8 +381,6 @@ ifeq ($(PLATFORM),darwin)
|
||||||
OPTIMIZEVM=
|
OPTIMIZEVM=
|
||||||
|
|
||||||
BASE_CFLAGS = -Wall -Wimplicit -Wstrict-prototypes
|
BASE_CFLAGS = -Wall -Wimplicit -Wstrict-prototypes
|
||||||
CLIENT_CFLAGS =
|
|
||||||
SERVER_CFLAGS =
|
|
||||||
|
|
||||||
ifeq ($(ARCH),ppc)
|
ifeq ($(ARCH),ppc)
|
||||||
BASE_CFLAGS += -faltivec
|
BASE_CFLAGS += -faltivec
|
||||||
|
@ -416,25 +399,18 @@ ifeq ($(PLATFORM),darwin)
|
||||||
BASE_CFLAGS += -fno-strict-aliasing -DMACOS_X -fno-common -pipe
|
BASE_CFLAGS += -fno-strict-aliasing -DMACOS_X -fno-common -pipe
|
||||||
|
|
||||||
ifeq ($(USE_OPENAL),1)
|
ifeq ($(USE_OPENAL),1)
|
||||||
BASE_CFLAGS += -DUSE_OPENAL
|
|
||||||
ifneq ($(USE_OPENAL_DLOPEN),1)
|
ifneq ($(USE_OPENAL_DLOPEN),1)
|
||||||
CLIENT_LIBS += -framework OpenAL
|
CLIENT_LIBS += -framework OpenAL
|
||||||
else
|
|
||||||
CLIENT_CFLAGS += -DUSE_OPENAL_DLOPEN
|
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(USE_CURL),1)
|
ifeq ($(USE_CURL),1)
|
||||||
CLIENT_CFLAGS += -DUSE_CURL
|
|
||||||
ifneq ($(USE_CURL_DLOPEN),1)
|
ifneq ($(USE_CURL_DLOPEN),1)
|
||||||
CLIENT_LIBS += -lcurl
|
CLIENT_LIBS += -lcurl
|
||||||
else
|
|
||||||
CLIENT_CFLAGS += -DUSE_CURL_DLOPEN
|
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(USE_CODEC_VORBIS),1)
|
ifeq ($(USE_CODEC_VORBIS),1)
|
||||||
CLIENT_CFLAGS += -DUSE_CODEC_VORBIS
|
|
||||||
CLIENT_LIBS += -lvorbisfile -lvorbis -logg
|
CLIENT_LIBS += -lvorbisfile -lvorbis -logg
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
@ -454,10 +430,6 @@ ifeq ($(PLATFORM),darwin)
|
||||||
OPTIMIZEVM += -falign-loops=16
|
OPTIMIZEVM += -falign-loops=16
|
||||||
OPTIMIZE = $(OPTIMIZEVM) -ffast-math
|
OPTIMIZE = $(OPTIMIZEVM) -ffast-math
|
||||||
|
|
||||||
ifneq ($(HAVE_VM_COMPILED),true)
|
|
||||||
BASE_CFLAGS += -DNO_VM_COMPILED
|
|
||||||
endif
|
|
||||||
|
|
||||||
SHLIBEXT=dylib
|
SHLIBEXT=dylib
|
||||||
SHLIBCFLAGS=-fPIC -fno-common
|
SHLIBCFLAGS=-fPIC -fno-common
|
||||||
SHLIBLDFLAGS=-dynamiclib $(LDFLAGS)
|
SHLIBLDFLAGS=-dynamiclib $(LDFLAGS)
|
||||||
|
@ -487,8 +459,6 @@ ifeq ($(PLATFORM),mingw32)
|
||||||
|
|
||||||
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
||||||
-DUSE_ICON
|
-DUSE_ICON
|
||||||
CLIENT_CFLAGS =
|
|
||||||
SERVER_CFLAGS =
|
|
||||||
|
|
||||||
# In the absence of wspiapi.h, require Windows XP or later
|
# In the absence of wspiapi.h, require Windows XP or later
|
||||||
ifeq ($(shell test -e $(CMDIR)/wspiapi.h; echo $$?),1)
|
ifeq ($(shell test -e $(CMDIR)/wspiapi.h; echo $$?),1)
|
||||||
|
@ -496,19 +466,12 @@ ifeq ($(PLATFORM),mingw32)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(USE_OPENAL),1)
|
ifeq ($(USE_OPENAL),1)
|
||||||
CLIENT_CFLAGS += -DUSE_OPENAL
|
|
||||||
CLIENT_CFLAGS += $(OPENAL_CFLAGS)
|
CLIENT_CFLAGS += $(OPENAL_CFLAGS)
|
||||||
ifeq ($(USE_OPENAL_DLOPEN),1)
|
ifneq ($(USE_OPENAL_DLOPEN),1)
|
||||||
CLIENT_CFLAGS += -DUSE_OPENAL_DLOPEN
|
|
||||||
else
|
|
||||||
CLIENT_LDFLAGS += $(OPENAL_LDFLAGS)
|
CLIENT_LDFLAGS += $(OPENAL_LDFLAGS)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(USE_CODEC_VORBIS),1)
|
|
||||||
CLIENT_CFLAGS += -DUSE_CODEC_VORBIS
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(ARCH),x64)
|
ifeq ($(ARCH),x64)
|
||||||
OPTIMIZEVM = -O3 -fno-omit-frame-pointer \
|
OPTIMIZEVM = -O3 -fno-omit-frame-pointer \
|
||||||
-falign-loops=2 -funroll-loops -falign-jumps=2 -falign-functions=2 \
|
-falign-loops=2 -funroll-loops -falign-jumps=2 -falign-functions=2 \
|
||||||
|
@ -531,11 +494,11 @@ ifeq ($(PLATFORM),mingw32)
|
||||||
BINEXT=.exe
|
BINEXT=.exe
|
||||||
|
|
||||||
LIBS= -lws2_32 -lwinmm -lpsapi
|
LIBS= -lws2_32 -lwinmm -lpsapi
|
||||||
CLIENT_LDFLAGS = -mwindows
|
CLIENT_LDFLAGS += -mwindows
|
||||||
CLIENT_LIBS = -lgdi32 -lole32 -lopengl32
|
CLIENT_LIBS = -lgdi32 -lole32
|
||||||
|
RENDERER_LIBS = -lgdi32 -lole32 -lopengl32
|
||||||
|
|
||||||
ifeq ($(USE_CURL),1)
|
ifeq ($(USE_CURL),1)
|
||||||
CLIENT_CFLAGS += -DUSE_CURL
|
|
||||||
CLIENT_CFLAGS += $(CURL_CFLAGS)
|
CLIENT_CFLAGS += $(CURL_CFLAGS)
|
||||||
ifneq ($(USE_CURL_DLOPEN),1)
|
ifneq ($(USE_CURL_DLOPEN),1)
|
||||||
ifeq ($(USE_LOCAL_HEADERS),1)
|
ifeq ($(USE_LOCAL_HEADERS),1)
|
||||||
|
@ -564,18 +527,25 @@ ifeq ($(PLATFORM),mingw32)
|
||||||
|
|
||||||
# libmingw32 must be linked before libSDLmain
|
# libmingw32 must be linked before libSDLmain
|
||||||
CLIENT_LIBS += -lmingw32
|
CLIENT_LIBS += -lmingw32
|
||||||
|
RENDERER_LIBS += -lmingw32
|
||||||
|
|
||||||
ifeq ($(USE_LOCAL_HEADERS),1)
|
ifeq ($(USE_LOCAL_HEADERS),1)
|
||||||
CLIENT_CFLAGS += -I$(SDLHDIR)/include
|
CLIENT_CFLAGS += -I$(SDLHDIR)/include
|
||||||
ifeq ($(ARCH), x86)
|
ifeq ($(ARCH), x86)
|
||||||
CLIENT_LIBS += $(LIBSDIR)/win32/libSDLmain.a \
|
CLIENT_LIBS += $(LIBSDIR)/win32/libSDLmain.a \
|
||||||
$(LIBSDIR)/win32/libSDL.dll.a
|
$(LIBSDIR)/win32/libSDL.dll.a
|
||||||
|
RENDERER_LIBS += $(LIBSDIR)/win32/libSDLmain.a \
|
||||||
|
$(LIBSDIR)/win32/libSDL.dll.a
|
||||||
else
|
else
|
||||||
CLIENT_LIBS += $(LIBSDIR)/win64/libSDLmain.a \
|
CLIENT_LIBS += $(LIBSDIR)/win64/libSDLmain.a \
|
||||||
$(LIBSDIR)/win64/libSDL64.dll.a
|
$(LIBSDIR)/win64/libSDL64.dll.a
|
||||||
|
RENDERER_LIBS += $(LIBSDIR)/win64/libSDLmain.a \
|
||||||
|
$(LIBSDIR)/win64/libSDL64.dll.a
|
||||||
endif
|
endif
|
||||||
else
|
else
|
||||||
CLIENT_CFLAGS += $(SDL_CFLAGS)
|
CLIENT_CFLAGS += $(SDL_CFLAGS)
|
||||||
CLIENT_LIBS += $(SDL_LIBS)
|
CLIENT_LIBS += $(SDL_LIBS)
|
||||||
|
RENDERER_LIBS += $(SDL_LIBS)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
BUILD_CLIENT_SMP = 0
|
BUILD_CLIENT_SMP = 0
|
||||||
|
@ -592,8 +562,7 @@ ifeq ($(PLATFORM),freebsd)
|
||||||
BASE_CFLAGS = $(shell env MACHINE_ARCH=$(ARCH) make -f /dev/null -VCFLAGS) \
|
BASE_CFLAGS = $(shell env MACHINE_ARCH=$(ARCH) make -f /dev/null -VCFLAGS) \
|
||||||
-Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
-Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
||||||
-DUSE_ICON -DMAP_ANONYMOUS=MAP_ANON
|
-DUSE_ICON -DMAP_ANONYMOUS=MAP_ANON
|
||||||
CLIENT_CFLAGS = $(SDL_CFLAGS)
|
CLIENT_CFLAGS += $(SDL_CFLAGS)
|
||||||
SERVER_CFLAGS =
|
|
||||||
HAVE_VM_COMPILED = true
|
HAVE_VM_COMPILED = true
|
||||||
|
|
||||||
OPTIMIZEVM = -O3 -funroll-loops -fomit-frame-pointer
|
OPTIMIZEVM = -O3 -funroll-loops -fomit-frame-pointer
|
||||||
|
@ -609,27 +578,23 @@ ifeq ($(PLATFORM),freebsd)
|
||||||
|
|
||||||
CLIENT_LIBS =
|
CLIENT_LIBS =
|
||||||
|
|
||||||
CLIENT_LIBS += $(SDL_LIBS) -lGL
|
CLIENT_LIBS += $(SDL_LIBS)
|
||||||
|
RENDERER_LIBS = $(SDL_LIBS) -lGL
|
||||||
|
|
||||||
# optional features/libraries
|
# optional features/libraries
|
||||||
ifeq ($(USE_OPENAL),1)
|
ifeq ($(USE_OPENAL),1)
|
||||||
CLIENT_CFLAGS += -DUSE_OPENAL
|
|
||||||
ifeq ($(USE_OPENAL_DLOPEN),1)
|
ifeq ($(USE_OPENAL_DLOPEN),1)
|
||||||
CLIENT_CFLAGS += -DUSE_OPENAL_DLOPEN
|
|
||||||
CLIENT_LIBS += $(THREAD_LIBS) -lopenal
|
CLIENT_LIBS += $(THREAD_LIBS) -lopenal
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(USE_CURL),1)
|
ifeq ($(USE_CURL),1)
|
||||||
CLIENT_CFLAGS += -DUSE_CURL
|
|
||||||
ifeq ($(USE_CURL_DLOPEN),1)
|
ifeq ($(USE_CURL_DLOPEN),1)
|
||||||
CLIENT_CFLAGS += -DUSE_CURL_DLOPEN
|
|
||||||
CLIENT_LIBS += -lcurl
|
CLIENT_LIBS += -lcurl
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(USE_CODEC_VORBIS),1)
|
ifeq ($(USE_CODEC_VORBIS),1)
|
||||||
CLIENT_CFLAGS += -DUSE_CODEC_VORBIS
|
|
||||||
CLIENT_LIBS += -lvorbisfile -lvorbis -logg
|
CLIENT_LIBS += -lvorbisfile -lvorbis -logg
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
@ -657,28 +622,13 @@ ifeq ($(PLATFORM),openbsd)
|
||||||
|
|
||||||
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
||||||
-DUSE_ICON -DMAP_ANONYMOUS=MAP_ANON
|
-DUSE_ICON -DMAP_ANONYMOUS=MAP_ANON
|
||||||
CLIENT_CFLAGS = $(SDL_CFLAGS)
|
CLIENT_CFLAGS += $(SDL_CFLAGS)
|
||||||
SERVER_CFLAGS =
|
|
||||||
|
|
||||||
ifeq ($(USE_OPENAL),1)
|
|
||||||
CLIENT_CFLAGS += -DUSE_OPENAL
|
|
||||||
ifeq ($(USE_OPENAL_DLOPEN),1)
|
|
||||||
CLIENT_CFLAGS += -DUSE_OPENAL_DLOPEN
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(USE_CODEC_VORBIS),1)
|
|
||||||
CLIENT_CFLAGS += -DUSE_CODEC_VORBIS
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(USE_CURL),1)
|
ifeq ($(USE_CURL),1)
|
||||||
CLIENT_CFLAGS += -DUSE_CURL $(CURL_CFLAGS)
|
CLIENT_CFLAGS += $(CURL_CFLAGS)
|
||||||
USE_CURL_DLOPEN=0
|
USE_CURL_DLOPEN=0
|
||||||
endif
|
endif
|
||||||
|
|
||||||
BASE_CFLAGS += -DNO_VM_COMPILED
|
|
||||||
HAVE_VM_COMPILED=false
|
|
||||||
|
|
||||||
SHLIBEXT=so
|
SHLIBEXT=so
|
||||||
SHLIBNAME=.$(SHLIBEXT)
|
SHLIBNAME=.$(SHLIBEXT)
|
||||||
SHLIBCFLAGS=-fPIC
|
SHLIBCFLAGS=-fPIC
|
||||||
|
@ -689,7 +639,8 @@ ifeq ($(PLATFORM),openbsd)
|
||||||
|
|
||||||
CLIENT_LIBS =
|
CLIENT_LIBS =
|
||||||
|
|
||||||
CLIENT_LIBS += $(SDL_LIBS) -lGL
|
CLIENT_LIBS += $(SDL_LIBS)
|
||||||
|
RENDERER_LIBS = $(SDL_LIBS) -lGL
|
||||||
|
|
||||||
ifeq ($(USE_OPENAL),1)
|
ifeq ($(USE_OPENAL),1)
|
||||||
ifneq ($(USE_OPENAL_DLOPEN),1)
|
ifneq ($(USE_OPENAL_DLOPEN),1)
|
||||||
|
@ -726,15 +677,12 @@ ifeq ($(PLATFORM),netbsd)
|
||||||
THREAD_LIBS=-lpthread
|
THREAD_LIBS=-lpthread
|
||||||
|
|
||||||
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes
|
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes
|
||||||
CLIENT_CFLAGS =
|
|
||||||
SERVER_CFLAGS =
|
|
||||||
|
|
||||||
ifneq ($(ARCH),i386)
|
ifeq ($(ARCH),i386)
|
||||||
BASE_CFLAGS += -DNO_VM_COMPILED
|
HAVE_VM_COMPILED=true
|
||||||
endif
|
endif
|
||||||
|
|
||||||
BUILD_CLIENT = 0
|
BUILD_CLIENT = 0
|
||||||
BUILD_GAME_QVM = 0
|
|
||||||
|
|
||||||
else # ifeq netbsd
|
else # ifeq netbsd
|
||||||
|
|
||||||
|
@ -750,8 +698,8 @@ ifeq ($(PLATFORM),irix64)
|
||||||
MKDIR = mkdir -p
|
MKDIR = mkdir -p
|
||||||
|
|
||||||
BASE_CFLAGS=-Dstricmp=strcasecmp -Xcpluscomm -woff 1185 \
|
BASE_CFLAGS=-Dstricmp=strcasecmp -Xcpluscomm -woff 1185 \
|
||||||
-I. -I$(ROOT)/usr/include -DNO_VM_COMPILED
|
-I. -I$(ROOT)/usr/include
|
||||||
CLIENT_CFLAGS = $(SDL_CFLAGS)
|
CLIENT_CFLAGS += $(SDL_CFLAGS)
|
||||||
OPTIMIZE = -O3
|
OPTIMIZE = -O3
|
||||||
|
|
||||||
SHLIBEXT=so
|
SHLIBEXT=so
|
||||||
|
@ -760,8 +708,9 @@ ifeq ($(PLATFORM),irix64)
|
||||||
|
|
||||||
LIBS=-ldl -lm -lgen
|
LIBS=-ldl -lm -lgen
|
||||||
# FIXME: The X libraries probably aren't necessary?
|
# FIXME: The X libraries probably aren't necessary?
|
||||||
CLIENT_LIBS=-L/usr/X11/$(LIB) $(SDL_LIBS) -lGL \
|
CLIENT_LIBS=-L/usr/X11/$(LIB) $(SDL_LIBS) \
|
||||||
-lX11 -lXext -lm
|
-lX11 -lXext -lm
|
||||||
|
RENDERER_LIBS = $(SDL_LIBS) -lGL
|
||||||
|
|
||||||
else # ifeq IRIX
|
else # ifeq IRIX
|
||||||
|
|
||||||
|
@ -790,8 +739,7 @@ ifeq ($(PLATFORM),sunos)
|
||||||
|
|
||||||
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \
|
||||||
-pipe -DUSE_ICON
|
-pipe -DUSE_ICON
|
||||||
CLIENT_CFLAGS = $(SDL_CFLAGS)
|
CLIENT_CFLAGS += $(SDL_CFLAGS)
|
||||||
SERVER_CFLAGS =
|
|
||||||
|
|
||||||
OPTIMIZEVM = -O3 -funroll-loops
|
OPTIMIZEVM = -O3 -funroll-loops
|
||||||
|
|
||||||
|
@ -814,10 +762,6 @@ ifeq ($(PLATFORM),sunos)
|
||||||
|
|
||||||
OPTIMIZE = $(OPTIMIZEVM) -ffast-math
|
OPTIMIZE = $(OPTIMIZEVM) -ffast-math
|
||||||
|
|
||||||
ifneq ($(HAVE_VM_COMPILED),true)
|
|
||||||
BASE_CFLAGS += -DNO_VM_COMPILED
|
|
||||||
endif
|
|
||||||
|
|
||||||
SHLIBEXT=so
|
SHLIBEXT=so
|
||||||
SHLIBCFLAGS=-fPIC
|
SHLIBCFLAGS=-fPIC
|
||||||
SHLIBLDFLAGS=-shared $(LDFLAGS)
|
SHLIBLDFLAGS=-shared $(LDFLAGS)
|
||||||
|
@ -827,14 +771,15 @@ ifeq ($(PLATFORM),sunos)
|
||||||
|
|
||||||
BOTCFLAGS=-O0
|
BOTCFLAGS=-O0
|
||||||
|
|
||||||
CLIENT_LIBS +=$(SDL_LIBS) -lGL -lX11 -lXext -liconv -lm
|
CLIENT_LIBS +=$(SDL_LIBS) -lX11 -lXext -liconv -lm
|
||||||
|
RENDERER_LIBS = $(SDL_LIBS) -lGL
|
||||||
|
|
||||||
else # ifeq sunos
|
else # ifeq sunos
|
||||||
|
|
||||||
#############################################################################
|
#############################################################################
|
||||||
# SETUP AND BUILD -- GENERIC
|
# SETUP AND BUILD -- GENERIC
|
||||||
#############################################################################
|
#############################################################################
|
||||||
BASE_CFLAGS=-DNO_VM_COMPILED
|
BASE_CFLAGS=
|
||||||
OPTIMIZE = -O3
|
OPTIMIZE = -O3
|
||||||
|
|
||||||
SHLIBEXT=so
|
SHLIBEXT=so
|
||||||
|
@ -850,6 +795,11 @@ endif #NetBSD
|
||||||
endif #IRIX
|
endif #IRIX
|
||||||
endif #SunOS
|
endif #SunOS
|
||||||
|
|
||||||
|
ifneq ($(HAVE_VM_COMPILED),true)
|
||||||
|
BASE_CFLAGS += -DNO_VM_COMPILED
|
||||||
|
BUILD_GAME_QVM=0
|
||||||
|
endif
|
||||||
|
|
||||||
TARGETS =
|
TARGETS =
|
||||||
|
|
||||||
ifndef FULLBINEXT
|
ifndef FULLBINEXT
|
||||||
|
@ -870,11 +820,18 @@ ifneq ($(BUILD_SERVER),0)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifneq ($(BUILD_CLIENT),0)
|
ifneq ($(BUILD_CLIENT),0)
|
||||||
|
ifneq ($(USE_RENDERER_DLOPEN),0)
|
||||||
|
TARGETS += $(B)/q3rally$(FULLBINEXT) $(B)/renderer_opengl1_$(SHLIBNAME)
|
||||||
|
ifneq ($(BUILD_CLIENT_SMP),0)
|
||||||
|
TARGETS += $(B)/renderer_opengl1_smp_$(SHLIBNAME)
|
||||||
|
endif
|
||||||
|
else
|
||||||
TARGETS += $(B)/q3rally$(FULLBINEXT)
|
TARGETS += $(B)/q3rally$(FULLBINEXT)
|
||||||
ifneq ($(BUILD_CLIENT_SMP),0)
|
ifneq ($(BUILD_CLIENT_SMP),0)
|
||||||
TARGETS += $(B)/q3rally-smp$(FULLBINEXT)
|
TARGETS += $(B)/q3rally-smp$(FULLBINEXT)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
ifneq ($(BUILD_GAME_SO),0)
|
ifneq ($(BUILD_GAME_SO),0)
|
||||||
TARGETS += \
|
TARGETS += \
|
||||||
|
@ -904,6 +861,28 @@ ifneq ($(BUILD_GAME_QVM),0)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifeq ($(USE_OPENAL),1)
|
||||||
|
CLIENT_CFLAGS += -DUSE_OPENAL
|
||||||
|
ifeq ($(USE_OPENAL_DLOPEN),1)
|
||||||
|
CLIENT_CFLAGS += -DUSE_OPENAL_DLOPEN
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifeq ($(USE_CURL),1)
|
||||||
|
CLIENT_CFLAGS += -DUSE_CURL
|
||||||
|
ifeq ($(USE_CURL_DLOPEN),1)
|
||||||
|
CLIENT_CFLAGS += -DUSE_CURL_DLOPEN
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifeq ($(USE_CODEC_VORBIS),1)
|
||||||
|
CLIENT_CFLAGS += -DUSE_CODEC_VORBIS
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifeq ($(USE_RENDERER_DLOPEN),1)
|
||||||
|
CLIENT_CFLAGS += -DUSE_RENDERER_DLOPEN
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(USE_MUMBLE),1)
|
ifeq ($(USE_MUMBLE),1)
|
||||||
CLIENT_CFLAGS += -DUSE_MUMBLE
|
CLIENT_CFLAGS += -DUSE_MUMBLE
|
||||||
endif
|
endif
|
||||||
|
@ -929,7 +908,7 @@ ifeq ($(USE_INTERNAL_JPEG),1)
|
||||||
BASE_CFLAGS += -DUSE_INTERNAL_JPEG
|
BASE_CFLAGS += -DUSE_INTERNAL_JPEG
|
||||||
BASE_CFLAGS += -I$(JPDIR)
|
BASE_CFLAGS += -I$(JPDIR)
|
||||||
else
|
else
|
||||||
CLIENT_LIBS += -ljpeg
|
RENDERER_LIBS += -ljpeg
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifdef DEFAULT_BASEDIR
|
ifdef DEFAULT_BASEDIR
|
||||||
|
@ -977,9 +956,14 @@ $(echo_cmd) "CC $<"
|
||||||
$(Q)$(CC) $(NOTSHLIBCFLAGS) $(CFLAGS) $(CLIENT_CFLAGS) $(OPTIMIZE) -o $@ -c $<
|
$(Q)$(CC) $(NOTSHLIBCFLAGS) $(CFLAGS) $(CLIENT_CFLAGS) $(OPTIMIZE) -o $@ -c $<
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
define DO_REF_CC
|
||||||
|
$(echo_cmd) "REF_CC $<"
|
||||||
|
$(Q)$(CC) $(SHLIBCFLAGS) $(CFLAGS) $(CLIENT_CFLAGS) $(OPTIMIZE) -o $@ -c $<
|
||||||
|
endef
|
||||||
|
|
||||||
define DO_SMP_CC
|
define DO_SMP_CC
|
||||||
$(echo_cmd) "SMP_CC $<"
|
$(echo_cmd) "SMP_CC $<"
|
||||||
$(Q)$(CC) $(NOTSHLIBCFLAGS) $(CFLAGS) $(CLIENT_CFLAGS) $(OPTIMIZE) -DSMP -o $@ -c $<
|
$(Q)$(CC) $(SHLIBCFLAGS) $(CFLAGS) $(CLIENT_CFLAGS) $(OPTIMIZE) -DSMP -o $@ -c $<
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define DO_BOT_CC
|
define DO_BOT_CC
|
||||||
|
@ -1141,7 +1125,8 @@ makedirs:
|
||||||
@if [ ! -d $(BUILD_DIR) ];then $(MKDIR) $(BUILD_DIR);fi
|
@if [ ! -d $(BUILD_DIR) ];then $(MKDIR) $(BUILD_DIR);fi
|
||||||
@if [ ! -d $(B) ];then $(MKDIR) $(B);fi
|
@if [ ! -d $(B) ];then $(MKDIR) $(B);fi
|
||||||
@if [ ! -d $(B)/client ];then $(MKDIR) $(B)/client;fi
|
@if [ ! -d $(B)/client ];then $(MKDIR) $(B)/client;fi
|
||||||
@if [ ! -d $(B)/clientsmp ];then $(MKDIR) $(B)/clientsmp;fi
|
@if [ ! -d $(B)/renderer ];then $(MKDIR) $(B)/renderer;fi
|
||||||
|
@if [ ! -d $(B)/renderersmp ];then $(MKDIR) $(B)/renderersmp;fi
|
||||||
@if [ ! -d $(B)/ded ];then $(MKDIR) $(B)/ded;fi
|
@if [ ! -d $(B)/ded ];then $(MKDIR) $(B)/ded;fi
|
||||||
@if [ ! -d $(B)/baseq3r ];then $(MKDIR) $(B)/baseq3r;fi
|
@if [ ! -d $(B)/baseq3r ];then $(MKDIR) $(B)/baseq3r;fi
|
||||||
@if [ ! -d $(B)/baseq3r/cgame ];then $(MKDIR) $(B)/baseq3r/cgame;fi
|
@if [ ! -d $(B)/baseq3r/cgame ];then $(MKDIR) $(B)/baseq3r/cgame;fi
|
||||||
|
@ -1431,37 +1416,7 @@ Q3OBJ = \
|
||||||
$(B)/client/l_precomp.o \
|
$(B)/client/l_precomp.o \
|
||||||
$(B)/client/l_script.o \
|
$(B)/client/l_script.o \
|
||||||
$(B)/client/l_struct.o \
|
$(B)/client/l_struct.o \
|
||||||
$(B)/client/tr_animation.o \
|
|
||||||
$(B)/client/tr_backend.o \
|
|
||||||
$(B)/client/tr_bsp.o \
|
|
||||||
$(B)/client/tr_cmds.o \
|
|
||||||
$(B)/client/tr_curve.o \
|
|
||||||
$(B)/client/tr_flares.o \
|
|
||||||
$(B)/client/tr_font.o \
|
|
||||||
$(B)/client/tr_image.o \
|
|
||||||
$(B)/client/tr_image_png.o \
|
|
||||||
$(B)/client/tr_image_jpg.o \
|
|
||||||
$(B)/client/tr_image_bmp.o \
|
|
||||||
$(B)/client/tr_image_tga.o \
|
|
||||||
$(B)/client/tr_image_pcx.o \
|
|
||||||
$(B)/client/tr_init.o \
|
|
||||||
$(B)/client/tr_light.o \
|
|
||||||
$(B)/client/tr_main.o \
|
|
||||||
$(B)/client/tr_marks.o \
|
|
||||||
$(B)/client/tr_mesh.o \
|
|
||||||
$(B)/client/tr_model.o \
|
|
||||||
$(B)/client/tr_model_iqm.o \
|
|
||||||
$(B)/client/tr_noise.o \
|
|
||||||
$(B)/client/tr_scene.o \
|
|
||||||
$(B)/client/tr_shade.o \
|
|
||||||
$(B)/client/tr_shade_calc.o \
|
|
||||||
$(B)/client/tr_shader.o \
|
|
||||||
$(B)/client/tr_shadows.o \
|
|
||||||
$(B)/client/tr_sky.o \
|
|
||||||
$(B)/client/tr_surface.o \
|
|
||||||
$(B)/client/tr_world.o \
|
|
||||||
\
|
\
|
||||||
$(B)/client/sdl_gamma.o \
|
|
||||||
$(B)/client/sdl_input.o \
|
$(B)/client/sdl_input.o \
|
||||||
$(B)/client/sdl_snd.o \
|
$(B)/client/sdl_snd.o \
|
||||||
\
|
\
|
||||||
|
@ -1469,54 +1424,95 @@ Q3OBJ = \
|
||||||
$(B)/client/con_log.o \
|
$(B)/client/con_log.o \
|
||||||
$(B)/client/sys_main.o
|
$(B)/client/sys_main.o
|
||||||
|
|
||||||
|
Q3ROBJ = \
|
||||||
|
$(B)/renderer/tr_animation.o \
|
||||||
|
$(B)/renderer/tr_backend.o \
|
||||||
|
$(B)/renderer/tr_bsp.o \
|
||||||
|
$(B)/renderer/tr_cmds.o \
|
||||||
|
$(B)/renderer/tr_curve.o \
|
||||||
|
$(B)/renderer/tr_flares.o \
|
||||||
|
$(B)/renderer/tr_font.o \
|
||||||
|
$(B)/renderer/tr_image.o \
|
||||||
|
$(B)/renderer/tr_image_png.o \
|
||||||
|
$(B)/renderer/tr_image_jpg.o \
|
||||||
|
$(B)/renderer/tr_image_bmp.o \
|
||||||
|
$(B)/renderer/tr_image_tga.o \
|
||||||
|
$(B)/renderer/tr_image_pcx.o \
|
||||||
|
$(B)/renderer/tr_init.o \
|
||||||
|
$(B)/renderer/tr_light.o \
|
||||||
|
$(B)/renderer/tr_main.o \
|
||||||
|
$(B)/renderer/tr_marks.o \
|
||||||
|
$(B)/renderer/tr_mesh.o \
|
||||||
|
$(B)/renderer/tr_model.o \
|
||||||
|
$(B)/renderer/tr_model_iqm.o \
|
||||||
|
$(B)/renderer/tr_noise.o \
|
||||||
|
$(B)/renderer/tr_scene.o \
|
||||||
|
$(B)/renderer/tr_shade.o \
|
||||||
|
$(B)/renderer/tr_shade_calc.o \
|
||||||
|
$(B)/renderer/tr_shader.o \
|
||||||
|
$(B)/renderer/tr_shadows.o \
|
||||||
|
$(B)/renderer/tr_sky.o \
|
||||||
|
$(B)/renderer/tr_surface.o \
|
||||||
|
$(B)/renderer/tr_world.o \
|
||||||
|
\
|
||||||
|
$(B)/renderer/sdl_gamma.o
|
||||||
|
|
||||||
|
ifneq ($(USE_RENDERER_DLOPEN), 0)
|
||||||
|
Q3ROBJ += \
|
||||||
|
$(B)/renderer/q_shared.o \
|
||||||
|
$(B)/renderer/puff.o \
|
||||||
|
$(B)/renderer/q_math.o \
|
||||||
|
$(B)/renderer/tr_subs.o
|
||||||
|
endif
|
||||||
|
|
||||||
ifneq ($(USE_INTERNAL_JPEG),0)
|
ifneq ($(USE_INTERNAL_JPEG),0)
|
||||||
Q3OBJ += \
|
Q3ROBJ += \
|
||||||
$(B)/client/jaricom.o \
|
$(B)/renderer/jaricom.o \
|
||||||
$(B)/client/jcapimin.o \
|
$(B)/renderer/jcapimin.o \
|
||||||
$(B)/client/jcapistd.o \
|
$(B)/renderer/jcapistd.o \
|
||||||
$(B)/client/jcarith.o \
|
$(B)/renderer/jcarith.o \
|
||||||
$(B)/client/jccoefct.o \
|
$(B)/renderer/jccoefct.o \
|
||||||
$(B)/client/jccolor.o \
|
$(B)/renderer/jccolor.o \
|
||||||
$(B)/client/jcdctmgr.o \
|
$(B)/renderer/jcdctmgr.o \
|
||||||
$(B)/client/jchuff.o \
|
$(B)/renderer/jchuff.o \
|
||||||
$(B)/client/jcinit.o \
|
$(B)/renderer/jcinit.o \
|
||||||
$(B)/client/jcmainct.o \
|
$(B)/renderer/jcmainct.o \
|
||||||
$(B)/client/jcmarker.o \
|
$(B)/renderer/jcmarker.o \
|
||||||
$(B)/client/jcmaster.o \
|
$(B)/renderer/jcmaster.o \
|
||||||
$(B)/client/jcomapi.o \
|
$(B)/renderer/jcomapi.o \
|
||||||
$(B)/client/jcparam.o \
|
$(B)/renderer/jcparam.o \
|
||||||
$(B)/client/jcprepct.o \
|
$(B)/renderer/jcprepct.o \
|
||||||
$(B)/client/jcsample.o \
|
$(B)/renderer/jcsample.o \
|
||||||
$(B)/client/jctrans.o \
|
$(B)/renderer/jctrans.o \
|
||||||
$(B)/client/jdapimin.o \
|
$(B)/renderer/jdapimin.o \
|
||||||
$(B)/client/jdapistd.o \
|
$(B)/renderer/jdapistd.o \
|
||||||
$(B)/client/jdarith.o \
|
$(B)/renderer/jdarith.o \
|
||||||
$(B)/client/jdatadst.o \
|
$(B)/renderer/jdatadst.o \
|
||||||
$(B)/client/jdatasrc.o \
|
$(B)/renderer/jdatasrc.o \
|
||||||
$(B)/client/jdcoefct.o \
|
$(B)/renderer/jdcoefct.o \
|
||||||
$(B)/client/jdcolor.o \
|
$(B)/renderer/jdcolor.o \
|
||||||
$(B)/client/jddctmgr.o \
|
$(B)/renderer/jddctmgr.o \
|
||||||
$(B)/client/jdhuff.o \
|
$(B)/renderer/jdhuff.o \
|
||||||
$(B)/client/jdinput.o \
|
$(B)/renderer/jdinput.o \
|
||||||
$(B)/client/jdmainct.o \
|
$(B)/renderer/jdmainct.o \
|
||||||
$(B)/client/jdmarker.o \
|
$(B)/renderer/jdmarker.o \
|
||||||
$(B)/client/jdmaster.o \
|
$(B)/renderer/jdmaster.o \
|
||||||
$(B)/client/jdmerge.o \
|
$(B)/renderer/jdmerge.o \
|
||||||
$(B)/client/jdpostct.o \
|
$(B)/renderer/jdpostct.o \
|
||||||
$(B)/client/jdsample.o \
|
$(B)/renderer/jdsample.o \
|
||||||
$(B)/client/jdtrans.o \
|
$(B)/renderer/jdtrans.o \
|
||||||
$(B)/client/jerror.o \
|
$(B)/renderer/jerror.o \
|
||||||
$(B)/client/jfdctflt.o \
|
$(B)/renderer/jfdctflt.o \
|
||||||
$(B)/client/jfdctfst.o \
|
$(B)/renderer/jfdctfst.o \
|
||||||
$(B)/client/jfdctint.o \
|
$(B)/renderer/jfdctint.o \
|
||||||
$(B)/client/jidctflt.o \
|
$(B)/renderer/jidctflt.o \
|
||||||
$(B)/client/jidctfst.o \
|
$(B)/renderer/jidctfst.o \
|
||||||
$(B)/client/jidctint.o \
|
$(B)/renderer/jidctint.o \
|
||||||
$(B)/client/jmemmgr.o \
|
$(B)/renderer/jmemmgr.o \
|
||||||
$(B)/client/jmemnobs.o \
|
$(B)/renderer/jmemnobs.o \
|
||||||
$(B)/client/jquant1.o \
|
$(B)/renderer/jquant1.o \
|
||||||
$(B)/client/jquant2.o \
|
$(B)/renderer/jquant2.o \
|
||||||
$(B)/client/jutils.o
|
$(B)/renderer/jutils.o
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(ARCH),i386)
|
ifeq ($(ARCH),i386)
|
||||||
|
@ -1675,22 +1671,40 @@ ifeq ($(USE_MUMBLE),1)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
Q3POBJ += \
|
Q3POBJ += \
|
||||||
$(B)/client/sdl_glimp.o
|
$(B)/renderer/sdl_glimp.o
|
||||||
|
|
||||||
Q3POBJ_SMP += \
|
Q3POBJ_SMP += \
|
||||||
$(B)/clientsmp/sdl_glimp.o
|
$(B)/renderersmp/sdl_glimp.o
|
||||||
|
|
||||||
$(B)/q3rally$(FULLBINEXT): $(Q3OBJ) $(Q3POBJ) $(LIBSDLMAIN)
|
ifneq ($(USE_RENDERER_DLOPEN),0)
|
||||||
|
$(B)/q3rally$(FULLBINEXT): $(Q3OBJ) $(LIBSDLMAIN)
|
||||||
$(echo_cmd) "LD $@"
|
$(echo_cmd) "LD $@"
|
||||||
$(Q)$(CC) $(CLIENT_CFLAGS) $(CFLAGS) $(CLIENT_LDFLAGS) $(LDFLAGS) \
|
$(Q)$(CC) $(CLIENT_CFLAGS) $(CFLAGS) $(CLIENT_LDFLAGS) $(LDFLAGS) \
|
||||||
-o $@ $(Q3OBJ) $(Q3POBJ) \
|
-o $@ $(Q3OBJ) \
|
||||||
$(LIBSDLMAIN) $(CLIENT_LIBS) $(LIBS)
|
$(LIBSDLMAIN) $(CLIENT_LIBS) $(LIBS)
|
||||||
|
|
||||||
$(B)/q3rally-smp$(FULLBINEXT): $(Q3OBJ) $(Q3POBJ_SMP) $(LIBSDLMAIN)
|
$(B)/renderer_opengl1_$(SHLIBNAME): $(Q3ROBJ) $(Q3POBJ)
|
||||||
|
$(echo_cmd) "LD $@"
|
||||||
|
$(Q)$(CC) $(CFLAGS) $(SHLIBLDFLAGS) -o $@ $(Q3ROBJ) $(Q3POBJ) \
|
||||||
|
$(THREAD_LIBS) $(LIBSDLMAIN) $(RENDERER_LIBS) $(LIBS)
|
||||||
|
|
||||||
|
$(B)/renderer_opengl1_smp_$(SHLIBNAME): $(Q3ROBJ) $(Q3POBJ_SMP)
|
||||||
|
$(echo_cmd) "LD $@"
|
||||||
|
$(Q)$(CC) $(CFLAGS) $(SHLIBLDFLAGS) -o $@ $(Q3ROBJ) $(Q3POBJ_SMP) \
|
||||||
|
$(THREAD_LIBS) $(LIBSDLMAIN) $(RENDERER_LIBS) $(LIBS)
|
||||||
|
else
|
||||||
|
$(B)/q3rally$(FULLBINEXT): $(Q3OBJ) $(Q3ROBJ) $(Q3POBJ) $(LIBSDLMAIN)
|
||||||
|
$(echo_cmd) "LD $@"
|
||||||
|
$(Q)$(CC) $(CLIENT_CFLAGS) $(CFLAGS) $(CLIENT_LDFLAGS) $(LDFLAGS) \
|
||||||
|
-o $@ $(Q3OBJ) $(Q3ROBJ) $(Q3POBJ) \
|
||||||
|
$(LIBSDLMAIN) $(CLIENT_LIBS) $(RENDERER_LIBS) $(LIBS)
|
||||||
|
|
||||||
|
$(B)/q3rally-smp$(FULLBINEXT): $(Q3OBJ) $(Q3ROBJ) $(Q3POBJ_SMP) $(LIBSDLMAIN)
|
||||||
$(echo_cmd) "LD $@"
|
$(echo_cmd) "LD $@"
|
||||||
$(Q)$(CC) $(CLIENT_CFLAGS) $(CFLAGS) $(CLIENT_LDFLAGS) $(LDFLAGS) $(THREAD_LDFLAGS) \
|
$(Q)$(CC) $(CLIENT_CFLAGS) $(CFLAGS) $(CLIENT_LDFLAGS) $(LDFLAGS) $(THREAD_LDFLAGS) \
|
||||||
-o $@ $(Q3OBJ) $(Q3POBJ_SMP) \
|
-o $@ $(Q3OBJ) $(Q3ROBJ) $(Q3POBJ_SMP) \
|
||||||
$(THREAD_LIBS) $(LIBSDLMAIN) $(CLIENT_LIBS) $(LIBS)
|
$(THREAD_LIBS) $(LIBSDLMAIN) $(CLIENT_LIBS) $(RENDERER_LIBS) $(LIBS)
|
||||||
|
endif
|
||||||
|
|
||||||
ifneq ($(strip $(LIBSDLMAIN)),)
|
ifneq ($(strip $(LIBSDLMAIN)),)
|
||||||
ifneq ($(strip $(LIBSDLMAINSRC)),)
|
ifneq ($(strip $(LIBSDLMAINSRC)),)
|
||||||
|
@ -2225,22 +2239,16 @@ $(B)/client/%.o: $(CMDIR)/%.c
|
||||||
$(B)/client/%.o: $(BLIBDIR)/%.c
|
$(B)/client/%.o: $(BLIBDIR)/%.c
|
||||||
$(DO_BOT_CC)
|
$(DO_BOT_CC)
|
||||||
|
|
||||||
$(B)/client/%.o: $(JPDIR)/%.c
|
|
||||||
$(DO_CC)
|
|
||||||
|
|
||||||
$(B)/client/%.o: $(SPEEXDIR)/%.c
|
$(B)/client/%.o: $(SPEEXDIR)/%.c
|
||||||
$(DO_CC)
|
$(DO_CC)
|
||||||
|
|
||||||
$(B)/client/%.o: $(ZDIR)/%.c
|
$(B)/client/%.o: $(ZDIR)/%.c
|
||||||
$(DO_CC)
|
$(DO_CC)
|
||||||
|
|
||||||
$(B)/client/%.o: $(RDIR)/%.c
|
|
||||||
$(DO_CC)
|
|
||||||
|
|
||||||
$(B)/client/%.o: $(SDLDIR)/%.c
|
$(B)/client/%.o: $(SDLDIR)/%.c
|
||||||
$(DO_CC)
|
$(DO_CC)
|
||||||
|
|
||||||
$(B)/clientsmp/%.o: $(SDLDIR)/%.c
|
$(B)/renderersmp/%.o: $(SDLDIR)/%.c
|
||||||
$(DO_SMP_CC)
|
$(DO_SMP_CC)
|
||||||
|
|
||||||
$(B)/client/%.o: $(SYSDIR)/%.c
|
$(B)/client/%.o: $(SYSDIR)/%.c
|
||||||
|
@ -2253,6 +2261,19 @@ $(B)/client/%.o: $(SYSDIR)/%.rc
|
||||||
$(DO_WINDRES)
|
$(DO_WINDRES)
|
||||||
|
|
||||||
|
|
||||||
|
$(B)/renderer/%.o: $(CMDIR)/%.c
|
||||||
|
$(DO_REF_CC)
|
||||||
|
|
||||||
|
$(B)/renderer/%.o: $(SDLDIR)/%.c
|
||||||
|
$(DO_REF_CC)
|
||||||
|
|
||||||
|
$(B)/renderer/%.o: $(JPDIR)/%.c
|
||||||
|
$(DO_REF_CC)
|
||||||
|
|
||||||
|
$(B)/renderer/%.o: $(RDIR)/%.c
|
||||||
|
$(DO_REF_CC)
|
||||||
|
|
||||||
|
|
||||||
$(B)/ded/%.o: $(ASMDIR)/%.s
|
$(B)/ded/%.o: $(ASMDIR)/%.s
|
||||||
$(DO_AS)
|
$(DO_AS)
|
||||||
|
|
||||||
|
@ -2376,7 +2397,7 @@ $(B)/missionpack/qcommon/%.asm: $(CMDIR)/%.c $(Q3LCC)
|
||||||
# MISC
|
# MISC
|
||||||
#############################################################################
|
#############################################################################
|
||||||
|
|
||||||
OBJ = $(Q3OBJ) $(Q3POBJ) $(Q3POBJ_SMP) $(Q3DOBJ) \
|
OBJ = $(Q3OBJ) $(Q3POBJ) $(Q3POBJ_SMP) $(Q3ROBJ) $(Q3DOBJ) \
|
||||||
$(MPGOBJ) $(Q3GOBJ) $(Q3CGOBJ) $(MPCGOBJ) $(Q3UIOBJ) $(MPUIOBJ) \
|
$(MPGOBJ) $(Q3GOBJ) $(Q3CGOBJ) $(MPCGOBJ) $(Q3UIOBJ) $(MPUIOBJ) \
|
||||||
$(MPGVMOBJ) $(Q3GVMOBJ) $(Q3CGVMOBJ) $(MPCGVMOBJ) $(Q3UIVMOBJ) $(MPUIVMOBJ)
|
$(MPGVMOBJ) $(Q3GVMOBJ) $(Q3CGVMOBJ) $(MPCGVMOBJ) $(Q3UIVMOBJ) $(MPUIVMOBJ)
|
||||||
TOOLSOBJ = $(LBURGOBJ) $(Q3CPPOBJ) $(Q3RCCOBJ) $(Q3LCCOBJ) $(Q3ASMOBJ)
|
TOOLSOBJ = $(LBURGOBJ) $(Q3CPPOBJ) $(Q3RCCOBJ) $(Q3LCCOBJ) $(Q3ASMOBJ)
|
||||||
|
@ -2389,12 +2410,13 @@ copyfiles: release
|
||||||
|
|
||||||
ifneq ($(BUILD_CLIENT),0)
|
ifneq ($(BUILD_CLIENT),0)
|
||||||
$(INSTALL) $(STRIP_FLAG) -m 0755 $(BR)/q3rally$(FULLBINEXT) $(COPYBINDIR)/q3rally$(FULLBINEXT)
|
$(INSTALL) $(STRIP_FLAG) -m 0755 $(BR)/q3rally$(FULLBINEXT) $(COPYBINDIR)/q3rally$(FULLBINEXT)
|
||||||
|
$(INSTALL) $(STRIP_FLAG) -m 0755 $(BR)/renderer_opengl1_$(SHLIBNAME) $(COPYBINDIR)/renderer_opengl1_$(SHLIBNAME)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Don't copy the SMP until it's working together with SDL.
|
# Don't copy the SMP until it's working together with SDL.
|
||||||
#ifneq ($(BUILD_CLIENT_SMP),0)
|
ifneq ($(BUILD_CLIENT_SMP),0)
|
||||||
# $(INSTALL) $(STRIP_FLAG) -m 0755 $(BR)/q3rally-smp$(FULLBINEXT) $(COPYBINDIR)/q3rally-smp$(FULLBINEXT)
|
$(INSTALL) $(STRIP_FLAG) -m 0755 $(BR)/renderer_opengl1_smp_$(SHLIBNAME) $(COPYBINDIR)/renderer_opengl1_smp_$(SHLIBNAME)
|
||||||
#endif
|
endif
|
||||||
|
|
||||||
ifneq ($(BUILD_SERVER),0)
|
ifneq ($(BUILD_SERVER),0)
|
||||||
@if [ -f $(BR)/q3rally-server$(FULLBINEXT) ]; then \
|
@if [ -f $(BR)/q3rally-server$(FULLBINEXT) ]; then \
|
||||||
|
|
|
@ -2284,12 +2284,12 @@ int AINode_Battle_Fight(bot_state_t *bs) {
|
||||||
}
|
}
|
||||||
//if the enemy is not visible
|
//if the enemy is not visible
|
||||||
if (!BotEntityVisible(bs->entitynum, bs->eye, bs->cur_ps.viewangles, 360, bs->enemy)) {
|
if (!BotEntityVisible(bs->entitynum, bs->eye, bs->cur_ps.viewangles, 360, bs->enemy)) {
|
||||||
+#ifdef MISSIONPACK
|
#ifdef MISSIONPACK
|
||||||
+ if (bs->enemy == redobelisk.entitynum || bs->enemy == blueobelisk.entitynum) {
|
if (bs->enemy == redobelisk.entitynum || bs->enemy == blueobelisk.entitynum) {
|
||||||
+ AIEnter_Battle_Chase(bs, "battle fight: obelisk out of sight");
|
AIEnter_Battle_Chase(bs, "battle fight: obelisk out of sight");
|
||||||
+ return qfalse;
|
return qfalse;
|
||||||
+ }
|
}
|
||||||
+#endif
|
#endif
|
||||||
if (BotWantsToChase(bs)) {
|
if (BotWantsToChase(bs)) {
|
||||||
AIEnter_Battle_Chase(bs);
|
AIEnter_Battle_Chase(bs);
|
||||||
return qfalse;
|
return qfalse;
|
||||||
|
|
|
@ -890,37 +890,37 @@ void BotInputToUserCommand(bot_input_t *bi, usercmd_t *ucmd, int delta_angles[3]
|
||||||
//bot input speed is in the range [0, 400]
|
//bot input speed is in the range [0, 400]
|
||||||
bi->speed = bi->speed * 127 / 400;
|
bi->speed = bi->speed * 127 / 400;
|
||||||
//set the view independent movement
|
//set the view independent movement
|
||||||
+ f = DotProduct(forward, bi->dir);
|
f = DotProduct(forward, bi->dir);
|
||||||
+ r = DotProduct(right, bi->dir);
|
r = DotProduct(right, bi->dir);
|
||||||
+ u = abs(forward[2]) * bi->dir[2];
|
u = abs(forward[2]) * bi->dir[2];
|
||||||
+ m = fabs(f);
|
m = fabs(f);
|
||||||
+
|
|
||||||
+ if (fabs(r) > m) {
|
if (fabs(r) > m) {
|
||||||
+ m = fabs(r);
|
m = fabs(r);
|
||||||
+ }
|
}
|
||||||
+
|
|
||||||
+ if (fabs(u) > m) {
|
if (fabs(u) > m) {
|
||||||
+ m = fabs(u);
|
m = fabs(u);
|
||||||
+ }
|
}
|
||||||
+
|
|
||||||
+ if (m > 0) {
|
if (m > 0) {
|
||||||
+ f *= bi->speed / m;
|
f *= bi->speed / m;
|
||||||
+ r *= bi->speed / m;
|
r *= bi->speed / m;
|
||||||
+ u *= bi->speed / m;
|
u *= bi->speed / m;
|
||||||
+ }
|
}
|
||||||
+
|
|
||||||
+ ucmd->forwardmove = f;
|
ucmd->forwardmove = f;
|
||||||
+ ucmd->rightmove = r;
|
ucmd->rightmove = r;
|
||||||
+ ucmd->upmove = u;
|
ucmd->upmove = u;
|
||||||
+
|
|
||||||
+ if (bi->actionflags & ACTION_MOVEFORWARD) ucmd->forwardmove = 127;
|
if (bi->actionflags & ACTION_MOVEFORWARD) ucmd->forwardmove = 127;
|
||||||
+ if (bi->actionflags & ACTION_MOVEBACK) ucmd->forwardmove = -127;
|
if (bi->actionflags & ACTION_MOVEBACK) ucmd->forwardmove = -127;
|
||||||
+ if (bi->actionflags & ACTION_MOVELEFT) ucmd->rightmove = -127;
|
if (bi->actionflags & ACTION_MOVELEFT) ucmd->rightmove = -127;
|
||||||
+ if (bi->actionflags & ACTION_MOVERIGHT) ucmd->rightmove = 127;
|
if (bi->actionflags & ACTION_MOVERIGHT) ucmd->rightmove = 127;
|
||||||
//jump/moveup
|
//jump/moveup
|
||||||
+ if (bi->actionflags & ACTION_JUMP) ucmd->upmove = 127;
|
if (bi->actionflags & ACTION_JUMP) ucmd->upmove = 127;
|
||||||
//crouch/movedown
|
//crouch/movedown
|
||||||
+ if (bi->actionflags & ACTION_CROUCH) ucmd->upmove = -127;
|
if (bi->actionflags & ACTION_CROUCH) ucmd->upmove = -127;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -228,7 +228,7 @@ void P_WorldEffects( gentity_t *ent ) {
|
||||||
ent->damage = 15;
|
ent->damage = 15;
|
||||||
|
|
||||||
// play a gurp sound instead of a normal pain sound
|
// play a gurp sound instead of a normal pain sound
|
||||||
if (ent->health <= ent->damage) {
|
// if (ent->health <= ent->damage) {
|
||||||
// STONELANCE
|
// STONELANCE
|
||||||
// G_Sound(ent, CHAN_VOICE, G_SoundIndex("*drown.wav"));
|
// G_Sound(ent, CHAN_VOICE, G_SoundIndex("*drown.wav"));
|
||||||
// G_Sound(ent, CHAN_VOICE, G_SoundIndex("sound/rally/car/drown.wav"));
|
// G_Sound(ent, CHAN_VOICE, G_SoundIndex("sound/rally/car/drown.wav"));
|
||||||
|
|
Loading…
Reference in a new issue