--- modules/ipfw/Makefile (revision 337573) +++ modules/ipfw/Makefile (working copy) @@ -7,7 +7,7 @@ SRCS= ip_fw2.c ip_fw_pfil.c ip_fw_bpf.c SRCS+= ip_fw_dynamic.c ip_fw_log.c ip_fw_eaction.c SRCS+= ip_fw_sockopt.c ip_fw_table.c ip_fw_table_algo.c ip_fw_iface.c SRCS+= ip_fw_table_value.c -SRCS+= opt_inet.h opt_inet6.h opt_ipdivert.h opt_ipfw.h +SRCS+= opt_inet.h opt_inet6.h opt_ipdivert.h opt_ipfw.h opt_global.h CFLAGS+= -DIPFIREWALL -I${SRCTOP}/sys/contrib/ck/include # --- modules/ipfw_nat/Makefile (revision 337573) +++ modules/ipfw_nat/Makefile (working copy) @@ -3,6 +3,6 @@ .PATH: ${SRCTOP}/sys/netpfil/ipfw KMOD= ipfw_nat -SRCS= ip_fw_nat.c +SRCS= ip_fw_nat.c opt_global.h .include --- modules/ipfw_nat64/Makefile (revision 337573) +++ modules/ipfw_nat64/Makefile (working copy) @@ -6,8 +6,6 @@ KMOD= ipfw_nat64 SRCS= ip_fw_nat64.c nat64_translate.c SRCS+= nat64lsn.c nat64lsn_control.c SRCS+= nat64stl.c nat64stl_control.c -SRCS+= opt_ipfw.h +SRCS+= opt_ipfw.h opt_global.h -#CFLAGS+= -DIPFIREWALL_NAT64_DIRECT_OUTPUT - .include --- modules/ipfw_nptv6/Makefile (revision 337573) +++ modules/ipfw_nptv6/Makefile (working copy) @@ -3,6 +3,6 @@ .PATH: ${SRCTOP}/sys/netpfil/ipfw/nptv6 KMOD= ipfw_nptv6 -SRCS= ip_fw_nptv6.c nptv6.c opt_ipfw.h +SRCS= ip_fw_nptv6.c nptv6.c opt_ipfw.h opt_global.h .include --- modules/ipfw_pmod/Makefile (revision 337573) +++ modules/ipfw_pmod/Makefile (working copy) @@ -3,6 +3,6 @@ .PATH: ${SRCTOP}/sys/netpfil/ipfw/pmod KMOD= ipfw_pmod -SRCS= ip_fw_pmod.c tcpmod.c opt_inet.h opt_inet6.h +SRCS= ip_fw_pmod.c tcpmod.c opt_inet.h opt_inet6.h opt_global.h .include --- modules/ipsec/Makefile (revision 337573) +++ modules/ipsec/Makefile (working copy) @@ -5,7 +5,7 @@ KMOD= ipsec SRCS= if_ipsec.c ipsec.c ipsec_input.c ipsec_mbuf.c ipsec_mod.c \ ipsec_output.c xform_ah.c xform_esp.c xform_ipcomp.c \ - opt_inet.h opt_inet6.h opt_ipsec.h opt_sctp.h + opt_inet.h opt_inet6.h opt_ipsec.h opt_sctp.h opt_global.h SRCS.INET= udpencap.c opt_ipsec.h: --- modules/pf/Makefile (revision 337573) +++ modules/pf/Makefile (working copy) @@ -16,10 +16,6 @@ opt_pf.h: echo "#define DEV_PFLOG 1" >> ${.TARGET} echo "#define DEV_PFSYNC 1" >> ${.TARGET} -.if defined(VIMAGE) -opt_global.h: - echo "#define VIMAGE 1" >> ${.TARGET} .endif -.endif .include --- modules/pflog/Makefile (revision 337573) +++ modules/pflog/Makefile (working copy) @@ -7,12 +7,4 @@ SRCS= if_pflog.c \ opt_pf.h opt_inet.h opt_inet6.h opt_bpf.h opt_global.h SRCS+= bus_if.h device_if.h -.if !defined(KERNBUILDDIR) -.if defined(VIMAGE) -opt_global.h: - echo "#define VIMAGE 1" >> ${.TARGET} -CFLAGS+= -include opt_global.h -.endif -.endif - .include --- modules/pfsync/Makefile (revision 337573) +++ modules/pfsync/Makefile (working copy) @@ -7,12 +7,4 @@ SRCS= if_pfsync.c \ opt_pf.h opt_inet.h opt_inet6.h opt_global.h SRCS+= bus_if.h device_if.h -.if !defined(KERNBUILDDIR) -.if defined(VIMAGE) -opt_global.h: - echo "#define VIMAGE 1" >> ${.TARGET} -CFLAGS+= -include opt_global.h -.endif -.endif - .include --- modules/tcp/tcpmd5/Makefile (revision 337573) +++ modules/tcp/tcpmd5/Makefile (working copy) @@ -3,7 +3,7 @@ .PATH: ${SRCTOP}/sys/netipsec KMOD= tcpmd5 -SRCS= xform_tcp.c opt_inet.h opt_inet6.h opt_ipsec.h +SRCS= xform_tcp.c opt_inet.h opt_inet6.h opt_ipsec.h opt_global.h opt_ipsec.h: @echo "#define IPSEC_SUPPORT 1" > ${.TARGET} --- conf/config.mk (revision 337573) +++ conf/config.mk (working copy) @@ -10,6 +10,10 @@ .if !defined(KERNBUILDDIR) opt_bpf.h: echo "#define DEV_BPF 1" > ${.TARGET} +.if ${MK_VIMAGE} != "no" +opt_global.h: + @echo "#define VIMAGE 1" > ${.TARGET} +.endif .if ${MK_INET_SUPPORT} != "no" opt_inet.h: @echo "#define INET 1" > ${.TARGET} --- conf/kern.opts.mk (revision 337573) +++ conf/kern.opts.mk (working copy) @@ -44,6 +44,7 @@ __DEFAULT_YES_OPTIONS = \ SOURCELESS_UCODE \ TESTS \ USB_GADGET_EXAMPLES \ + VIMAGE \ ZFS __DEFAULT_NO_OPTIONS = \