Makefile 1.46 KB
#!smake
PRDEPTH = ../..
include $(PRDEPTH)/PRdefs

COMMONPREF = BringupBoot

LASINCS = -I$(PRDEPTH)/iosim/src -I../include -I$(PRDEPTH)/include
LCINCS = -I$(ROOT)/PR/iosim/src -I../../include -I$(PRDEPTH)/include
ENDIAN = -EB
#if defined(HW_FLAGS) && $(HW_FLAGS) == "-D_HW_VERSION_1" 
BOOT_LDFLAGS = -allow_jump_at_eop -coff -N -T 04000400 -G 0
#else
BOOT_LDFLAGS = -allow_jump_at_eop -coff -N -T 04000040 -G 0
#endif
PIF2BOOT_LDFLAGS = -allow_jump_at_eop -coff -N -T b0001000 -G 0
LASOPTS = -Wab,-mips3 -Wab,-diag -non_shared -coff -G 0
LCOPTS = -Wab,-mips3 -Wab,-diag -non_shared -coff -g -G 0

LDV= ${LD} ${LLDFLAGS} ${VLDFLAGS} ${ENDIAN} 

ASFILES  = Boot.s pif2Boot.s

TARGETS  = Boot pif2Boot
#if defined(HW_FLAGS) && $(HW_FLAGS) == "-D_HW_VERSION_1" 
ROMHEADER= romheader.v1
#else
ROMHEADER= romheader
#endif
LDIRT = $(TARGETS) 

OBJECTS = $(ASFILES:.s=.o) $(CFILES:.c=.o)

include $(PRDEPTH)/PRrules

SUBDIRS = IPL4

default all:    $(TARGETS)
	$(SUBDIRS_MAKERULE)

$(COMMONTARGS): $(_FORCE) $(COMMONPREF)$@
	$(SUBDIRS_MAKERULE)

#
# install to the same directory as rsp ucode (/usr/lib/PR)
#
install exports: $(TARGETS)
	$(SUBDIRS_MAKERULE)
	$(INSTALL) -m 444 -F /usr/lib/PR $(TARGETS) font
	$(INSTALL) -m 444 -F /usr/lib/PR -src $(ROMHEADER) -O romheader

Boot:	$(OBJECTS) Makefile
	$(LD) $(BOOT_LDFLAGS) Boot.o -o Boot
	$(SIZE) -x Boot | grep "Size of Boot"

pif2Boot: $(OBJECTS) Makefile
	$(LD) $(PIF2BOOT_LDFLAGS) pif2Boot.o -o pif2Boot
	$(SIZE) -x pif2Boot | grep "Size of pif2Boot"