X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?p=pcsx_rearmed.git;a=blobdiff_plain;f=Makefile;h=58961582fe32bf075c74017e7c0704c24aeb2ab3;hp=28a0c79e99dbaef77af1a66bee560aef5c68036c;hb=f5b13bdc7678f786f16ef25c1499555ddbc51321;hpb=c5061935e3f7b91d889d7546b06c4515c3004cb2 diff --git a/Makefile b/Makefile index 28a0c79e..58961582 100644 --- a/Makefile +++ b/Makefile @@ -14,10 +14,14 @@ endif ifndef DEBUG CFLAGS += -O2 # -DNDEBUG endif +USE_OSS = 1 +#USE_ALSA = 1 #DRC_DBG = 1 #PCNT = 1 TARGET = pcsx +-include Makefile.local + all: $(TARGET) # core @@ -40,9 +44,18 @@ CFLAGS += -DDRC_DBG endif # spu -OBJS += plugins/dfsound/adsr.o plugins/dfsound/dma.o plugins/dfsound/oss.o plugins/dfsound/reverb.o \ - plugins/dfsound/xa.o plugins/dfsound/freeze.o plugins/dfsound/cfg.o plugins/dfsound/registers.o \ - plugins/dfsound/spu.o +OBJS += plugins/dfsound/adsr.o plugins/dfsound/dma.o plugins/dfsound/reverb.o plugins/dfsound/xa.o \ + plugins/dfsound/freeze.o plugins/dfsound/cfg.o plugins/dfsound/registers.o plugins/dfsound/spu.o +ifeq "$(USE_OSS)" "1" +plugins/dfsound/%.o: CFLAGS += -DUSEOSS +OBJS += plugins/dfsound/oss.o +endif +ifeq "$(USE_ALSA)" "1" +plugins/dfsound/%.o: CFLAGS += -DUSEALSA +OBJS += plugins/dfsound/alsa.o +LDFLAGS += -lasound +endif + # gpu plugins/dfxvideo/%.o: CFLAGS += -Wall OBJS += plugins/dfxvideo/gpu.o @@ -68,6 +81,10 @@ OBJS += frontend/plat_omap.o else OBJS += frontend/plat_dummy.o endif +ifdef X11 +frontend/%.o: CFLAGS += -DX11 +OBJS += frontend/xkb.o +endif ifdef PCNT CFLAGS += -DPCNT endif @@ -84,14 +101,18 @@ frontend/revision.h: FORCE $(TARGET): $(OBJS) $(CC) -o $@ $^ $(LDFLAGS) -Wl,-Map=$@.map -spunull.so: plugins/spunull/spunull.c - $(CC) $(CFLAGS) -shared -fPIC -ggdb -O2 -o $@ $^ +PLUGINS = plugins/spunull/spunull.so plugins/gpu_unai/gpuPCSX4ALL.so \ + plugins/gpu-gles/gpuGLES.so -plugins/gpu-gles/gpuGLES.so: - make -C plugins/gpu-gles/ +$(PLUGINS): + make -C $(dir $@) clean: - $(RM) $(TARGET) $(OBJS) + $(RM) $(TARGET) $(OBJS) $(TARGET).map + +clean_plugins: + for dir in $(PLUGINS) ; do \ + $(MAKE) -C $$(dirname $$dir) clean; done # ----------- release ----------- @@ -99,7 +120,7 @@ PND_MAKE ?= $(HOME)/dev/pnd/src/pandora-libraries/testdata/scripts/pnd_make.sh VER ?= $(shell git describe --abbrev=0 master) -rel: pcsx spunull.so plugins/gpu-gles/gpuGLES.so \ +rel: pcsx $(PLUGINS) \ pandora/pcsx.sh pandora/pcsx.pxml pandora/pcsx.png \ pandora/picorestore pandora/readme.txt skin COPYING rm -rf out