| 1 | # gpSP makefile |
| 2 | # Gilead Kutnick - Exophase |
| 3 | # pandora port - notaz |
| 4 | |
| 5 | # Global definitions |
| 6 | |
| 7 | CC = $(CROSS_COMPILE)gcc |
| 8 | |
| 9 | OBJS = pnd.o main.o cpu.o memory.o video.o input.o sound.o gui.o \ |
| 10 | cheats.o zip.o cpu_threaded.o arm_stub.o video_blend.o warm.o \ |
| 11 | linux/fbdev.o linux/xenv.o |
| 12 | BIN = gpsp |
| 13 | |
| 14 | # Platform specific definitions |
| 15 | |
| 16 | VPATH += .. ../arm |
| 17 | CFLAGS += -DARM_ARCH -DPND_BUILD -Wall |
| 18 | CFLAGS += -mcpu=cortex-a8 -mtune=cortex-a8 -mfloat-abi=softfp -ffast-math |
| 19 | CFLAGS += -ggdb |
| 20 | CFLAGS += -O2 |
| 21 | |
| 22 | # expecting to have PATH set up to get correct sdl-config first |
| 23 | CFLAGS += `sdl-config --cflags` |
| 24 | LIBS += `sdl-config --libs` |
| 25 | LIBS += -ldl -lpthread -lz |
| 26 | |
| 27 | # Compilation: |
| 28 | |
| 29 | all: $(BIN) picorestore |
| 30 | |
| 31 | %.o: %.S |
| 32 | $(CC) $(CFLAGS) -c -o $@ $< |
| 33 | |
| 34 | cpu.o cpu_threaded.o: CFLAGS += -Wno-unused-variable -Wno-unused-label |
| 35 | |
| 36 | $(BIN): $(OBJS) |
| 37 | $(CC) $(OBJS) $(LIBS) -o $(BIN) |
| 38 | |
| 39 | clean: |
| 40 | rm -f *.o $(BIN) picorestore |
| 41 | |
| 42 | # ----------- release ----------- |
| 43 | |
| 44 | PND_MAKE ?= $(HOME)/dev/pnd/src/pandora-libraries/testdata/scripts/pnd_make.sh |
| 45 | |
| 46 | rel: gpsp gpsp.sh gpsp.pxml gba_icon.png picorestore readme.txt ../game_config.txt ../COPYING.DOC |
| 47 | rm -rf out |
| 48 | mkdir out |
| 49 | cp $^ out/ |
| 50 | $(PND_MAKE) -p gpsp.pnd -d out -x out/gpsp.pxml -i out/gba_icon.png -c |