1 2.include <bsd.init.mk> 3 4PROG= ${LDR} 5INTERNALPROG= 6FILES= ${BOOT} 7MAN= ${BOOT}.8 8SRCS= ${LDR}.S 9CLEANFILES+= ${BOOT} 10 11BOOT= pxeboot 12LDR= pxeldr 13ORG= 0x7c00 14LOADER= loader 15 16.if defined(BOOT_PXELDR_PROBE_KEYBOARD) 17CFLAGS+=-DPROBE_KEYBOARD 18.endif 19 20.if defined(BOOT_PXELDR_ALWAYS_SERIAL) 21CFLAGS+=-DALWAYS_SERIAL 22.endif 23 24CFLAGS+=-I${BOOTSRC}/i386/common 25 26L=${LOADER_DEFAULT_INTERP} 27LOADERBIN= ${BOOTOBJ}/i386/loader_${L}/loader_${L}.bin 28 29CLEANFILES+= ${BOOT}.tmp 30 31${BOOT}: ${LDR} ${LOADER} 32 cat ${LDR} ${LOADER} > ${.TARGET}.tmp 33 ${DD} if=${.TARGET}.tmp of=${.TARGET} bs=2048 conv=sync 34 rm ${.TARGET}.tmp 35 36LDFLAGS+=${LDFLAGS_BIN} 37 38CLEANFILES+= ${LOADER} 39 40# Note: pxeldr.S assumes a.out and will require changes for ELF if the output 41# format is changed to ELF. 42${LOADER}: ${LOADERBIN} ${BTXLDR} ${BTXKERN} 43 btxld -v -f aout -e ${LOADER_ADDRESS} -o ${.TARGET} -l ${BTXLDR} \ 44 -b ${BTXKERN} ${LOADERBIN} 45 46.include <bsd.prog.mk> 47