Permalink
Switch branches/tags
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
50 lines (37 sloc) 1.35 KB
TITLE_ID = GAC000001
TARGET = Gamesandconsoles
OBJS = main.o
PSVITAIP = 192.168.0.105
LIBS = -lvita2d -lSceLibKernel_stub -lSceDisplay_stub -lSceGxm_stub -lSceIme_stub \
-lSceSysmodule_stub -lSceCtrl_stub -lScePgf_stub -lSceAppMgr_stub -lSceAppUtil_stub \
-lSceCommonDialog_stub -lfreetype -lpng -ljpeg -lz -lm -lc -lSceRegistryMgr_stub -lSceVshBridge_stub
PREFIX = arm-vita-eabi
CC = $(PREFIX)-gcc
CFLAGS = -Wl,-q -Wall -O3
ASFLAGS = $(CFLAGS)
all: $(TARGET).vpk
%.vpk: eboot.bin
vita-mksfoex -s TITLE_ID=$(TITLE_ID) "$(TARGET)" param.sfo
vita-pack-vpk -s param.sfo -b eboot.bin \
--add sce_sys/icon0.png=sce_sys/icon0.png \
--add sce_sys/livearea/contents/bg.png=sce_sys/livearea/contents/bg.png \
--add sce_sys/livearea/contents/startup.png=sce_sys/livearea/contents/startup.png \
--add sce_sys/livearea/contents/template.xml=sce_sys/livearea/contents/template.xml \
$@
eboot.bin: $(TARGET).velf
vita-make-fself $< $@
%.velf: %.elf
vita-elf-create $< $@
$(TARGET).elf: $(OBJS)
$(CC) $(CFLAGS) $^ $(LIBS) -o $@
%.o: %.png
$(PREFIX)-ld -r -b binary -o $@ $^
clean:
@rm -rf $(TARGET).vpk $(TARGET).velf $(TARGET).elf $(OBJS) \
eboot.bin param.sfo
vpksend: $(TARGET).vpk
curl -T $(TARGET).vpk ftp://$(PSVITAIP):1337/ux0:/
@echo "Sent."
send: eboot.bin
curl -T eboot.bin ftp://$(PSVITAIP):1337/ux0:/app/$(TITLE_ID)/
@echo "Sent."