]> CyberLeo.Net >> Repos - FreeBSD/releng/7.2.git/blob - sys/boot/sparc64/loader/Makefile
Create releng/7.2 from stable/7 in preparation for 7.2-RELEASE.
[FreeBSD/releng/7.2.git] / sys / boot / sparc64 / loader / Makefile
1 # $FreeBSD$
2
3 .include <bsd.own.mk>
4
5 PROG=           loader
6 NEWVERSWHAT=    "bootstrap loader" sparc64
7 INSTALLFLAGS=   -b
8
9 # Architecture-specific loader code
10 SRCS=           locore.S main.c metadata.c vers.c
11
12 LOADER_DISK_SUPPORT?=   yes
13 LOADER_UFS_SUPPORT?=    yes
14 LOADER_CD9660_SUPPORT?= yes
15 LOADER_NET_SUPPORT?=    yes
16 LOADER_NFS_SUPPORT?=    yes
17 LOADER_TFTP_SUPPORT?=   yes
18 LOADER_GZIP_SUPPORT?=   yes
19 LOADER_BZIP2_SUPPORT?=  no
20
21 .if ${LOADER_DISK_SUPPORT} == "yes"
22 CFLAGS+=        -DLOADER_DISK_SUPPORT
23 .endif
24 .if ${LOADER_UFS_SUPPORT} == "yes"
25 CFLAGS+=        -DLOADER_UFS_SUPPORT
26 .endif
27 .if ${LOADER_CD9660_SUPPORT} == "yes"
28 CFLAGS+=        -DLOADER_CD9660_SUPPORT
29 .endif
30 .if ${LOADER_GZIP_SUPPORT} == "yes"
31 CFLAGS+=        -DLOADER_GZIP_SUPPORT
32 .endif
33 .if ${LOADER_BZIP2_SUPPORT} == "yes"
34 CFLAGS+=        -DLOADER_BZIP2_SUPPORT
35 .endif
36 .if ${LOADER_NET_SUPPORT} == "yes"
37 CFLAGS+=        -DLOADER_NET_SUPPORT
38 .endif
39 .if ${LOADER_NFS_SUPPORT} == "yes"
40 CFLAGS+=        -DLOADER_NFS_SUPPORT
41 .endif
42 .if ${LOADER_TFTP_SUPPORT} == "yes"
43 CFLAGS+=        -DLOADER_TFTP_SUPPORT
44 .endif
45
46 .if ${MK_FORTH} != "no"
47 # Enable BootForth
48 BOOT_FORTH=     yes
49 CFLAGS+=        -DBOOT_FORTH -I${.CURDIR}/../../ficl -I${.CURDIR}/../../ficl/sparc64
50 LIBFICL=        ${.OBJDIR}/../../ficl/libficl.a
51 .endif
52
53 # Always add MI sources 
54 .PATH:          ${.CURDIR}/../../common
55 .include        "${.CURDIR}/../../common/Makefile.inc"
56 CFLAGS+=        -I${.CURDIR}/../../common
57 CFLAGS+=        -I.
58
59 CLEANFILES+=    vers.c loader.help
60
61 LDFLAGS=        -static
62
63 # Open Firmware standalone support library
64 LIBOFW=         ${.OBJDIR}/../../ofw/libofw/libofw.a
65 CFLAGS+=        -I${.CURDIR}/../../ofw/libofw/
66
67 # where to get libstand from
68 CFLAGS+=        -I${.CURDIR}/../../../../lib/libstand/
69
70 DPADD=          ${LIBFICL} ${LIBOFW} ${LIBSTAND}
71 LDADD=          ${LIBFICL} ${LIBOFW} -lstand
72
73 vers.c: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version
74         sh ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version ${NEWVERSWHAT}
75
76 loader.help: help.common help.sparc64
77         cat ${.ALLSRC} | \
78             awk -f ${.CURDIR}/../../common/merge_help.awk > ${.TARGET}
79
80 .PATH: ${.CURDIR}/../../forth
81 FILES=  loader.help loader.4th support.4th loader.conf
82 FILESDIR_loader.conf=   /boot/defaults
83
84 .if !exists(${DESTDIR}/boot/loader.rc)
85 FILES+= loader.rc
86 .endif
87
88 .include <bsd.prog.mk>