diff options
Diffstat (limited to 'Makefile.trimui')
-rw-r--r-- | Makefile.trimui | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/Makefile.trimui b/Makefile.trimui new file mode 100644 index 0000000..25fe88e --- /dev/null +++ b/Makefile.trimui @@ -0,0 +1,52 @@ +# gpSP makefile +# Gilead Kutnick - Exophase +# pandora port - notaz +# respberry pi - DPR + +# Global definitions + +CC = $(CROSS_COMPILE)gcc +SYSROOT = $(shell $(CC) --print-sysroot) + +OBJS = main.o cpu.o gba_memory.o video.o input.o sound.o gba_cc_lut.o \ + bios_data.o cheats.o zip.o arm/arm_stub.o cpu_threaded.o arm/video_blend.o \ + frontend/libpicofe/input.o frontend/libpicofe/in_sdl.o \ + frontend/libpicofe/linux/in_evdev.o frontend/libpicofe/linux/plat.o \ + frontend/libpicofe/fonts.o frontend/libpicofe/readpng.o frontend/libpicofe/config_file.o \ + frontend/config.o frontend/menu.o frontend/plat_trimui.o frontend/main.o frontend/scale.o + +BIN = picogpsp + +# Platform specific definitions + +VPATH += .. ../arm +CFLAGS += -DARM_ARCH -DARM_ARCH_BLENDING_OPTS -DPC_BUILD -Wall -DHAVE_DYNAREC +CFLAGS += -Ofast -fdata-sections -ffunction-sections -flto -fno-PIC -DPICO_HOME_DIR='"/.picogpsp/"' +CFLAGS += -I./ $(shell $(SYSROOT)/usr/bin/sdl-config --cflags) + +# expecting to have PATH set up to get correct sdl-config first + +LIBS = -lc -lgcc -lSDL -lasound -lpng -lz -Wl,--as-needed -Wl,--gc-sections -flto -s + +ifeq ($(PROFILE), YES) +CFLAGS += -fprofile-generate=./profile +LIBS += -lgcov +else ifeq ($(PROFILE), APPLY) +CFLAGS += -fprofile-use -fprofile-dir=./profile -fbranch-probabilities +endif + +# Compilation: + +all: $(BIN) + +%.o: %.S + $(CC) $(CFLAGS) -c -o $@ $< + + +cpu.o cpu_threaded.o: CFLAGS += -Wno-unused-variable -Wno-unused-label + +$(BIN): $(OBJS) + $(CC) $(OBJS) $(LIBS) -o $(BIN) + +clean: + rm -f $(OBJS) $(BIN) |