summaryrefslogtreecommitdiffstats
path: root/sys/boot/alpha/boot1/Makefile
blob: 3edaf04c81228287cd6a7a5799c1f96b8ff6c805 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# $NetBSD: Makefile,v 1.15 1998/03/28 00:21:35 thorpej Exp $

.include <../Makefile.inc>

PROG = boot1

.PATH:		${.CURDIR}/../../common
.PATH:		${.CURDIR}/../libalpha

SRCS=		start.S boot1.c sys.c
CFLAGS+=	-mno-fp-regs
CFLAGS+=	-I${.CURDIR}/../../common -I${.CURDIR}
CFLAGS+=	-I${LIBSTANDDIR}
CFLAGS+=	-I${.CURDIR}/..
CFLAGS+=	-DSECONDARY_LOAD_ADDRESS=${SECONDARY_LOAD_ADDRESS} -DMINIMAL
NOMAN=1
STRIP=
BINDIR?=	/usr/mdec

BOOT_RELOC = ${PRIMARY_LOAD_ADDRESS}

CLEANFILES+= ${PROG}.sym ${PROG}.nosym ${PROG}.list

all:	${PROG}

afterinstall:
	ln -sf boot1 /usr/mdec/daboot
	ln -sf boot1 /usr/mdec/fdboot

${PROG}.nosym: ${PROG}.sym
	cp ${PROG}.sym ${PROG}.nosym
	strip ${PROG}.nosym

${PROG}: ${PROG}.nosym
	objcopy -O binary ${PROG}.nosym ${PROG}

.include <bsd.prog.mk>

start.o:	${.CURDIR}/../libalpha/start.S
	${CC} -c ${CFLAGS} $<

${PROG}.sym: ${OBJS} ${LIBKERN}
	${LD} -M -Ttext ${BOOT_RELOC} -N -e start -o ${PROG}.sym ${OBJS} \
		${LIBSTAND} ${LIBALPHA} ${LIBSTAND} > ${.OBJDIR}/${PROG}.list
	size ${PROG}.sym
OpenPOWER on IntegriCloud