diff options
author | Ruslan Ermilov <ru@FreeBSD.org> | 2004-02-12 08:10:34 +0000 |
---|---|---|
committer | Ruslan Ermilov <ru@FreeBSD.org> | 2004-02-12 08:10:34 +0000 |
commit | 5c8f32a869ce6c872345ac916a6462aa036b19d6 (patch) | |
tree | 791ce63a1fe22f573e4bf7cf6091279cb40b609a /sys/boot | |
parent | aa0b7126ba7f43ba2235bbb4c626ad6b517fae7c (diff) | |
download | src-5c8f32a869ce6c872345ac916a6462aa036b19d6.tar.gz src-5c8f32a869ce6c872345ac916a6462aa036b19d6.zip |
Tidy up makefiles.
Tested by: marcel
Notes
Notes:
svn path=/head/; revision=125729
Diffstat (limited to 'sys/boot')
-rw-r--r-- | sys/boot/efi/Makefile.inc | 3 | ||||
-rw-r--r-- | sys/boot/efi/libefi/Makefile | 15 | ||||
-rw-r--r-- | sys/boot/efi/loader/Makefile | 92 | ||||
-rw-r--r-- | sys/boot/ia64/Makefile.inc | 3 | ||||
-rw-r--r-- | sys/boot/ia64/efi/Makefile | 92 | ||||
-rw-r--r-- | sys/boot/ia64/libski/Makefile | 17 | ||||
-rw-r--r-- | sys/boot/ia64/ski/Makefile | 58 | ||||
-rw-r--r-- | sys/boot/ia64/skiload/Makefile | 58 |
8 files changed, 74 insertions, 264 deletions
diff --git a/sys/boot/efi/Makefile.inc b/sys/boot/efi/Makefile.inc index 81f7724c1d22..2668708befb5 100644 --- a/sys/boot/efi/Makefile.inc +++ b/sys/boot/efi/Makefile.inc @@ -1,4 +1,7 @@ # $FreeBSD$ +BINDIR?= /boot + # Options used when building app-specific efi components CFLAGS+= -ffreestanding -fshort-wchar -Wformat +LDFLAGS+= -nostdlib diff --git a/sys/boot/efi/libefi/Makefile b/sys/boot/efi/libefi/Makefile index bd8e034fa436..ee9a429d37a8 100644 --- a/sys/boot/efi/libefi/Makefile +++ b/sys/boot/efi/libefi/Makefile @@ -12,28 +12,21 @@ SRCS+= delay.c efifs.c efinet.c elf_freebsd.c bootinfo.c pal.S SRCS+= efifpswa.c .endif -CFLAGS+= -ffreestanding -fpic +CFLAGS+= -fpic CFLAGS+= -I${.CURDIR}/../include CFLAGS+= -I${.CURDIR}/../include/${MACHINE_ARCH} -CFLAGS+= -I${.CURDIR}/../../../../lib/libstand/ +CFLAGS+= -I${.CURDIR}/../../../../lib/libstand # Pick up the bootstrap header for some interface items -CFLAGS+= -I${.CURDIR}/../../common -I${.CURDIR}/../../.. -I. +CFLAGS+= -I${.CURDIR}/../../common .if ${MACHINE_ARCH} == "powerpc" CFLAGS+= -msoft-float .endif -.ifdef(BOOT_DISK_DEBUG) +.if defined(BOOT_DISK_DEBUG) # Make the disk code more talkative CFLAGS+= -DDISK_DEBUG .endif -machine: - ln -sf ${.CURDIR}/../../../${MACHINE_ARCH}/include machine - -CLEANFILES+= machine - .include <bsd.lib.mk> - -beforedepend ${OBJS}: machine diff --git a/sys/boot/efi/loader/Makefile b/sys/boot/efi/loader/Makefile index e2f9a84ea786..8197b6a7acbe 100644 --- a/sys/boot/efi/loader/Makefile +++ b/sys/boot/efi/loader/Makefile @@ -1,76 +1,45 @@ # $FreeBSD$ -.PATH: ${.CURDIR}/../common - -BASE= loader -PROG= ${BASE}.efi +PROG= loader.sym +INTERNALPROG= NOMAN= NEWVERSWHAT= "EFI boot" ${MACHINE_ARCH} -BINDIR?= /boot -STRIP= # We must not strip loader.efi at install time. -SRCS+= main.c conf.c dev_net.c +SRCS= start.S main.c conf.c dev_net.c vers.c -CFLAGS+= -ffreestanding +.PATH: ${.CURDIR}/../libefi/arch/${MACHINE_ARCH} .if !defined(NOFORTH) # Enable BootForth BOOT_FORTH= yes CFLAGS+= -DBOOT_FORTH CFLAGS+= -I${.CURDIR}/../../ficl -I${.CURDIR}/../../ficl/${MACHINE_ARCH} -.if exists(${.OBJDIR}/../../ficl/libficl.a) LIBFICL= ${.OBJDIR}/../../ficl/libficl.a -.else -LIBFICL= ${.CURDIR}/../../ficl/libficl.a -.endif -.endif - -# where to get libstand from -.if exists(${.OBJDIR}/../../../../lib/libstand/libstand.a) -LIBSTAND= ${.OBJDIR}/../../../../lib/libstand/libstand.a -.else -LIBSTAND= ${.CURDIR}/../../../../lib/libstand/libstand.a .endif -.if exists(${.OBJDIR}/../libefi/libefi.a) LIBEFI= ${.OBJDIR}/../libefi/libefi.a -.else -LIBEFI= ${.CURDIR}/../libefi/libefi.a -.endif # Always add MI sources .PATH: ${.CURDIR}/../../common -.include <${.CURDIR}/../../common/Makefile.inc> +.include "${.CURDIR}/../../common/Makefile.inc" -CFLAGS+= -I- CFLAGS+= -I${.CURDIR}/../include CFLAGS+= -I${.CURDIR}/../include/${MACHINE_ARCH} -CFLAGS+= -I${.CURDIR}/../../common -I${.CURDIR} -CFLAGS+= -I${.CURDIR}/../../.. -I. +CFLAGS+= -I${.CURDIR}/../../common CFLAGS+= -I${.CURDIR}/../libefi CFLAGS+= -I${.CURDIR}/../../../../lib/libstand CFLAGS+= -DLOADER LDSCRIPT= ${.CURDIR}/../libefi/arch/${MACHINE_ARCH}/ldscript.${MACHINE_ARCH} -LDFLAGS= -nostdlib -T ${LDSCRIPT} -shared -Bsymbolic +LDFLAGS= -Wl,-T${LDSCRIPT} -Wl,-M,-Map,loader.list -shared -symbolic OBJCOPY?= objcopy -CLEANFILES+= setdef0.c setdef0.o setdef1.c setdef1.o setdefs.h start.o \ - vers.c vers.o ${BASE}.efi ${BASE}.sym ${BASE}.list -CLEANFILES+= loader.help -CLEANFILES+= machine - -CRT= start.o - -all: ${BASE} +CLEANFILES= vers.c loader.efi loader.list loader.help -vers.o: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version +vers.c: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version sh ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version ${NEWVERSWHAT} - ${CC} -c vers.c -${BASE}: ${BASE}.efi ${BASE}.help - -${BASE}.efi: ${BASE}.sym +loader.efi: loader.sym ${OBJCOPY} -j .text \ -j .hash \ -j .data \ @@ -81,43 +50,22 @@ ${BASE}.efi: ${BASE}.sym -j .dynsym \ -j .dynstr \ --target=efi-app-${MACHINE_ARCH} \ - ${BASE}.sym ${BASE}.efi + loader.sym loader.efi -${BASE}.help: help.common +loader.help: help.common cat ${.ALLSRC} | awk -f ${.CURDIR}/../../common/merge_help.awk \ > ${.TARGET} -beforeinstall: -.if exists(${.OBJDIR}/loader.help) - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.OBJDIR}/${BASE}.help ${DESTDIR}/boot -.else - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/${BASE}.help ${DESTDIR}/boot -.endif +.PATH: ${.CURDIR}/../../forth +FILES= loader.efi loader.help loader.4th support.4th loader.conf +FILESMODE_loader.efi= ${BINMODE} +FILESDIR_loader.conf= /boot/defaults + .if !exists(${DESTDIR}/boot/loader.rc) - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/../../forth/loader.rc ${DESTDIR}/boot +FILES+= loader.rc .endif - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/../../forth/loader.4th ${DESTDIR}/boot - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/../../forth/support.4th ${DESTDIR}/boot - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/../../forth/loader.conf ${DESTDIR}/boot/defaults - -# Other fragments still to be brought in from ../Makfile.booters? -start.o: ${.CURDIR}/../libefi/arch/${MACHINE_ARCH}/start.S - ${CC} -c ${CFLAGS} ${.IMPSRC} - -machine: - ln -sf ${.CURDIR}/../../../${MACHINE_ARCH}/include machine +DPADD= ${LIBFICL} ${LIBEFI} ${LIBSTAND} +LDADD= ${LIBFICL} ${LIBEFI} -lstand .include <bsd.prog.mk> - -${BASE}.sym: ${OBJS} ${LIBFICL} ${LIBEFI} ${LIBSTAND} ${CRT} vers.o - ${LD} ${LDFLAGS} -o ${BASE}.sym -M ${CRT} ${OBJS} vers.o \ - ${LIBFICL} ${LIBEFI} ${LIBSTAND} > ${.OBJDIR}/${BASE}.list - -beforedepend ${OBJS}: machine diff --git a/sys/boot/ia64/Makefile.inc b/sys/boot/ia64/Makefile.inc index 3000e04e9737..2e9a113df387 100644 --- a/sys/boot/ia64/Makefile.inc +++ b/sys/boot/ia64/Makefile.inc @@ -1,4 +1,7 @@ # $FreeBSD$ +BINDIR?= /boot + # Options used when building standalone components CFLAGS+= -ffreestanding -fshort-wchar -Wformat +LDFLAGS+= -nostdlib diff --git a/sys/boot/ia64/efi/Makefile b/sys/boot/ia64/efi/Makefile index e2f9a84ea786..8197b6a7acbe 100644 --- a/sys/boot/ia64/efi/Makefile +++ b/sys/boot/ia64/efi/Makefile @@ -1,76 +1,45 @@ # $FreeBSD$ -.PATH: ${.CURDIR}/../common - -BASE= loader -PROG= ${BASE}.efi +PROG= loader.sym +INTERNALPROG= NOMAN= NEWVERSWHAT= "EFI boot" ${MACHINE_ARCH} -BINDIR?= /boot -STRIP= # We must not strip loader.efi at install time. -SRCS+= main.c conf.c dev_net.c +SRCS= start.S main.c conf.c dev_net.c vers.c -CFLAGS+= -ffreestanding +.PATH: ${.CURDIR}/../libefi/arch/${MACHINE_ARCH} .if !defined(NOFORTH) # Enable BootForth BOOT_FORTH= yes CFLAGS+= -DBOOT_FORTH CFLAGS+= -I${.CURDIR}/../../ficl -I${.CURDIR}/../../ficl/${MACHINE_ARCH} -.if exists(${.OBJDIR}/../../ficl/libficl.a) LIBFICL= ${.OBJDIR}/../../ficl/libficl.a -.else -LIBFICL= ${.CURDIR}/../../ficl/libficl.a -.endif -.endif - -# where to get libstand from -.if exists(${.OBJDIR}/../../../../lib/libstand/libstand.a) -LIBSTAND= ${.OBJDIR}/../../../../lib/libstand/libstand.a -.else -LIBSTAND= ${.CURDIR}/../../../../lib/libstand/libstand.a .endif -.if exists(${.OBJDIR}/../libefi/libefi.a) LIBEFI= ${.OBJDIR}/../libefi/libefi.a -.else -LIBEFI= ${.CURDIR}/../libefi/libefi.a -.endif # Always add MI sources .PATH: ${.CURDIR}/../../common -.include <${.CURDIR}/../../common/Makefile.inc> +.include "${.CURDIR}/../../common/Makefile.inc" -CFLAGS+= -I- CFLAGS+= -I${.CURDIR}/../include CFLAGS+= -I${.CURDIR}/../include/${MACHINE_ARCH} -CFLAGS+= -I${.CURDIR}/../../common -I${.CURDIR} -CFLAGS+= -I${.CURDIR}/../../.. -I. +CFLAGS+= -I${.CURDIR}/../../common CFLAGS+= -I${.CURDIR}/../libefi CFLAGS+= -I${.CURDIR}/../../../../lib/libstand CFLAGS+= -DLOADER LDSCRIPT= ${.CURDIR}/../libefi/arch/${MACHINE_ARCH}/ldscript.${MACHINE_ARCH} -LDFLAGS= -nostdlib -T ${LDSCRIPT} -shared -Bsymbolic +LDFLAGS= -Wl,-T${LDSCRIPT} -Wl,-M,-Map,loader.list -shared -symbolic OBJCOPY?= objcopy -CLEANFILES+= setdef0.c setdef0.o setdef1.c setdef1.o setdefs.h start.o \ - vers.c vers.o ${BASE}.efi ${BASE}.sym ${BASE}.list -CLEANFILES+= loader.help -CLEANFILES+= machine - -CRT= start.o - -all: ${BASE} +CLEANFILES= vers.c loader.efi loader.list loader.help -vers.o: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version +vers.c: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version sh ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version ${NEWVERSWHAT} - ${CC} -c vers.c -${BASE}: ${BASE}.efi ${BASE}.help - -${BASE}.efi: ${BASE}.sym +loader.efi: loader.sym ${OBJCOPY} -j .text \ -j .hash \ -j .data \ @@ -81,43 +50,22 @@ ${BASE}.efi: ${BASE}.sym -j .dynsym \ -j .dynstr \ --target=efi-app-${MACHINE_ARCH} \ - ${BASE}.sym ${BASE}.efi + loader.sym loader.efi -${BASE}.help: help.common +loader.help: help.common cat ${.ALLSRC} | awk -f ${.CURDIR}/../../common/merge_help.awk \ > ${.TARGET} -beforeinstall: -.if exists(${.OBJDIR}/loader.help) - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.OBJDIR}/${BASE}.help ${DESTDIR}/boot -.else - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/${BASE}.help ${DESTDIR}/boot -.endif +.PATH: ${.CURDIR}/../../forth +FILES= loader.efi loader.help loader.4th support.4th loader.conf +FILESMODE_loader.efi= ${BINMODE} +FILESDIR_loader.conf= /boot/defaults + .if !exists(${DESTDIR}/boot/loader.rc) - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/../../forth/loader.rc ${DESTDIR}/boot +FILES+= loader.rc .endif - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/../../forth/loader.4th ${DESTDIR}/boot - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/../../forth/support.4th ${DESTDIR}/boot - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/../../forth/loader.conf ${DESTDIR}/boot/defaults - -# Other fragments still to be brought in from ../Makfile.booters? -start.o: ${.CURDIR}/../libefi/arch/${MACHINE_ARCH}/start.S - ${CC} -c ${CFLAGS} ${.IMPSRC} - -machine: - ln -sf ${.CURDIR}/../../../${MACHINE_ARCH}/include machine +DPADD= ${LIBFICL} ${LIBEFI} ${LIBSTAND} +LDADD= ${LIBFICL} ${LIBEFI} -lstand .include <bsd.prog.mk> - -${BASE}.sym: ${OBJS} ${LIBFICL} ${LIBEFI} ${LIBSTAND} ${CRT} vers.o - ${LD} ${LDFLAGS} -o ${BASE}.sym -M ${CRT} ${OBJS} vers.o \ - ${LIBFICL} ${LIBEFI} ${LIBSTAND} > ${.OBJDIR}/${BASE}.list - -beforedepend ${OBJS}: machine diff --git a/sys/boot/ia64/libski/Makefile b/sys/boot/ia64/libski/Makefile index 02889381886a..310d21eab8a6 100644 --- a/sys/boot/ia64/libski/Makefile +++ b/sys/boot/ia64/libski/Makefile @@ -7,30 +7,21 @@ SRCS= skiconsole.c time.c copy.c devicename.c module.c exit.c SRCS+= delay.c skifs.c elf_freebsd.c bootinfo.c ssc.c SRCS+= acpi_stub.c efi_stub.c pal_stub.S sal_stub.c -CFLAGS+= -ffreestanding -fpic -g -CFLAGS+= -I${.CURDIR}/../include -CFLAGS+= -I${.CURDIR}/../include/${MACHINE_ARCH} -CFLAGS+= -I${.CURDIR}/../../../../lib/libstand/ +CFLAGS+= -fpic +CFLAGS+= -I${.CURDIR}/../../../../lib/libstand CFLAGS+= -I${.CURDIR}/../../efi/include CFLAGS+= -I${.CURDIR}/../../efi/include/${MACHINE_ARCH} # Pick up the bootstrap header for some interface items -CFLAGS+= -I${.CURDIR}/../../common -I${.CURDIR}/../../.. -I. +CFLAGS+= -I${.CURDIR}/../../common -I${.CURDIR}/../../.. .if ${MACHINE_ARCH} == "powerpc" CFLAGS+= -msoft-float .endif -.ifdef(BOOT_DISK_DEBUG) +.if defined(BOOT_DISK_DEBUG) # Make the disk code more talkative CFLAGS+= -DDISK_DEBUG .endif -machine: - ln -sf ${.CURDIR}/../../../${MACHINE_ARCH}/include machine - -CLEANFILES+= machine - .include <bsd.lib.mk> - -beforedepend ${OBJS}: machine diff --git a/sys/boot/ia64/ski/Makefile b/sys/boot/ia64/ski/Makefile index 5d8934086132..2c53e9b32dd5 100644 --- a/sys/boot/ia64/ski/Makefile +++ b/sys/boot/ia64/ski/Makefile @@ -8,78 +8,40 @@ NEWVERSWHAT= "ia64 SKI boot" ${MACHINE_ARCH} BINDIR?= /boot STRIP= # We must not strip skiload at install time. -SRCS+= conf.c main.c start.S - -CFLAGS+= -ffreestanding +SRCS= conf.c main.c start.S vers.c .if !defined(NOFORTH) # Enable BootForth BOOT_FORTH= yes CFLAGS+= -DBOOT_FORTH CFLAGS+= -I${.CURDIR}/../../ficl -I${.CURDIR}/../../ficl/${MACHINE_ARCH} -.if exists(${.OBJDIR}/../../ficl/libficl.a) LIBFICL= ${.OBJDIR}/../../ficl/libficl.a -.else -LIBFICL= ${.CURDIR}/../../ficl/libficl.a -.endif .endif -# where to get libstand from -.if exists(${.OBJDIR}/../../../../lib/libstand/libstand.a) -LIBSTAND= ${.OBJDIR}/../../../../lib/libstand/libstand.a -.else -LIBSTAND= ${.CURDIR}/../../../../lib/libstand/libstand.a -.endif - -.if exists(${.OBJDIR}/../libski/libski.a) LIBSKI= ${.OBJDIR}/../libski/libski.a -.else -LIBSKI= ${.CURDIR}/../libski/libski.a -.endif # Always add MI sources .PATH: ${.CURDIR}/../../common -.include <${.CURDIR}/../../common/Makefile.inc> +.include "${.CURDIR}/../../common/Makefile.inc" -CFLAGS+= -I- -CFLAGS+= -I${.CURDIR}/../include -CFLAGS+= -I${.CURDIR}/../include/${MACHINE_ARCH} -CFLAGS+= -I${.CURDIR}/../../common -I${.CURDIR} -CFLAGS+= -I${.CURDIR}/../../.. -I. +CFLAGS+= -I${.CURDIR}/../../common CFLAGS+= -I${.CURDIR}/../libski CFLAGS+= -DLOADER -LDFLAGS= -nostdlib -T ${.CURDIR}/ldscript.ia64 +LDFLAGS= -Wl,-T${.CURDIR}/ldscript.ia64 -Wl,-M,-Map,${PROG}.list -CLEANFILES+= vers.c vers.o ${PROG}.list -CLEANFILES+= loader.help -CLEANFILES+= machine +CLEANFILES= vers.c ${PROG}.list ${PROG}.help -all: ${PROG} - -vers.o: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version +vers.c: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version sh ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version ${NEWVERSWHAT} - ${CC} -c vers.c -${PROG}.help: help.common help.efi +${PROG}.help: help.common cat ${.ALLSRC} | awk -f ${.CURDIR}/../../common/merge_help.awk \ > ${.TARGET} -beforeinstall: -.if exists(${.OBJDIR}/${PROG}.help) - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.OBJDIR}/${PROG}.help ${DESTDIR}/boot -.endif - -machine: - ln -sf ${.CURDIR}/../../../${MACHINE_ARCH}/include machine +FILES= ${PROG}.help -${PROG}: ${OBJS} ${LIBFICL} ${LIBSKI} ${LIBSTAND} vers.o - ${LD} ${LDFLAGS} -o ${PROG} -M \ - ${OBJS} vers.o \ - ${LIBFICL} ${LIBSTAND} ${LIBSKI} ${LIBSTAND} \ - > ${.OBJDIR}/${PROG}.list +DPADD= ${LIBFICL} ${LIBSKI} ${LIBSTAND} +LDADD= ${LIBFICL} ${LIBSKI} -lstand .include <bsd.prog.mk> - -beforedepend ${OBJS}: machine diff --git a/sys/boot/ia64/skiload/Makefile b/sys/boot/ia64/skiload/Makefile index 5d8934086132..2c53e9b32dd5 100644 --- a/sys/boot/ia64/skiload/Makefile +++ b/sys/boot/ia64/skiload/Makefile @@ -8,78 +8,40 @@ NEWVERSWHAT= "ia64 SKI boot" ${MACHINE_ARCH} BINDIR?= /boot STRIP= # We must not strip skiload at install time. -SRCS+= conf.c main.c start.S - -CFLAGS+= -ffreestanding +SRCS= conf.c main.c start.S vers.c .if !defined(NOFORTH) # Enable BootForth BOOT_FORTH= yes CFLAGS+= -DBOOT_FORTH CFLAGS+= -I${.CURDIR}/../../ficl -I${.CURDIR}/../../ficl/${MACHINE_ARCH} -.if exists(${.OBJDIR}/../../ficl/libficl.a) LIBFICL= ${.OBJDIR}/../../ficl/libficl.a -.else -LIBFICL= ${.CURDIR}/../../ficl/libficl.a -.endif .endif -# where to get libstand from -.if exists(${.OBJDIR}/../../../../lib/libstand/libstand.a) -LIBSTAND= ${.OBJDIR}/../../../../lib/libstand/libstand.a -.else -LIBSTAND= ${.CURDIR}/../../../../lib/libstand/libstand.a -.endif - -.if exists(${.OBJDIR}/../libski/libski.a) LIBSKI= ${.OBJDIR}/../libski/libski.a -.else -LIBSKI= ${.CURDIR}/../libski/libski.a -.endif # Always add MI sources .PATH: ${.CURDIR}/../../common -.include <${.CURDIR}/../../common/Makefile.inc> +.include "${.CURDIR}/../../common/Makefile.inc" -CFLAGS+= -I- -CFLAGS+= -I${.CURDIR}/../include -CFLAGS+= -I${.CURDIR}/../include/${MACHINE_ARCH} -CFLAGS+= -I${.CURDIR}/../../common -I${.CURDIR} -CFLAGS+= -I${.CURDIR}/../../.. -I. +CFLAGS+= -I${.CURDIR}/../../common CFLAGS+= -I${.CURDIR}/../libski CFLAGS+= -DLOADER -LDFLAGS= -nostdlib -T ${.CURDIR}/ldscript.ia64 +LDFLAGS= -Wl,-T${.CURDIR}/ldscript.ia64 -Wl,-M,-Map,${PROG}.list -CLEANFILES+= vers.c vers.o ${PROG}.list -CLEANFILES+= loader.help -CLEANFILES+= machine +CLEANFILES= vers.c ${PROG}.list ${PROG}.help -all: ${PROG} - -vers.o: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version +vers.c: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version sh ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version ${NEWVERSWHAT} - ${CC} -c vers.c -${PROG}.help: help.common help.efi +${PROG}.help: help.common cat ${.ALLSRC} | awk -f ${.CURDIR}/../../common/merge_help.awk \ > ${.TARGET} -beforeinstall: -.if exists(${.OBJDIR}/${PROG}.help) - ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.OBJDIR}/${PROG}.help ${DESTDIR}/boot -.endif - -machine: - ln -sf ${.CURDIR}/../../../${MACHINE_ARCH}/include machine +FILES= ${PROG}.help -${PROG}: ${OBJS} ${LIBFICL} ${LIBSKI} ${LIBSTAND} vers.o - ${LD} ${LDFLAGS} -o ${PROG} -M \ - ${OBJS} vers.o \ - ${LIBFICL} ${LIBSTAND} ${LIBSKI} ${LIBSTAND} \ - > ${.OBJDIR}/${PROG}.list +DPADD= ${LIBFICL} ${LIBSKI} ${LIBSTAND} +LDADD= ${LIBFICL} ${LIBSKI} -lstand .include <bsd.prog.mk> - -beforedepend ${OBJS}: machine |