1# $FreeBSD$ 2 3# Note: This file is also duplicated in the sys/conf/kern.pre.mk so 4# it will always grab SRCCONF, even if it isn't being built in-tree 5# to preserve historical (and useful) behavior. Changes here need to 6# be reflected there so SRCCONF isn't included multiple times. 7 8# make sure this is defined in a consistent manner 9SRCTOP:= ${.PARSEDIR:tA:H:H} 10 11# Allow user to configure things that only effect src tree builds. 12SRCCONF?= /etc/src.conf 13.if (exists(${SRCCONF}) || ${SRCCONF} != "/etc/src.conf") && !target(_srcconf_included_) 14.sinclude "${SRCCONF}" 15_srcconf_included_: .NOTMAIN 16.endif 17# If we were found via .../share/mk we need to replace that 18# with ${.PARSEDIR:tA} so that we can be found by 19# sub-makes launched from objdir. 20.if ${.MAKEFLAGS:M.../share/mk} != "" 21.MAKEFLAGS:= ${.MAKEFLAGS:S,.../share/mk,${.PARSEDIR:tA},} 22.endif 23.if ${MAKESYSPATH:Uno:M*.../*} != "" 24MAKESYSPATH:= ${MAKESYSPATH:S,.../share/mk,${.PARSEDIR:tA},} 25.export MAKESYSPATH 26.endif 27