- Override CPPFLAGS and LDFLAGS (src/Makefile)

git-svn-id: svn://svn.code.sf.net/p/loki-lib/code/trunk@689 7ec92016-0320-0410-acc4-a06ded1c099a
This commit is contained in:
lfittl 2006-07-01 12:17:05 +00:00
parent 6bb64c5ff1
commit 5121014d22

View file

@ -2,26 +2,26 @@ SRC = $(wildcard *.cpp)
STATIC_OBJ = $(SRC:.cpp=.o) STATIC_OBJ = $(SRC:.cpp=.o)
SHARED_OBJ = $(SRC:.cpp=.lo) SHARED_OBJ = $(SRC:.cpp=.lo)
CPPFLAGS = -I../include -DNDEBUG override CPPFLAGS += -I../include -DNDEBUG
STATIC_LIB = libloki.a STATIC_LIB = libloki.a
ifeq ($(OS), Darwin) ifeq ($(OS), Darwin)
SHARED_LIB_BASE = libloki.dylib SHARED_LIB_BASE = libloki.dylib
SHARED_LIB_VERSIONED = libloki.$(VERSION).dylib SHARED_LIB_VERSIONED = libloki.$(VERSION).dylib
LDFLAGS = -dynamiclib -single_module -install_name $(SHARED_LIB_VERSIONED) -fPIC override LDFLAGS += -dynamiclib -single_module -install_name $(SHARED_LIB_VERSIONED) -fPIC
LDLIBS = -lpthread LDLIBS = -lpthread
RESULT_DIR = ../lib/ RESULT_DIR = ../lib/
else else
ifeq ($(OS), Linux) ifeq ($(OS), Linux)
SHARED_LIB_BASE = libloki.so SHARED_LIB_BASE = libloki.so
SHARED_LIB_VERSIONED = libloki.so.$(VERSION) SHARED_LIB_VERSIONED = libloki.so.$(VERSION)
LDFLAGS = --shared -Wl,-soname=$(SHARED_LIB_VERSIONED) -fPIC override LDFLAGS += --shared -Wl,-soname=$(SHARED_LIB_VERSIONED) -fPIC
LDLIBS = -lpthread LDLIBS = -lpthread
RESULT_DIR = ../lib/ RESULT_DIR = ../lib/
else else
SHARED_LIB_BASE = libloki.dll SHARED_LIB_BASE = libloki.dll
LDFLAGS = --shared override LDFLAGS += --shared
LDLIBS = LDLIBS =
RESULT_DIR = ../lib/ RESULT_DIR = ../lib/
endif endif