63 lines
1.6 KiB
Makefile
63 lines
1.6 KiB
Makefile
# $NetBSD: Makefile.bootprogs,v 1.4 1999/02/13 02:54:37 lukem Exp $
|
|
|
|
S= ${.CURDIR}/../../../..
|
|
|
|
.PATH: ${.CURDIR}/../common
|
|
|
|
MKMAN= no
|
|
STRIPFLAG=
|
|
BINMODE= 444
|
|
|
|
STRIP?= strip
|
|
|
|
.PHONY: machine-links
|
|
beforedepend: machine-links
|
|
# ${MACHINE} then ${MACHINE_ARCH}
|
|
machine-links:
|
|
-rm -f machine && \
|
|
ln -s $S/arch/alpha/include machine
|
|
-rm -f alpha && \
|
|
ln -s $S/arch/alpha/include alpha
|
|
CLEANFILES+=machine alpha
|
|
|
|
all: machine-links ${PROG}
|
|
|
|
AFLAGS += -DASSEMBLER
|
|
#CPPFLAGS+= -nostdinc -I${.OBJDIR}
|
|
CPPFLAGS+= -I${.OBJDIR}
|
|
CPPFLAGS += -D_STANDALONE -I${.CURDIR}/../.. -I${S}
|
|
CFLAGS = ${CWARNFLAGS} -mno-fp-regs -g
|
|
|
|
# For descriptions of regions available to bootstrap programs, see
|
|
# section 3.4.1.2 (pp. III 3-14 - III 3-18) of the second edition of
|
|
# the Alpha AXP Architecture Reference Manual.
|
|
|
|
PRIMARY_LOAD_ADDRESS= 20000000 # "Region 1 start"
|
|
SECONDARY_LOAD_ADDRESS= 20004000 # "Region 1 start" + 32k
|
|
HEAP_LIMIT= 20040000 # "Region 1 start" + 256k
|
|
|
|
CPPFLAGS+= -DPRIMARY_LOAD_ADDRESS="0x${PRIMARY_LOAD_ADDRESS}"
|
|
CPPFLAGS+= -DSECONDARY_LOAD_ADDRESS="0x${SECONDARY_LOAD_ADDRESS}"
|
|
CPPFLAGS+= -DHEAP_LIMIT="0x${HEAP_LIMIT}"
|
|
|
|
PRIMARY_CPPFLAGS= -DPRIMARY_BOOTBLOCK
|
|
FILE_FORMAT_CPPFLAGS= -DALPHA_BOOT_ECOFF -DALPHA_BOOT_ELF
|
|
|
|
.include <bsd.prog.mk>
|
|
|
|
### find out what to use for libkern
|
|
KERN_AS= library
|
|
.include "${S}/lib/libkern/Makefile.inc"
|
|
LIBKERN= ${KERNLIB}
|
|
|
|
### find out what to use for libz
|
|
Z_AS= library
|
|
.include "${S}/lib/libz/Makefile.inc"
|
|
LIBZ= ${ZLIB}
|
|
|
|
### find out what to use for libsa
|
|
SA_AS= library
|
|
SAMISCMAKEFLAGS= SA_USE_CREAD=yes
|
|
.include "${S}/lib/libsa/Makefile.inc"
|
|
LIBSA= ${SALIB}
|