blob: bf817c08763ed845d7b08014e2aaf7ffd733c6c7 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
--- Makefile.orig 2006-06-08 22:44:02.000000000 +0200
+++ Makefile 2008-04-11 13:18:40.000000000 +0200
@@ -34,19 +34,12 @@
CC=i586-mingw32msvc-gcc
LD=i586-mingw32msvc-gcc
else
-CC?=gcc
-LD=gcc
+CC?=cc
+LD=$(CC)
-# this nice line comes from the linux kernel makefile
-BASE_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/)
+ARCH=$(shell uname -m)
OS=$(shell uname)
-ifeq ($(OS),FreeBSD)
-ARCH=freebsd_$(BASE_ARCH)
-else
-ARCH=$(BASE_ARCH)
-endif
-
SHARED_LIBRARY_EXTENSION=so
endif
@@ -134,7 +127,7 @@
LIB=lib
endif
-LDFLAGS_CLIENT=-ljpeg -lz -L$(X11BASE)/$(LIB) -lX11 -lXext -lXxf86dga -lXxf86vm -lXinerama $(shell curl-config --libs)
+LDFLAGS_CLIENT=-ljpeg -lz -L$(X11BASE)/$(LIB) -lX11 -lXext -lXxf86dga -lXxf86vm -lXinerama $(shell curl-config --libs) $(PTHREAD_LIBS)
LDFLAGS_DED=-lz $(shell curl-config --libs)
LDFLAGS_MODULE=-shared
LDFLAGS_TV_SERVER=-lz
@@ -149,11 +142,7 @@
# sdl
ifeq ($(BUILD_SND_QF),YES)
-ifeq ($(OS),FreeBSD)
-SDL_CONFIG?=sdl11-config
-else
SDL_CONFIG?=sdl-config
-endif
CFLAGS_SDL=$(shell $(SDL_CONFIG) --cflags)
LDFLAGS_QF=$(shell $(SDL_CONFIG) --libs) -lvorbisfile
@@ -193,8 +182,7 @@
######################################################################################################
# Helper functions
######################################################################################################
-DO_CC=echo " > Compiling $<" && \
- $(CC) $(CFLAGS_COMMON) -c $< -o $@
+DO_CC=$(CC) $(CFLAGS_COMMON) -c $< -o $@
DO_CC_CLIENT=$(DO_CC) $(CFLAGS_CLIENT)
DO_CC_DED=$(DO_CC) $(CFLAGS_DED)
|