From 2de16cc7f77c6e249d17059fe42f715fd43c3279 Mon Sep 17 00:00:00 2001
From: molivier <molivier@d7cf8633-e32d-0410-b094-e92efae38249>
Date: Fri, 10 Jun 2005 07:04:14 +0000
Subject: [PATCH] Fixed direct compilation of subtargets (cl-release, sv-debug,
 ...)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5419 d7cf8633-e32d-0410-b094-e92efae38249
---
 makefile     | 12 ++++++------
 makefile.bsd |  4 ++--
 makefile.inc | 19 +++----------------
 3 files changed, 11 insertions(+), 24 deletions(-)

diff --git a/makefile b/makefile
index bed6ab0d..299893ba 100644
--- a/makefile
+++ b/makefile
@@ -50,7 +50,7 @@ endif
 
 # Linux configuration
 ifeq ($(DP_MAKE_TARGET), linux)
-	DEFAULT_SNDAPI=$(DEFAULT_SNDAPI_LINUX)
+	DEFAULT_SNDAPI=ALSA
 	OBJ_CD=$(OBJ_LINUXCD)
 
 	OBJ_CL=$(OBJ_GLX)
@@ -66,7 +66,7 @@ endif
 
 # Mac OS X configuration
 ifeq ($(DP_MAKE_TARGET), macosx)
-	DEFAULT_SNDAPI=$(DEFAULT_SNDAPI_MACOSX)
+	DEFAULT_SNDAPI=COREAUDIO
 	OBJ_CD=$(OBJ_MACOSXCD)
 
 	OBJ_CL=$(OBJ_AGL)
@@ -82,7 +82,7 @@ endif
 
 # SunOS configuration (Solaris)
 ifeq ($(DP_MAKE_TARGET), sunos)
-	DEFAULT_SNDAPI=$(DEFAULT_SNDAPI_SUNOS)
+	DEFAULT_SNDAPI=OSS
 	OBJ_CD=$(OBJ_SUNOSCD)
 
 	OBJ_CL=$(OBJ_GLX)
@@ -101,9 +101,9 @@ endif
 # BSD configuration
 ifeq ($(DP_MAKE_TARGET), bsd)
 ifeq ($(DP_ARCH),FreeBSD)
-	DEFAULT_SNDAPI=$(DEFAULT_SNDAPI_OSS)
+	DEFAULT_SNDAPI=OSS
 else
-	DEFAULT_SNDAPI=$(DEFAULT_SNDAPI_BSD)
+	DEFAULT_SNDAPI=BSD
 endif
 	OBJ_CD=$(OBJ_BSDCD)
 
@@ -120,7 +120,7 @@ endif
 
 # Win32 configuration
 ifeq ($(DP_MAKE_TARGET), mingw)
-	DEFAULT_SNDAPI=$(DEFAULT_SNDAPI_WIN32)
+	DEFAULT_SNDAPI=WIN
 	OBJ_CD=$(OBJ_WINCD)
 
 	OBJ_CL=$(OBJ_WGL)
diff --git a/makefile.bsd b/makefile.bsd
index ecb66473..af0228e8 100644
--- a/makefile.bsd
+++ b/makefile.bsd
@@ -18,9 +18,9 @@ UNIX_X11LIBPATH=-L/usr/X11R6/lib
 
 # FreeBSD uses OSS
 .if $(DP_ARCH) == "FreeBSD"
-DEFAULT_SNDAPI=$(DEFAULT_SNDAPI_OSS)
+DEFAULT_SNDAPI=OSS
 .else
-DEFAULT_SNDAPI=$(DEFAULT_SNDAPI_BSD)
+DEFAULT_SNDAPI=BSD
 .endif
 OBJ_CD=$(OBJ_BSDCD)
 
diff --git a/makefile.inc b/makefile.inc
index 58135eab..f7ab1d95 100644
--- a/makefile.inc
+++ b/makefile.inc
@@ -169,8 +169,6 @@ CMD_UNIXRM=rm -rf
 
 ##### Linux specific variables #####
 
-DEFAULT_SNDAPI_LINUX=ALSA
-
 # If you want CD sound in Linux
 OBJ_LINUXCD=cd_linux.o
 # If you want no CD audio
@@ -184,8 +182,6 @@ LDFLAGS_LINUXSDL=$(LDFLAGS_UNIXCOMMON) -ldl $(LDFLAGS_UNIXSDL)
 
 ##### Mac OS X specific variables #####
 
-DEFAULT_SNDAPI_MACOSX=COREAUDIO
-
 # If you want CD sound in Mac OS X
 #OBJ_MACOSXCD=cd_macosx.o
 # If you want no CD audio
@@ -200,8 +196,6 @@ OBJ_AGL= builddate.c sys_linux.o vid_agl.o $(OBJ_SOUND) $(OBJ_CD) $(OBJ_COMMON)
 
 ##### SunOS specific variables #####
 
-DEFAULT_SNDAPI_SUNOS=OSS
-
 # No CD support available
 OBJ_SUNOSCD=$(OBJ_NOCD)
 
@@ -215,8 +209,6 @@ LDFLAGS_SUNOSSDL=$(LDFLAGS_UNIXCOMMON) -ldl -lsocket -lnsl $(LDFLAGS_UNIXSDL)
 
 ##### BSD specific variables #####
 
-DEFAULT_SNDAPI_BSD=BSD
-
 #if you want CD sound in BSD
 OBJ_BSDCD=cd_bsd.o
 #if you want no CD audio
@@ -230,8 +222,6 @@ LDFLAGS_BSDSDL=$(LDFLAGS_UNIXCOMMON) $(LDFLAGS_UNIXSDL)
 
 ##### Win32 specific variables #####
 
-DEFAULT_SNDAPI_WIN32=WIN
-
 #if you want CD sound in Win32
 OBJ_WINCD=cd_win.o
 #if you want no CD audio
@@ -277,16 +267,13 @@ help:
 	@echo
 
 debug :
-	$(MAKE) sdl-debug cl-debug sv-debug \
-		DP_MAKE_TARGET=$(DP_MAKE_TARGET) DP_SOUND_API=$(DP_SOUND_API)
+	$(MAKE) sv-debug cl-debug sdl-debug
 
 profile :
-	$(MAKE) sdl-profile cl-profile sv-profile \
-		DP_MAKE_TARGET=$(DP_MAKE_TARGET) DP_SOUND_API=$(DP_SOUND_API)
+	$(MAKE) sv-profile cl-profile sdl-profile
 
 release :
-	$(MAKE) sdl-release cl-release sv-release \
-		DP_MAKE_TARGET=$(DP_MAKE_TARGET) DP_SOUND_API=$(DP_SOUND_API)
+	$(MAKE) sv-release cl-release sdl-release
 
 cl-debug :
 	$(MAKE) bin-debug \
-- 
2.39.5