5 .PATH: ${BOOTSRC}/i386/boot2 ${BOOTSRC}/i386/gptboot \
6 ${BOOTSRC}/i386/common ${SASRC}
11 BOOT_COMCONSOLE_PORT?= 0x3f8
12 BOOT_COMCONSOLE_SPEED?= 9600
21 CFLAGS+=-DBOOTPROG=\"isoboot\" \
23 -DSIOPRT=${BOOT_COMCONSOLE_PORT} \
24 -DSIOFMT=${B2SIOFMT} \
25 -DSIOSPD=${BOOT_COMCONSOLE_SPEED} \
27 -I${BOOTSRC}/i386/common \
28 -I${BOOTSRC}/i386/boot2 \
29 -Wall -Waggregate-return -Wbad-function-cast -Wno-cast-align \
30 -Wmissing-declarations -Wmissing-prototypes -Wnested-externs \
31 -Wpointer-arith -Wshadow -Wstrict-prototypes -Wwrite-strings \
32 -Winline -Wno-pointer-sign
34 CFLAGS.gcc+= --param max-inline-insns-single=100
35 CFLAGS.clang+= -Oz ${CLANG_OPT_SMALL}
37 LD_FLAGS+=${LD_FLAGS_BIN}
41 isoboot: gptldr.bin isoboot.bin ${BTXKERN}
42 btxld -v -E ${ORG2} -f bin -b ${BTXKERN} -l gptldr.bin \
43 -o ${.TARGET} isoboot.bin
44 @set -- `ls -l ${.TARGET}`; x=$$((${ISOBOOTSIZE}-$$5)); \
45 echo "$$x bytes available"; test $$x -ge 0
47 CLEANFILES+= gptldr.bin gptldr.out gptldr.o
49 gptldr.bin: gptldr.out
50 ${OBJCOPY} -S -O binary gptldr.out ${.TARGET}
53 ${LD} ${LD_FLAGS} -e start --defsym ORG=${ORG1} -T ${LDSCRIPT} -o ${.TARGET} gptldr.o
55 CLEANFILES+= isoboot.bin isoboot.out isoboot.o sio.o drv.o \
56 cons.o ${OPENCRYPTO_XTS}
58 isoboot.bin: isoboot.out
59 ${OBJCOPY} -S -O binary isoboot.out ${.TARGET}
61 isoboot.out: ${BTXCRT} isoboot.o sio.o drv.o cons.o ${OPENCRYPTO_XTS}
62 ${LD} ${LD_FLAGS} --defsym ORG=${ORG2} -T ${LDSCRIPT} -o ${.TARGET} ${.ALLSRC} ${LIBSA32}
64 .include <bsd.prog.mk>