Index: head/share/mk/sys.mk =================================================================== --- head/share/mk/sys.mk +++ head/share/mk/sys.mk @@ -33,16 +33,23 @@ # early include for customization # see local.sys.mk below -.-include +# Not included when building in fmake compatibility mode (still needed +# for older system support) +.if defined(.PARSEDIR) +.sinclude .if ${MK_META_MODE} == "yes" -.-include -.elif ${MK_META_FILES} == "yes" && ${.MAKEFLAGS:U:M-B} == "" +.sinclude +.elif ${MK_META_FILES} == "yes" && defined(.MAKEFLAGS) +.if ${.MAKEFLAGS:M-B} == "" .MAKE.MODE= meta verbose .endif +.endif .if ${MK_AUTO_OBJ} == "yes" # This needs to be done early - before .PATH is computed -.-include +.sinclude +.endif + .endif # If the special target .POSIX appears (without prerequisites or @@ -362,7 +369,7 @@ .endif # late include for customization -.-include +.sinclude .if defined(__MAKE_SHELL) && !empty(__MAKE_SHELL) SHELL= ${__MAKE_SHELL} @@ -379,11 +386,12 @@ # when running target scripts, this is a problem for many makefiles here. # So define a shell that will do what FreeBSD expects. .ifndef WITHOUT_SHELL_ERRCTL +__MAKE_SHELL?=/bin/sh .SHELL: name=sh \ quiet="set -" echo="set -v" filter="set -" \ hasErrCtl=yes check="set -e" ignore="set +e" \ echoFlag=v errFlag=e \ - path=${__MAKE_SHELL:U/bin/sh} + path=${__MAKE_SHELL} .endif .include