aboutsummaryrefslogtreecommitdiff
path: root/backends/platform/psp/psp.mk
blob: f3d104fb80fb4d89ab6e172b6fc2bae851cdcdca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
PSP_EXE_STRIPPED := scummvm_stripped$(EXEEXT)
PSP_EBOOT = EBOOT.PBP
PSP_EBOOT_SFO = param.sfo
PSP_EBOOT_TITLE = ScummVM-PSP
DATE = $(shell date +%Y%m%d)
DIST_EXECUTABLES=$(PSP_EBOOT) $(PLUGINS)

MKSFO = mksfoex -d MEMSIZE=1
PACK_PBP = pack-pbp

all: pack_pbp

clean: psp_clean

$(PSP_EXE_STRIPPED): $(EXECUTABLE)
	$(STRIP) $< -o $@

$(PSP_EBOOT_SFO): $(EXECUTABLE)
	$(MKSFO) '$(PSP_EBOOT_TITLE) r$(VER_REV) ($(DATE))' $@

psp_clean:
	$(RM) $(PSP_EXE_STRIPPED) $(PSP_EBOOT) $(PSP_EBOOT_SFO)

psp_fixup_elf: $(PSP_EXE_STRIPPED)
	psp-fixup-imports $<

pack_pbp: psp_fixup_elf $(PSP_EBOOT_SFO)
	$(PACK_PBP) $(PSP_EBOOT) \
	$(PSP_EBOOT_SFO) \
	$(srcdir)/backends/platform/psp/icon0.png \
	NULL \
	$(srcdir)/backends/platform/psp/pic0.png \
	$(srcdir)/backends/platform/psp/pic1.png \
	NULL \
	$(PSP_EXE_STRIPPED) \
	NULL

.PHONY: psp_fixup_elf pack_pbp