raze/polymer/eduke32/source/jaudiolib/Makefile
hendricks266 95dd57154e Clean up some file and directory structure.
* Renamed source/jaudiolib/third-party/mingw32 to source/jaudiolib/third-party/Windows.
* Moved source/jaudiolib/third-party/Windows/include to source/jaudiolib/third-party/common/include to use both on Windows and Apple.
* Deleted Apple/lib/include/{ogg,vorbis}/, see previous point.
* Deleted Apple/lib/libvorbisenc.a, 6MB saved.
* Moved Apple/lib/lib{ogg,vorbis,vorbisfile}.a to source/jaudiolib/third-party/Apple/lib, where they belong.
* Moved source files in Apple/ to source/, where they belong. (SDLMain.[mh] stay.)
* Deleted source/jaudiolib/third-party/{ogg,vorbis}.framework, not used any more.
* Renamed "StartupWinController*" to "startosx*".

git-svn-id: https://svn.eduke32.com/eduke32@3334 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 10:54:35 +00:00

93 lines
2.2 KiB
Makefile

include ../../Makefile.common
include ../../$(EROOT)/Makefile.shared
OBJ=obj
OBJNAME=libjfaudiolib.a
SRC=src
INC=include
# for BUILD_ECHOFLAGS:
OURCOMMONFLAGS=$(BASECOMMONFLAGS) $(BUILDCOMMONFLAGS) -I$(INC) -I$(SRC)
ifneq ($(PLATFORM),WII)
OURCOMMONFLAGS+= -DHAVE_VORBIS
endif
ifneq ($(RELEASE),0)
# Debugging disabled
debug+= $(F_NO_STACK_PROTECTOR)
endif
OURCFLAGS=$(OURCOMMONFLAGS) $(BASECFLAGS)
OURCONLYFLAGS=$(BASECONLYFLAGS)
OURCXXFLAGS=$(BASECXXFLAGS)
PRINTLDFLAGS=$(BASELDFLAGS)
OURASFLAGS=$(BASEASFLAGS)
ifeq ($(PLATFORM),DARWIN)
ifeq (1,$(SDL_FRAMEWORK))
OURCOMMONFLAGS += -I$(APPLE_FRAMEWORKS)/SDL.framework/Headers \
-I$(APPLE_FRAMEWORKS)/SDL_mixer.framework/Headers
else
OURCOMMONFLAGS += -I$(SDLROOT)/include -I$(SDLROOT)/include/SDL
endif
endif
COMPILER=$(CC) $(OURCONLYFLAGS)
ifneq ($(CPLUSPLUS),0)
COMPILER=$(CXX) $(OURCXXFLAGS)
endif
OBJECTS=$(OBJ)/drivers.o \
$(OBJ)/fx_man.o \
$(OBJ)/multivoc.o \
$(OBJ)/mix.o \
$(OBJ)/mixst.o \
$(OBJ)/pitch.o \
$(OBJ)/vorbis.o \
$(OBJ)/driver_nosound.o
ifeq ($(PLATFORM),DARWIN)
OURCOMMONFLAGS+= -Ithird-party/common/include
endif
ifeq ($(PLATFORM),WINDOWS)
ifeq ($(RENDERTYPE),WIN)
OURCOMMONFLAGS+= -DHAVE_DS -I$(DXROOT) -I$(DXROOT)/include
OBJECTS+= $(OBJ)/driver_directsound.o
endif
OURCOMMONFLAGS+= -Ithird-party/common/include
OBJNAME=libjfaudiolib_win32.a
OBJ=obj_win
endif
ifeq ($(RENDERTYPE),SDL)
OURCOMMONFLAGS+= -DHAVE_SDL
ifeq ($(PLATFORM),WINDOWS)
OURCOMMONFLAGS += -I$(SDLROOT)/include -I$(SDLROOT)/include/SDL
endif
ifneq ($(PLATFORM),DARWIN)
ifneq ($(PLATFORM),WINDOWS)
OURCOMMONFLAGS+=`pkg-config --cflags vorbis`
endif
endif
OBJECTS+= $(OBJ)/driver_sdl.o
endif
# OBJECTS=$(SOURCES:%.c=$(OBJ)/%.o)
$(OBJNAME): $(OBJECTS)
$(BUILD_ECHOFLAGS)
$(ARCHIVE_STATUS)
if $(AR) cr $@ $^; then $(ARCHIVE_OK); else $(ARCHIVE_FAILED); fi
$(OBJECTS): $(OBJ)/%.o: $(SRC)/%.c
-mkdir -p $(OBJ)
$(COMPILE_STATUS)
if $(COMPILER) $(OURCFLAGS) -c $< -o $@; then $(COMPILE_OK); else $(COMPILE_FAILED); fi
ifeq ($(PRETTY_OUTPUT),1)
.SILENT:
endif
.PHONY: clean
clean:
-rm -f $(OBJECTS) $(OBJNAME)