1 1.27 christos # $NetBSD: Makefile,v 1.27 2019/09/23 13:42:37 christos Exp $ 2 1.1 thorpej 3 1.17 tsutsui S= ${.CURDIR}/../../../.. 4 1.1 thorpej 5 1.3 thorpej BASE?= pxeboot_ia32 6 1.2 thorpej PROG= ${BASE}.bin 7 1.1 thorpej NEWVERSWHAT= "PXE Boot" 8 1.2 thorpej STARTFILE= ${PXESTART} 9 1.2 thorpej RELOC= 0x0 10 1.1 thorpej 11 1.3 thorpej .if (${BASE} != "pxeboot_ia32") 12 1.3 thorpej .PATH.c: ${.CURDIR}/../pxeboot 13 1.3 thorpej .PATH.S: ${.CURDIR}/../pxeboot 14 1.3 thorpej .endif 15 1.1 thorpej 16 1.26 manu SRCS= main.c dev_net.c devopen.c conf.c 17 1.26 manu SRCS+=exec.c exec_multiboot1.c exec_multiboot2.c pxe.c pxe_call.S 18 1.5 drochner # use our own nfs implementation 19 1.5 drochner .PATH: ${.CURDIR}/../libsa 20 1.5 drochner SRCS+= nfs.c 21 1.6 mycroft 22 1.25 christos .include <bsd.init.mk> 23 1.10 mrg 24 1.16 abs .if ${MACHINE_ARCH} == "x86_64" 25 1.11 lukem LDFLAGS+= -Wl,-m,elf_i386 26 1.11 lukem AFLAGS+= -m32 27 1.11 lukem LIBKERN_ARCH= i386 28 1.8 chs KERNMISCMAKEFLAGS="LIBKERN_ARCH=i386" 29 1.8 chs .endif 30 1.8 chs 31 1.6 mycroft CPPFLAGS+= -DSLOW # for libz 32 1.1 thorpej 33 1.3 thorpej .if (${BASE} == "pxeboot_ia32") 34 1.9 dsl # Take config values from patchable header 35 1.9 dsl CPPFLAGS+= -DSUPPORT_SERIAL=boot_params.bp_consdev 36 1.9 dsl CPPFLAGS+= -DCONSPEED=boot_params.bp_conspeed 37 1.9 dsl CPPFLAGS+= -DCONSADDR=boot_params.bp_consaddr 38 1.9 dsl CPPFLAGS+= -DCONSOLE_KEYMAP=boot_params.bp_keymap 39 1.24 christos CPPFLAGS+= -DDIRECT_SERIAL 40 1.1 thorpej # Various serial line configurations 41 1.9 dsl #CPPFLAGS+= -DSUPPORT_SERIAL=CONSDEV_PC -DDIRECT_SERIAL 42 1.1 thorpej # or 43 1.1 thorpej #CPPFLAGS+= -DSUPPORT_SERIAL=CONSDEV_COM0KBD 44 1.1 thorpej # or 45 1.1 thorpej #CPPFLAGS+= -DSUPPORT_SERIAL=CONSDEV_AUTO 46 1.1 thorpej # and maybe 47 1.1 thorpej #CPPFLAGS+= -DDIRECT_SERIAL -DCOMCONS_KEYPRESS -DCONSPEED=57600 48 1.3 thorpej .endif 49 1.3 thorpej 50 1.3 thorpej .if (${BASE} == "pxeboot_ia32_com0") 51 1.3 thorpej CPPFLAGS+= -DSUPPORT_SERIAL=CONSDEV_COM0 -DDIRECT_SERIAL 52 1.3 thorpej .endif 53 1.1 thorpej 54 1.1 thorpej CPPFLAGS+= -DSUPPORT_BOOTP -DSUPPORT_DHCP 55 1.1 thorpej CPPFLAGS+= -DSUPPORT_TFTP 56 1.1 thorpej CPPFLAGS+= -DSUPPORT_NFS 57 1.5 drochner #CPPFLAGS+= -DNFS_NOSYMLINK 58 1.1 thorpej 59 1.1 thorpej CPPFLAGS+= -DPASS_MEMMAP 60 1.13 salo CPPFLAGS+= -DEPIA_HACK 61 1.1 thorpej 62 1.18 drochner # modules and boot.cfg need special DHCP server setup, disable 63 1.18 drochner # per default for compatibility with existing setups 64 1.20 drochner CPPFLAGS+= -DBOOTPARAM_DEFFLAGS=0x0c 65 1.18 drochner 66 1.1 thorpej #CFLAGS= -O2 -fomit-frame-pointer -fno-defer-pop 67 1.1 thorpej CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes -Wno-main 68 1.1 thorpej 69 1.1 thorpej SAMISCCPPFLAGS+= -DHEAP_START=0x10000 -DHEAP_LIMIT=0x30000 70 1.2 thorpej SAMISCMAKEFLAGS+= SA_USE_CREAD=yes # Read compressed kernels 71 1.1 thorpej 72 1.7 dbj CPPFLAGS+= -DPASS_BIOSGEOM 73 1.7 dbj # if you don't use -DPASS_BIOSGEOM, then set I386_INCLUDE_DISK=no 74 1.7 dbj #I386MISCMAKEFLAGS= I386_INCLUDE_DISK=no 75 1.1 thorpej 76 1.3 thorpej .if (${BASE} == "pxeboot_ia32") 77 1.1 thorpej VERSIONFILE= ${.CURDIR}/version 78 1.3 thorpej .else 79 1.3 thorpej VERSIONFILE= ${.CURDIR}/../pxeboot/version 80 1.3 thorpej .endif 81 1.1 thorpej 82 1.1 thorpej .include "../Makefile.booters" 83 1.14 he 84 1.14 he release: check_RELEASEDIR 85 1.14 he ${HOST_INSTALL_FILE} -m ${BINMODE} ${PROG} \ 86 1.27 christos ${RELEASEDIR}/${RELEASEMACHINEDIR}/installation/misc 87