| 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 |
| 18 | CFLAGS += -funsigned-char |
| 19 | CFLAGS += -mcpu=cortex-a8 -mtune=cortex-a8 -mfloat-abi=softfp -ffast-math |
| 20 | CFLAGS += -fno-common -fno-builtin |
| 21 | CFLAGS += -ggdb |
| 22 | CFLAGS += -O2 |
| 23 | |
| 24 | # expecting to have PATH set up to get correct sdl-config first |
| 25 | CFLAGS += `sdl-config --cflags` |
| 26 | LIBS += `sdl-config --libs` |
| 27 | LIBS += -ldl -lpthread -lz |
| 28 | |
| 29 | # Compilation: |
| 30 | |
| 31 | %.o: %.S |
| 32 | $(CC) $(CFLAGS) -c -o $@ $< |
| 33 | |
| 34 | all: $(BIN) |
| 35 | |
| 36 | $(BIN): $(OBJS) |
| 37 | $(CC) $(OBJS) $(LIBS) -o $(BIN) |
| 38 | |
| 39 | clean: |
| 40 | rm -f *.o $(BIN) |
| 41 | |