1# $FreeBSD$ 2 3.include <bsd.init.mk> 4 5PROG= boot1.elf 6NEWVERSWHAT= "Open Firmware boot block" ${MACHINE_ARCH} 7INSTALLFLAGS= -b 8 9FILES= boot1.hfs 10SRCS= boot1.c ashldi3.c syncicache.c 11 12CFLAGS+=-I${LDRSRC} 13LDFLAGS=-nostdlib -static -Wl,-N 14 15.PATH: ${SYSDIR}/libkern ${SRCTOP}/lib/libc/powerpc/gen ${.CURDIR} 16 17# The following inserts out objects into a template HFS 18# created by generate-hfs.sh 19 20.include "${.CURDIR}/Makefile.hfs" 21 22boot1.hfs: boot1.elf bootinfo.txt 23 echo ${.OBJDIR} 24 uudecode ${.CURDIR}/hfs.tmpl.bz2.uu 25 mv hfs.tmpl.bz2 ${.TARGET}.bz2 26 bzip2 -f -d ${.TARGET}.bz2 27 ${DD} if=boot1.elf of=${.TARGET} seek=${BOOT1_OFFSET} conv=notrunc 28 ${DD} if=${.CURDIR}/bootinfo.txt of=${.TARGET} seek=${BOOTINFO_OFFSET} \ 29 conv=notrunc 30 31CLEANFILES+= boot1.hfs 32 33.include <bsd.prog.mk> 34 35