raze-gles/polymer/eduke32/source/jaudiolib/Makefile
hendricks266 c5519e3fe8 More Build tools improvements:
- JFBuild ports: arttool, givedepth, and mkpalette
 - All viable tools are now built when 'make utils' is invoked, not just some
 - Revert "initprintf" hack of previous commit and replace it with "compat_tools.c"
 - Move Bstrtolower from baselayer.c to compat.c
 - Makefiles: Add start and finish messages for the tools
 - Makefiles: To prevent "-Wimplicit" from being passed to the C++ compiler, create $(*CONLYFLAGS)

git-svn-id: https://svn.eduke32.com/eduke32@2458 1a8010ca-5511-0410-912e-c29ae57300e0
2012-03-12 04:48:42 +00:00

72 lines
1.7 KiB
Makefile

include ../../Makefile.common
include ../../$(EROOT)/Makefile.shared
OBJ=obj
OBJNAME=libjfaudiolib.a
SRC=src
INC=include
# SDK locations - adjust to match your setup
ifneq ($(DXROOT_OVERRIDE),)
DXROOT ?= $(DXROOT_OVERRIDE)
else
DXROOT=../../../sdk/dx
#DXROOT ?= c:/sdks/directx/dx8
endif
CFLAGS=$(BASECFLAGS) $(BUILDCFLAGS) $(F_NO_STACK_PROTECTOR)
# for BUILD_ECHOFLAGS:
OURCFLAGS=$(CFLAGS)
OURCONLYFLAGS=$(BASECONLYFLAGS)
OURCXXFLAGS=$(BASECXXFLAGS)
CPPFLAGS=-I$(INC) -I$(SRC) -DHAVE_VORBIS
ifeq ($(PLATFORM),DARWIN)
ifeq (1,$(SDL_FRAMEWORK))
APPLE_INCLUDE_DIR:=../../Apple/include
OURCFLAGS += -DSDL_FRAMEWORK -I$(APPLE_INCLUDE_DIR) -I$(APPLE_FRAMEWORKS)/SDL.framework/Headers \
-I$(APPLE_FRAMEWORKS)/SDL_mixer.framework/Headers
endif
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),WINDOWS)
CPPFLAGS+= -I$(DXROOT)/include -Ithird-party/mingw32/include
OBJECTS+= $(OBJ)/driver_directsound.o
OBJNAME=libjfaudiolib_win32.a
OBJ=obj_win
else
CPPFLAGS+= -DHAVE_SDL
ifneq ($(PLATFORM),DARWIN)
CPPFLAGS+=`pkg-config --cflags vorbis`
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 $(CC) $(CPPFLAGS) $(OURCONLYFLAGS) $(OURCFLAGS) -c $< -o $@; then $(COMPILE_OK); else $(COMPILE_FAILED); fi
ifeq ($(PRETTY_OUTPUT),1)
.SILENT:
endif
.PHONY: clean
clean:
-rm -f $(OBJECTS) $(OBJNAME)