giz port, restructuring
[libpicofe.git] / gp2x / Makefile
index 5b8b039..65565f1 100644 (file)
@@ -32,7 +32,12 @@ use_cyclone = 1
 endif\r
 \r
 DEFINC = -I../.. -I. -DARM -D__GP2X__ -D_UNZIP_SUPPORT # -DBENCHMARK\r
-COPT_COMMON = -static -Wall -O2 -ftracer -fstrength-reduce -fomit-frame-pointer -fstrict-aliasing -ffast-math\r
+COPT_COMMON = -static -Wall -Winline\r
+ifeq ($(DEBUG),)\r
+COPT_COMMON += -O2 -ftracer -fstrength-reduce -fomit-frame-pointer -fstrict-aliasing -ffast-math\r
+else\r
+COPT_COMMON += -ggdb\r
+endif\r
 ifeq "$(profile)" "1"\r
 COPT_COMMON += -fprofile-generate\r
 endif\r
@@ -53,7 +58,7 @@ OBJS += main.o menu.o gp2x.o usbjoy.o emu.o squidgehack.o cpuctrl.o
 OBJS += 940ctl.o\r
 \r
 # common\r
-OBJS += ../common/menu.o ../common/fonts.o ../common/arm_utils.o ../common/readpng.o\r
+OBJS += ../common/emu.o ../common/menu.o ../common/fonts.o ../common/arm_utils.o ../common/readpng.o\r
 \r
 # Pico\r
 ifeq "$(amalgamate)" "1"\r
@@ -178,7 +183,7 @@ testrefr.gpe : test.o gp2x.o
 ../../Pico/sound/mix_asm.o : ../../Pico/sound/mix.s\r
        @echo $<\r
        @$(AS) $(ASOPT) $< -o $@\r
-../../Pico/misc_asm.o : ../../Pico/misc.s\r
+../../Pico/misc_asm.o : ../../Pico/Misc.s\r
        @echo $<\r
        @$(AS) $(ASOPT) $< -o $@\r
 ../../Pico/cd/pico_asm.o : ../../Pico/cd/Pico.s\r
@@ -187,7 +192,7 @@ testrefr.gpe : test.o gp2x.o
 ../../Pico/cd/memory_asm.o : ../../Pico/cd/Memory.s\r
        @echo $<\r
        @$(AS) $(ASOPT) $< -o $@\r
-../../Pico/cd/misc_asm.o : ../../Pico/cd/misc.s\r
+../../Pico/cd/misc_asm.o : ../../Pico/cd/Misc.s\r
        @echo $<\r
        @$(AS) $(ASOPT) $< -o $@\r
 \r