From b70bf50d65d77a3ce8a9b90a3ef3be4cb5abc2d5 Mon Sep 17 00:00:00 2001 From: ludwig Date: Sun, 13 Nov 2005 21:01:44 +0000 Subject: link against libopenal by default rather than dlopening it git-svn-id: svn://svn.icculus.org/quake3/trunk@349 edf5b092-35ff-0310-97b2-ce42778d08ea --- code/unix/Makefile | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'code/unix') diff --git a/code/unix/Makefile b/code/unix/Makefile index 4d2ab9b..e64de89 100644 --- a/code/unix/Makefile +++ b/code/unix/Makefile @@ -51,6 +51,10 @@ ifndef USE_OPENAL USE_OPENAL=1 endif +ifndef USE_OPENAL_DLOPEN +USE_OPENAL_DLOPEN=0 +endif + ifndef BUILD_CLIENT BUILD_CLIENT=1 endif @@ -121,6 +125,9 @@ ifeq ($(PLATFORM),linux) ifeq ($(USE_OPENAL),1) BASE_CFLAGS += -DUSE_OPENAL=1 + ifeq ($(USE_OPENAL_DLOPEN),1) + BASE_CFLAGS += -DUSE_OPENAL_DLOPEN=1 + endif endif ifeq ($(USE_SDL),1) @@ -168,6 +175,10 @@ ifeq ($(PLATFORM),linux) THREAD_LDFLAGS=-lpthread LDFLAGS=-ldl -lm + ifneq ($(USE_OPENAL_DLOPEN),1) + LDFLAGS += -lopenal + endif + ifeq ($(USE_SDL),1) GLLDFLAGS=$(shell sdl-config --libs) else @@ -224,6 +235,9 @@ ifeq ($(PLATFORM),mingw32) ifeq ($(USE_OPENAL),1) BASE_CFLAGS += -DUSE_OPENAL=1 + ifeq ($(USE_OPENAL_DLOPEN),1) + BASE_CFLAGS += -DUSE_OPENAL_DLOPEN=1 + endif endif DX_CFLAGS = -I$(DXSDK_DIR)/Include @@ -247,6 +261,10 @@ ifeq ($(PLATFORM),mingw32) LDFLAGS= -mwindows -lwsock32 -lgdi32 -lwinmm -lole32 GLLDFLAGS= + ifneq ($(USE_OPENAL_DLOPEN),1) + LDFLAGS += -lopenal + endif + ifeq ($(ARCH),x86) # build 32bit BASE_CFLAGS += -m32 -- cgit v1.2.3