4 NEWVERSWHAT= "U-Boot loader" ${MACHINE_ARCH}
9 # Architecture-specific loader code
10 SRCS= start.S conf.c vers.c
12 LOADER_DISK_SUPPORT?= no
13 LOADER_UFS_SUPPORT?= no
14 LOADER_CD9660_SUPPORT?= no
15 LOADER_EXT2FS_SUPPORT?= no
16 LOADER_NET_SUPPORT?= yes
17 LOADER_NFS_SUPPORT?= yes
18 LOADER_TFTP_SUPPORT?= no
19 LOADER_GZIP_SUPPORT?= no
20 LOADER_BZIP2_SUPPORT?= no
22 .if ${LOADER_DISK_SUPPORT} == "yes"
23 CFLAGS+= -DLOADER_DISK_SUPPORT
25 .if ${LOADER_UFS_SUPPORT} == "yes"
26 CFLAGS+= -DLOADER_UFS_SUPPORT
28 .if ${LOADER_CD9660_SUPPORT} == "yes"
29 CFLAGS+= -DLOADER_CD9660_SUPPORT
31 .if ${LOADER_EXT2FS_SUPPORT} == "yes"
32 CFLAGS+= -DLOADER_EXT2FS_SUPPORT
34 .if ${LOADER_GZIP_SUPPORT} == "yes"
35 CFLAGS+= -DLOADER_GZIP_SUPPORT
37 .if ${LOADER_BZIP2_SUPPORT} == "yes"
38 CFLAGS+= -DLOADER_BZIP2_SUPPORT
40 .if ${LOADER_NET_SUPPORT} == "yes"
41 CFLAGS+= -DLOADER_NET_SUPPORT
43 .if ${LOADER_NFS_SUPPORT} == "yes"
44 CFLAGS+= -DLOADER_NFS_SUPPORT
46 .if ${LOADER_TFTP_SUPPORT} == "yes"
47 CFLAGS+= -DLOADER_TFTP_SUPPORT
50 .if !defined(NO_FORTH)
53 CFLAGS+= -DBOOT_FORTH -I${.CURDIR}/../../ficl -I${.CURDIR}/../../ficl/powerpc
54 LIBFICL= ${.OBJDIR}/../../ficl/libficl.a
57 # Always add MI sources
58 .PATH: ${.CURDIR}/../../common
59 .include "${.CURDIR}/../../common/Makefile.inc"
60 CFLAGS+= -I${.CURDIR}/../../common
63 CLEANFILES+= vers.c ${PROG}.help
65 CFLAGS+= -ffreestanding
67 LDFLAGS= -nostdlib -static -T ${.CURDIR}/ldscript.powerpc
69 # Pull in common loader code
70 .PATH: ${.CURDIR}/../../uboot/common
71 .include "${.CURDIR}/../../uboot/common/Makefile.inc"
72 CFLAGS+= -I${.CURDIR}/../../uboot/common
74 # U-Boot standalone support library
75 LIBUBOOT= ${.OBJDIR}/../../uboot/lib/libuboot.a
76 CFLAGS+= -I${.CURDIR}/../../uboot/lib
77 CFLAGS+= -I${.OBJDIR}/../../uboot/lib
79 # where to get libstand from
80 CFLAGS+= -I${.CURDIR}/../../../../lib/libstand/
82 DPADD= ${LIBFICL} ${LIBUBOOT} ${LIBSTAND}
83 LDADD= ${LIBFICL} ${LIBUBOOT} -lstand
85 vers.c: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version
86 sh ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version ${NEWVERSWHAT}
88 ${PROG}.help: help.common help.uboot
90 awk -f ${.CURDIR}/../../common/merge_help.awk > ${.TARGET}
92 .PATH: ${.CURDIR}/../../forth
95 .include <bsd.prog.mk>