summaryrefslogtreecommitdiffstats
path: root/sys/boot/sparc64/loader
diff options
context:
space:
mode:
authorjake <jake@FreeBSD.org>2002-02-23 04:35:28 +0000
committerjake <jake@FreeBSD.org>2002-02-23 04:35:28 +0000
commitce801add096c9c6bdd2746b1ebac657ab8c93351 (patch)
treec95268bd6308d2843909d82c2c6209ad68425fcf /sys/boot/sparc64/loader
parent8f643f6169940e6274da22f5fb678422ade2579d (diff)
downloadFreeBSD-src-ce801add096c9c6bdd2746b1ebac657ab8c93351.zip
FreeBSD-src-ce801add096c9c6bdd2746b1ebac657ab8c93351.tar.gz
Add make variables for fs support and propagate them to CFLAGS. Put
-ffreestanding in CFLAGS. Remove unnecessary LDFLAGS.
Diffstat (limited to 'sys/boot/sparc64/loader')
-rw-r--r--sys/boot/sparc64/loader/Makefile30
1 files changed, 21 insertions, 9 deletions
diff --git a/sys/boot/sparc64/loader/Makefile b/sys/boot/sparc64/loader/Makefile
index dec52e0..64e686b 100644
--- a/sys/boot/sparc64/loader/Makefile
+++ b/sys/boot/sparc64/loader/Makefile
@@ -1,17 +1,31 @@
# $FreeBSD$
-LOADERBASE= 0x100000
-
BASE= loader
PROG= ${BASE}
NEWVERSWHAT= "bootstrap loader" sparc64
-LOADER_DISK_SUPPORT?= yes
-LOADER_NET_SUPPORT?= yes
+CFLAGS= -mno-app-regs
+
+LOADER_DISK_SUPPORT?= no
+LOADER_NET_SUPPORT?= yes
+LOADER_NFS_SUPPORT?= yes
+LOADER_TFTP_SUPPORT?= yes
+
+.if ${LOADER_DISK_SUPPORT} == "yes"
+CFLAGS+= -DLOADER_DISK_SUPPORT
+.endif
+.if ${LOADER_NET_SUPPORT} == "yes"
+CFLAGS+= -DLOADER_NET_SUPPORT
+.endif
+.if ${LOADER_NFS_SUPPORT} == "yes"
+CFLAGS+= -DLOADER_NFS_SUPPORT
+.endif
+.if ${LOADER_TFTP_SUPPORT} == "yes"
+CFLAGS+= -DLOADER_TFTP_SUPPORT
+.endif
# Architecture-specific loader code
SRCS= locore.s main.c metadata.c
-CFLAGS= -mno-app-regs
# Always add MI sources
.PATH: ${.CURDIR}/../../common
@@ -21,8 +35,8 @@ CFLAGS+= -I${.CURDIR}/../../.. -I.
CLEANFILES+= ${PROG}
-CFLAGS+= -W -Wall
-LDFLAGS= -X -Ttext ${LOADERBASE} -e _start -static
+CFLAGS+= -W -Wall -ffreestanding
+LDFLAGS= -X -static
# where to get libstand from
#XXX need a better way to do this
@@ -37,8 +51,6 @@ LIBOFW= ${.CURDIR}/../../ofw/libofw/libofw.a
CFLAGS+= -I${.CURDIR}/../../../../lib/libstand/
CFLAGS+= -I${.CURDIR}/../../ofw/libofw/
-CFLAGS+= -elf -DLOADERBASE=${LOADERBASE}
-
# Debug me!
#CFLAGS+= -g
#LDFLAGS+= -g
OpenPOWER on IntegriCloud