mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-09-06 15:48:05 -04:00
revive GP2X build, update
This commit is contained in:
parent
8b78786e0f
commit
75a30842c4
35 changed files with 757 additions and 2592 deletions
|
@ -1,111 +1,6 @@
|
|||
CROSS ?= arm-linux-
|
||||
|
||||
# settings
|
||||
use_cyclone = 1
|
||||
#use_musashi = 1
|
||||
use_drz80 = 1
|
||||
use_sh2drc = 1
|
||||
#use_sh2mame = 1
|
||||
|
||||
asm_memory = 1
|
||||
asm_render = 1
|
||||
asm_ym2612 = 1
|
||||
asm_misc = 1
|
||||
asm_cdpico = 1
|
||||
asm_cdmemory = 1
|
||||
asm_32xdraw = 1
|
||||
#profile = 1
|
||||
#drc_debug = 3
|
||||
|
||||
-include Makefile.local
|
||||
|
||||
ifeq "$(debug_cyclone)" "1"
|
||||
use_cyclone = 1
|
||||
use_musashi = 1
|
||||
endif
|
||||
ifeq "$(use_musashi)" "1"
|
||||
# due to CPU stop flag acces
|
||||
asm_cdpico = 0
|
||||
asm_cdmemory = 0
|
||||
endif
|
||||
|
||||
ARCH = arm
|
||||
DEFINES += ARM __GP2X__ IN_GP2X IN_EVDEV # BENCHMARK
|
||||
CFLAGS += -Wall -Winline -I../.. -I.
|
||||
ifeq ($(DEBUG),)
|
||||
CFLAGS += -O3 -fomit-frame-pointer -fstrict-aliasing -ffast-math
|
||||
endif
|
||||
CFLAGS += -mcpu=arm920t -mtune=arm920t
|
||||
ASFLAGS = -mcpu=arm920t -mfloat-abi=soft
|
||||
LDFLAGS += -lm -lpng
|
||||
|
||||
CC = $(CROSS)gcc
|
||||
STRIP = $(CROSS)strip
|
||||
AS = $(CROSS)as
|
||||
LD = $(CROSS)ld
|
||||
OBJCOPY = $(CROSS)objcopy
|
||||
|
||||
# frontend
|
||||
OBJS += plat.o warm.o pollux_set.o soc.o soc_mmsp2.o soc_pollux.o soc_dummy.o emu.o in_gp2x.o
|
||||
# 940 core control
|
||||
OBJS += 940ctl.o
|
||||
|
||||
# ARM stuff
|
||||
OBJS += pico/carthw/svp/compiler.o pico/carthw/svp/stub_arm.o
|
||||
OBJS += pico/sound/mix_arm.o
|
||||
|
||||
# common
|
||||
OBJS += platform/common/emu.o platform/common/menu_pico.o platform/common/fonts.o platform/common/config.o \
|
||||
platform/common/arm_utils.o platform/common/arm_linux.o platform/common/readpng.o \
|
||||
platform/common/mp3_helix.o platform/common/input.o platform/common/main.o platform/common/mp3.o \
|
||||
platform/linux/sndout_oss.o platform/linux/plat.o platform/linux/in_evdev.o
|
||||
|
||||
# unzip
|
||||
OBJS += unzip/unzip.o unzip/unzip_stream.o
|
||||
# zlib
|
||||
OBJS += zlib/gzio.o zlib/inffast.o zlib/inflate.o zlib/inftrees.o zlib/trees.o \
|
||||
zlib/deflate.o zlib/crc32.o zlib/adler32.o zlib/zutil.o zlib/compress.o
|
||||
|
||||
vpath %.c = ../..
|
||||
vpath %.s = ../..
|
||||
vpath %.S = ../..
|
||||
|
||||
DIRS += platform/gp2x platform/linux zlib unzip
|
||||
|
||||
|
||||
all: mkdirs PicoDrive
|
||||
|
||||
include ../common/common.mak
|
||||
include ../common/common_arm.mak
|
||||
include ../common/revision.mak
|
||||
|
||||
CFLAGS += $(addprefix -D,$(DEFINES))
|
||||
|
||||
# partial linking helps profiled builds due to section merging
|
||||
PicoDrive.o : $(OBJS) ../common/helix/$(CROSS)helix-mp3.a
|
||||
$(LD) -r -o $@ $^
|
||||
|
||||
# still using static, dynamic linking slows Wiz 1-10%
|
||||
# also libm on F100 is not compatible
|
||||
PicoDrive : PicoDrive.o
|
||||
@echo ">>>" $@
|
||||
$(CC) -static -o $@ $(CFLAGS) $^ $(LDFLAGS) -Wl,-Map=$@.map
|
||||
ifeq ($(DEBUG),)
|
||||
$(STRIP) $@
|
||||
endif
|
||||
|
||||
up: PicoDrive
|
||||
@cp -v PicoDrive /mnt/gp2x/mnt/sd/emus/PicoDrive/
|
||||
|
||||
clean: tidy
|
||||
$(RM) PicoDrive
|
||||
tidy:
|
||||
$(RM) $(OBJS)
|
||||
|
||||
readme.txt: ../../tools/textfilter ../base_readme.txt
|
||||
../../tools/textfilter ../base_readme.txt $@ GP2X
|
||||
|
||||
# ----------- release -----------
|
||||
VER ?= $(shell head -n 1 version.h | sed 's/.*"\(.*\)\.\(.*\)".*/\1\2/g')
|
||||
CODE940 = code940/pico940_v3.bin
|
||||
|
||||
|
@ -125,4 +20,3 @@ rel: PicoDrive PicoDrive.gpe $(CODE940) readme.txt ../game_def.cfg \
|
|||
|
||||
$(CODE940):
|
||||
make -C code940/
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue