[2] | 1 | # $Id: Makefile 197 2024-09-29 07:13:35Z nishi $
|
---|
| 2 |
|
---|
| 3 | include $(PWD)/Platform/$(PLATFORM).mk
|
---|
| 4 |
|
---|
| 5 | .PHONY: all clean
|
---|
| 6 | .SUFFIXES: .c .o
|
---|
| 7 |
|
---|
[191] | 8 | OBJS = main.o version.o config.o server.o http.o module.o strptime.o font.o $(EXTOBJS) $(PREOBJS)
|
---|
[2] | 9 |
|
---|
[182] | 10 | all: tewi$(EXEC) $(TARGET)
|
---|
[2] | 11 |
|
---|
[182] | 12 | tewi_strip$(EXEC): tewi$(EXEC)
|
---|
| 13 |
|
---|
[3] | 14 | tewi$(EXEC): $(OBJS) ../Common/common.a
|
---|
[189] | 15 | $(CC) $(LDFLAGS) $(EXTLDFLAGS) -o $@ $(OBJS) $(EXTLIBS) ../Common/common.a $(LIBS)
|
---|
[182] | 16 | $(SERVADD)
|
---|
[2] | 17 |
|
---|
[182] | 18 | tewi.pbp: tewi_strip$(EXEC) param.sfo
|
---|
[183] | 19 | pack-pbp $@ param.sfo ../Binary/psp.png NULL NULL NULL NULL tewi_strip$(EXEC) NULL
|
---|
[182] | 20 |
|
---|
| 21 | param.sfo:
|
---|
| 22 | mksfoex -d MEMSIZE=1 'Tewi HTTPd' $@
|
---|
| 23 |
|
---|
[187] | 24 | tewi.self: tewi_strip$(EXEC)
|
---|
| 25 | sprxlinker tewi_strip$(EXEC)
|
---|
| 26 | make_self_npdrm tewi_strip$(EXEC) $@ UP0001-TEWI_00-0000000000000000
|
---|
| 27 | fself tewi_strip$(EXEC) tewi.fake.self
|
---|
| 28 |
|
---|
| 29 | tewi.pkg: tewi.self
|
---|
[197] | 30 | mkdir -p pkg/USRDIR/etc
|
---|
| 31 | mkdir -p pkg/USRDIR/www
|
---|
[193] | 32 | cp ../Binary/ps3.png pkg/ICON0.PNG
|
---|
[197] | 33 | ../Tool/genconf /dev_hdd0/game/TEWI_00-0/USRDIR lib/tewi so > pkg/USRDIR/etc/tewi.conf
|
---|
| 34 | cp ../Binary/pbtewi.gif pkg/USRDIR/www/
|
---|
| 35 | convert '../Binary/pbtewi.gif[0]' pkg/USRDIR/pbtewi.png
|
---|
| 36 | ../Tool/itworks > pkg/USRDIR/www/index.html
|
---|
[193] | 37 | make_self_npdrm tewi_strip$(EXEC) pkg/USRDIR/EBOOT.BIN UP0001-TEWI_00-0000000000000000
|
---|
[187] | 38 | sfo.py --title "Tewi HTTPd" --appid "TEWI" -f /usr/local/ps3dev/bin/sfo.xml pkg/PARAM.SFO
|
---|
| 39 | pkg.py --contentid UP0001-TEWI_00-0000000000000000 pkg/ $@
|
---|
| 40 | rm -rf pkg
|
---|
[195] | 41 | package_finalize $@
|
---|
[187] | 42 |
|
---|
[2] | 43 | .c.o:
|
---|
[44] | 44 | $(CC) $(CFLAGS) $(EXTCFLAGS) -c -o $@ $<
|
---|
[2] | 45 |
|
---|
[128] | 46 | tewi.res: tewi.rc ../Binary/tewi.ico
|
---|
[48] | 47 | $(WINDRES) tewi.rc -O coff -o $@
|
---|
| 48 |
|
---|
[2] | 49 | clean:
|
---|
[187] | 50 | rm -f *.o tewi *.exe *.res *.elf *.sfo *.pbp *.self *.pkg
|
---|