GNUmakefile 1.4 KB
#!smake -k
# --------------------------------------------------------------------
#        Copyright (C) 1997 Nintendo. (Originated by SGI)
#        
#        $RCSfile: GNUmakefile,v $
#        $Revision: 1.1 $
#        $Date: 2003/04/05 15:53:19 $
# --------------------------------------------------------------------
#
# Makefile for onetri demo application 
#
#

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

PRDEPTH = ../..

APP =		sptext

OPTIMIZER =	-g

TARGETS =	rom

TEXDIR  =	Texture


TEXTURES =	${TEXDIR}/letters.rgb

TEXHFILES = 	./letters_img.h


HFILES =	main.h font.h font_ext.h

CODEFILES   =	main.c sptext.c font.c

CODEOBJECTS =	$(CODEFILES:.c=.o)

DATAFILES   =	static.c cfb.c rsp_cfb.c

DATAOBJECTS =	$(DATAFILES:.c=.o)

CODESEGMENT =	codesegment.o

OBJECTS =	$(CODESEGMENT) $(DATAOBJECTS)

LCDEFS =
LCINCS =	-I.
LCOPTS =	-Wall -non_shared -G 0 -mips2
LDFLAGS =	$(MKDEPOPT) -L$(ROOT)/usr/lib -lultra_d -lgcc

LDIRT  =	$(APP) $(TEXHFILES)

default:	$(TARGETS)

include $(COMMONRULES)

install:	default
		$(INSTALL) -m 444 -F /usr/src/PR/demos/sptext \
		    $(HFILES) $(CODEFILES) $(DATAFILES) $(TEXTURES) Makefile spec

$(CODESEGMENT):	$(CODEOBJECTS)
		$(LD) -o $(CODESEGMENT) -r $(CODEOBJECTS) $(LDFLAGS)

rom $(APP):	spec $(OBJECTS) $(MAKEROM)
		$(MAKEROM) -r rom spec

font.o:		./letters_img.h

./letters_img.h:	${TEXDIR}/letters.rgb
	cd ${TEXDIR}; $(RGB2C) -F -m letters_img -f I -s 4 letters.rgb > ../letters_img.h