PCmake 1.26 KB
#!smake
# PCǥץ Makefile

include $(ROOT)/usr/include/make/PRdefs

APPDIR	= gs2dex

TEXTFILES = Makefile action.c action.h L2_TV.c \
	    main.c ppm8to5.perl ppmtoCI.perl rgb2u64.c spec sprite.c \
	    sprite.h sprite_ball.c static.c system.c system.h \
	    system_cfb.c system_rspbuf.c texture.c texture.h \
	    texture_pattern.h uc_assert.c uc_assert.h

BINFILES  = L2_TV.rgb L2_TV.rgba5551 

SUBDIRS	  = 

ERASELINE = 'install', 'rgb2u64'
ENDLINE   = 'L2_TV\.rgba5551'
LDIRTV	  = 

FILES	  = $(TEXTFILES) $(BINFILES)

default:
	$(INSTALL) -m 666 -F /PR/apps.pc/$(APPDIR) $(FILES)
	perl -ne 'if(/^LDIRT\s*=/){$$a=1;s/\t/ /;s/\*~//;s/\\//;}if(($$a==1)&&(/Makedepend/)){s/Makedepend//;$$a=0}print' Makefile |\
	perl $(ROOT)/PR/apps.released/mkPCmake.pl > \
		$(ROOT)/PR/apps.pc/$(APPDIR)/Makefile
	perl -i -pe 's/L2_TV.rgba5551//;s/L2_TV.ppm//;s/rgb2u64//;unless(/BGFILES/){s/L2_TV.c//}else{s/L2_TV.c/l2_tv.c/}' $(ROOT)/PR/apps.pc/$(APPDIR)/Makefile ; \
#	( \
#	cd $(ROOT)/PR/apps.pc/$(APPDIR) ; \
#	for i in $(TEXTFILES) ; do ( \
#		to_dos $$i /tmp/__pctmp ; \
#	        euctosjis /tmp/__pctmp > $$i ;  \
#	        rm -f /tmp/__pctmp )\
#	done ; \
#	)	
	cp $(ROOT)/PR/apps.released/__elfcom.c $(ROOT)/PR/apps.pc/$(APPDIR)

clean clobber:
	rm -rf $(ROOT)/PR/apps.pc/$(APPDIR)