blob: a7b5698a17fd983abd7b5d8884e172419b8ff6cb (
plain)
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
|
# $Id$
# For pthreads support on Linux, you need
# -D_POSIX_THREADS
# -D_POSIX_THREAD_SAFE_FUNCTIONS
# in the CXX command line. Also, add -lpthreads to the LIBS.
# libpthreads.so comes with the sources of Linux libc-5.3.*, you need
# to compile it yourself (no binaries included) --
# Jan Rychter <jwr@icm.edu.pl>
CC = gcc
CXX = g++
CFLAGS += $(DCFLAGS) -Wall -fno-strict-prototypes -D_POSIX_THREADS -D_POSIX_THREAD_SAFE_FUNCTIONS -D_REENTRANT
CCFLAGS += $(CFLAGS) -fno-implicit-templates
DCFLAGS += -g -O3
DLD = $(CXX)
LD = $(CXX)
LIBS += -ldl -lpthread
PIC = -fPIC
AR = ar
ARFLAGS = ruv
RANLIB = ranlib
SOFLAGS = $(CPPFLAGS) -shared
SOBUILD = $(COMPILE.cc) $(PIC) -o $(VSHDIR)$*.so $<
# Added line below to support "Executable Shared Object" files (as
# needed by the service configurator).
# Marius Kjeldahl <mariusk@sn.no, marius@funcom.com>
ESOBUILD = $(COMPILEESO.cc) $(PIC) -shared -o $(VSHDIR)$*.so $<
PRELIB = (echo "int main() { return 0; }" > gcctemp.c && \
$(COMPILE.cc) -o gcctemp.o gcctemp.c && \
$(LINK.cc) -o gcctemp gcctemp.o $^ $(LDFLAGS) $(VLDLIBS); \
status=$$?; exit $$status)
|