Date: Tue, 26 May 2015 21:44:15 +0000 (UTC) From: "Simon J. Gerraty" <sjg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r283586 - projects/bmake/share/mk Message-ID: <201505262144.t4QLiFer003729@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: sjg Date: Tue May 26 21:44:15 2015 New Revision: 283586 URL: https://svnweb.freebsd.org/changeset/base/283586 Log: Move META_MODE bits to local.meta.sys.mk By moving META_MODE bits from local.sys.mk, they are easier to skip when MK_META_MODE=no Update some filters to cope with sync from head. If buildworld etc or WITHOUT_META_MODE disable all the META_MODE related options. Added: projects/bmake/share/mk/local.meta.sys.mk (contents, props changed) Modified: projects/bmake/share/mk/local.dirdeps.mk projects/bmake/share/mk/local.gendirdeps.mk projects/bmake/share/mk/local.init.mk projects/bmake/share/mk/local.sys.mk Modified: projects/bmake/share/mk/local.dirdeps.mk ============================================================================== --- projects/bmake/share/mk/local.dirdeps.mk Tue May 26 21:41:26 2015 (r283585) +++ projects/bmake/share/mk/local.dirdeps.mk Tue May 26 21:44:15 2015 (r283586) @@ -35,6 +35,7 @@ _need_host_libs= \ lib/libc++ \ lib/libcxxrt \ lib/libdwarf \ + lib/libmd \ N_host_libs:= ${cd ${SRCTOP} && echo lib/lib*:L:sh:${_need_host_libs:${M_ListToSkip}}:${M_ListToSkip}} DIRDEPS_FILTER.host = \ @@ -44,6 +45,7 @@ DIRDEPS_FILTER.host = \ Nlib/[mn]* \ Ngnu/lib/csu* \ Ngnu/lib/lib[a-r]* \ + Nusr.bin/xinstall* \ DIRDEPS_FILTER+= \ @@ -81,10 +83,12 @@ DIRDEPS += \ DIRDEPS+= lib/clang/include .endif +.if ${MK_STAGING} == "yes" # we need targets/pseudo/stage to prep the stage tree .if ${DEP_RELDIR} != "targets/pseudo/stage" DIRDEPS += targets/pseudo/stage .endif +.endif CSU_DIR.i386 = csu/i386-elf DEP_MACHINE_ARCH = ${MACHINE_ARCH.${DEP_MACHINE}} Modified: projects/bmake/share/mk/local.gendirdeps.mk ============================================================================== --- projects/bmake/share/mk/local.gendirdeps.mk Tue May 26 21:41:26 2015 (r283585) +++ projects/bmake/share/mk/local.gendirdeps.mk Tue May 26 21:44:15 2015 (r283586) @@ -9,12 +9,21 @@ GENDIRDEPS_FILTER+= \ Ntools/* .if ${RELDIR:Mtargets*} == "" +.if ${RELDIR:Nusr.bin/clang/*:Ngnu/usr.bin/cc/*:Nlib/clang*} != "" +GENDIRDEPS_FILTER.host+= \ + Nusr.bin/clang/* \ + Ngnu/usr.bin/cc/* \ + +.endif GENDIRDEPS_FILTER+= \ Nusr.bin/clang/clang.host \ Ngnu/usr.bin/cc* \ + Ngnu/usr.bin/binutils*.host \ .endif +GENDIRDEPS_FILTER+= ${GENDIRDEPS_FILTER.${MACHINE}:U} + # gendirdeps.mk will turn _{VAR} into ${VAR} which keeps this simple # order of this list matters! GENDIRDEPS_FILTER_DIR_VARS+= \ Modified: projects/bmake/share/mk/local.init.mk ============================================================================== --- projects/bmake/share/mk/local.init.mk Tue May 26 21:41:26 2015 (r283585) +++ projects/bmake/share/mk/local.init.mk Tue May 26 21:44:15 2015 (r283586) @@ -16,13 +16,16 @@ CFLAGS_LAST+= --sysroot=${SYSROOT} CXXFLAGS_LAST+= --sysroot=${SYSROOT} LDADD+= --sysroot=${SYSROOT} +.elif ${MK_STAGING} == "yes" +CFLAGS+= -I${STAGE_INCLUDEDIR} +LDADD+= -L${STAGE_LIBDIR} +.endif .if ${MACHINE} == "host" # we cheat? LDADD+= -B/usr/lib CFLAGS_LAST+= -I/usr/include CXXFLAGS_LAST+= -I/usr/include .endif -.endif .if ${MACHINE} == "host" .if ${.MAKE.DEPENDFILE:E} != "host" Added: projects/bmake/share/mk/local.meta.sys.mk ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ projects/bmake/share/mk/local.meta.sys.mk Tue May 26 21:44:15 2015 (r283586) @@ -0,0 +1,204 @@ +# $FreeBSD$ + +# local configuration specific to meta mode +# XXX some of this should be in meta.sys.mk +# we assume that MK_META_MODE=yes + +.if ${.MAKE.LEVEL} == 0 +.if !empty(SB) +SB_OBJROOT ?= ${SB}/obj/ +# this is what we use below +OBJROOT ?= ${SB_OBJROOT} +.endif +OBJROOT ?= ${SRCTOP:H}/obj/ +.if ${OBJROOT:M*/} != "" +OBJROOT:= ${OBJROOT:tA}/ +.else +OBJROOT:= ${OBJROOT:H:tA}/${OBJROOT:T} +.endif +.export OBJROOT SRCTOP + +# we need HOST_TARGET etc below. +.include <host-target.mk> +.export HOST_TARGET +.endif + +# from src/Makefile (for universe) +TARGET_ARCHES_arm?= arm armeb armv6 armv6eb +TARGET_ARCHES_mips?= mipsel mips mips64el mips64 mipsn32 +TARGET_ARCHES_powerpc?= powerpc powerpc64 +TARGET_ARCHES_pc98?= i386 + +# some corner cases +CSU_DIR.i386 = csu/i386-elf +BOOT_MACHINE_DIR.amd64 = boot/i386 +MACHINE_ARCH.host = ${_HOST_ARCH} + +# the list of machines we support +ALL_MACHINE_LIST?= amd64 arm i386 ia64 mips pc98 powerpc sparc64 +.for m in ${ALL_MACHINE_LIST:O:u} +MACHINE_ARCH_LIST.$m?= ${TARGET_ARCHES_${m}:U$m} +MACHINE_ARCH.$m?= ${MACHINE_ARCH_LIST.$m:[1]} +BOOT_MACHINE_DIR.$m ?= boot/$m +.endfor +.ifndef _TARGET_SPEC +.if empty(MACHINE_ARCH) +.if !empty(TARGET_ARCH) +MACHINE_ARCH= ${TARGET_ARCH} +.else +MACHINE_ARCH= ${MACHINE_ARCH.${MACHINE}} +.endif +.endif +MACHINE_ARCH?= ${MACHINE_ARCH.${MACHINE}} +MACHINE_ARCH:= ${MACHINE_ARCH} +.else +# we got here via dirdeps +MACHINE_ARCH:= ${MACHINE_ARCH.${MACHINE}} +.endif + +# now because for universe we want to potentially +# build for multiple MACHINE_ARCH per MACHINE +# we need more than MACHINE in TARGET_SPEC +TARGET_SPEC_VARS= MACHINE MACHINE_ARCH +# see dirdeps.mk +.if ${TARGET_SPEC:Uno:M*,*} != "" +_tspec := ${TARGET_SPEC:S/,/ /g} +MACHINE := ${_tspec:[1]} +MACHINE_ARCH := ${_tspec:[2]} +# etc. +# We need to stop that TARGET_SPEC affecting any submakes +# and deal with MACHINE=${TARGET_SPEC} in the environment. +TARGET_SPEC= +# export but do not track +.export-env TARGET_SPEC +.export ${TARGET_SPEC_VARS} +.for v in ${TARGET_SPEC_VARS:O:u} +.if empty($v) +.undef $v +.endif +.endfor +.endif +# make sure we know what TARGET_SPEC is +# as we may need it to find Makefile.depend* +TARGET_SPEC = ${TARGET_SPEC_VARS:@v@${$v:U}@:ts,} + +# to be consistent with src/Makefile just concatenate with '.'s +TARGET_OBJ_SPEC:= ${TARGET_SPEC:S;,;.;g} +OBJTOP:= ${OBJROOT}${TARGET_OBJ_SPEC} + +.if ${.CURDIR} == ${SRCTOP} +RELDIR = . +.elif ${.CURDIR:M${SRCTOP}/*} +RELDIR := ${.CURDIR:S,${SRCTOP}/,,} +.endif + +HOST_OBJTOP ?= ${OBJROOT}${HOST_TARGET} + +.if ${OBJTOP} == ${HOST_OBJTOP} || ${REQUESTED_MACHINE:U${MACHINE}} == "host" +MACHINE= host +.if ${TARGET_MACHINE:Uno} == ${HOST_TARGET} +# not what we want +TARGET_MACHINE= host +.endif +.endif +.if ${MACHINE} == "host" +OBJTOP := ${HOST_OBJTOP} +.endif + +.if ${.MAKE.LEVEL} == 0 +PYTHON ?= /usr/local/bin/python +# this works best if share/mk is ready for it. +BUILD_AT_LEVEL0= no +.export PYTHON + +# we want to end up with a singe stage tree for all machines +.if ${MK_STAGING} == "yes" +.if empty(STAGE_ROOT) +STAGE_ROOT?= ${OBJROOT}stage +.export STAGE_ROOT +.endif +.endif +.endif + +.if ${MK_STAGING} == "yes" +.if ${MACHINE} == "host" +STAGE_MACHINE= ${HOST_TARGET} +.else +STAGE_MACHINE:= ${TARGET_OBJ_SPEC} +.endif +STAGE_OBJTOP:= ${STAGE_ROOT}/${STAGE_MACHINE} +STAGE_COMMON_OBJTOP:= ${STAGE_ROOT}/common +STAGE_HOST_OBJTOP:= ${STAGE_ROOT}/${HOST_TARGET} + +STAGE_LIBDIR= ${STAGE_OBJTOP}${_LIBDIR:U${LIBDIR:U/lib}} +STAGE_INCLUDEDIR= ${STAGE_OBJTOP}${INCLUDEDIR:U/usr/include} +# this is not the same as INCLUDEDIR +STAGE_INCSDIR= ${STAGE_OBJTOP}${INCSDIR:U/include} +# the target is usually an absolute path +STAGE_SYMLINKS_DIR= ${STAGE_OBJTOP} + +LDFLAGS_LAST+= -Wl,-rpath-link -Wl,${STAGE_LIBDIR} +.ifdef WITH_SYSROOT +SYSROOT?= ${STAGE_OBJTOP}/ +.else +LDFLAGS_LAST+= -L${STAGE_LIBDIR} +.endif + +.endif # MK_STAGING + +# this is sufficient for most of the tree. +.MAKE.DEPENDFILE_DEFAULT = ${.MAKE.DEPENDFILE_PREFIX} + +# but if we have a machine qualified file it should be used in preference +.MAKE.DEPENDFILE_PREFERENCE = \ + ${.MAKE.DEPENDFILE_PREFIX}.${MACHINE} \ + ${.MAKE.DEPENDFILE_PREFIX} + +.undef .MAKE.DEPENDFILE + +.include "sys.dependfile.mk" + +.if ${.MAKE.LEVEL} > 0 && ${MACHINE} == "host" && ${.MAKE.DEPENDFILE:E} != "host" +# we can use this but should not update it. +UPDATE_DEPENDFILE= NO +.endif + +.MAKE.META.BAILIWICK = ${SB} ${OBJROOT} ${STAGE_ROOT} + +CSU_DIR.i386 = csu/i386-elf +CSU_DIR.${MACHINE_ARCH} ?= csu/${MACHINE_ARCH} +CSU_DIR := ${CSU_DIR.${MACHINE_ARCH}} + +.if !empty(TIME_STAMP) +TRACER= ${TIME_STAMP} ${:U} +.endif + +# toolchains can be a pain - especially bootstrappping them +.if ${MACHINE} == "host" +MK_SHARED_TOOLCHAIN= no +.endif +.ifdef WITH_TOOLSDIR +TOOLSDIR?= ${HOST_OBJTOP}/tools +.elif defined(STAGE_HOST_OBJTOP) && exists(${STAGE_HOST_OBJTOP}/usr/bin) +TOOLSDIR?= ${STAGE_HOST_OBJTOP} +.endif +.if ${.MAKE.LEVEL} == 0 && exists(${TOOLSDIR}/usr/bin) +PATH:= ${PATH:S,:, ,g:@d@${exists(${TOOLSDIR}$d):?${TOOLSDIR}$d:}@:ts:}:${PATH} +.export PATH +.if exists(${TOOLSDIR}/usr/bin/cc) +HOST_CC?= ${TOOLSDIR}/usr/bin/cc +.export HOST_CC +.endif +.endif + +.if ${MACHINE:Nhost:Ncommon} != "" && ${MACHINE} != ${HOST_MACHINE} +# cross-building +.if !defined(FREEBSD_REVISION) +FREEBSD_REVISION!= sed -n '/^REVISION=/{s,.*=,,;s,",,g;p; }' ${SRCTOP}/sys/conf/newvers.sh +.export FREEBSD_REVISION +.endif +CROSS_TARGET_FLAGS= -target ${MACHINE_ARCH}-unknown-freebsd${FREEBSD_REVISION} +CFLAGS+= ${CROSS_TARGET_FLAGS} +ACFLAGS+= ${CROSS_TARGET_FLAGS} +LDFLAGS+= -Wl,-m -Wl,elf_${MACHINE_ARCH}_fbsd +.endif Modified: projects/bmake/share/mk/local.sys.mk ============================================================================== --- projects/bmake/share/mk/local.sys.mk Tue May 26 21:41:26 2015 (r283585) +++ projects/bmake/share/mk/local.sys.mk Tue May 26 21:44:15 2015 (r283586) @@ -1,17 +1,20 @@ WITH_INSTALL_AS_USER= yes -.if defined(.PARSEDIR) # bmake .if !defined(_TARGETS) # some things we do only once -_TARGETS := ${.TARGETS} +_TARGETS:= ${.TARGETS} .export _TARGETS .endif -.if ${_TARGETS:Mbuildworld} -WITHOUT_STAGING= -WITHOUT_SYSROOT= + +.if (!empty(_TARGETS) && ${_TARGETS:Nbuildworld:Nuniverse:Ninstallworld} == "") || defined(WITHOUT_META_MODE) +MK_AUTO_OBJ= no +MK_META_MODE= no +MK_STAGING= no +MK_STAGING_PROG= no +MK_SYSROOT= no UPDATE_DEPENDFILE=NO -NO_AUTO_OBJ= .endif + SRCCONF:= ${.PARSEDIR}/src.conf # ensure we are self contained __MAKE_CONF:= ${SRCCONF} @@ -40,226 +43,6 @@ M_whence = ${M_type}:M/*:[1] # convert a path to a valid shell variable M_P2V = tu:C,[./-],_,g -# absoulte path to what we are reading. -_PARSEDIR = ${.PARSEDIR:tA} - -.if !empty(SB) -SB_SRC ?= ${SB}/src -SB_OBJROOT ?= ${SB}/obj/ -# this is what we use below -SRCTOP ?= ${SB_SRC} -OBJROOT ?= ${SB_OBJROOT} -.endif - -.if empty(SRCTOP) -SRCTOP := ${_PARSEDIR:H:H} -OBJROOT ?= ${SRCTOP:H}/obj/ -OBJROOT := ${OBJROOT} -.endif -.export OBJROOT SRCTOP - -# we need HOST_TARGET etc below. -.include <host-target.mk> - -# from src/Makefile (for universe) -TARGET_ARCHES_arm?= arm armeb armv6 armv6eb -TARGET_ARCHES_mips?= mipsel mips mips64el mips64 mipsn32 -TARGET_ARCHES_powerpc?= powerpc powerpc64 -TARGET_ARCHES_pc98?= i386 - -# some corner cases -CSU_DIR.i386 = csu/i386-elf -BOOT_MACHINE_DIR.amd64 = boot/i386 -MACHINE_ARCH.host = ${_HOST_ARCH} - -# the list of machines we support -ALL_MACHINE_LIST?= amd64 arm i386 ia64 mips pc98 powerpc sparc64 -.for m in ${ALL_MACHINE_LIST:O:u} -MACHINE_ARCH_LIST.$m?= ${TARGET_ARCHES_${m}:U$m} -MACHINE_ARCH.$m?= ${MACHINE_ARCH_LIST.$m:[1]} -BOOT_MACHINE_DIR.$m ?= boot/$m -.endfor -.ifndef _TARGET_SPEC -.if empty(MACHINE_ARCH) -.if !empty(TARGET_ARCH) -MACHINE_ARCH= ${TARGET_ARCH} -.else -MACHINE_ARCH= ${MACHINE_ARCH.${MACHINE}} -.endif -.endif -MACHINE_ARCH?= ${MACHINE_ARCH.${MACHINE}} -MACHINE_ARCH:= ${MACHINE_ARCH} -.else -# we got here via dirdeps -MACHINE_ARCH:= ${MACHINE_ARCH.${MACHINE}} -.endif - -.if ${.MAKE.LEVEL} == 0 -# 1st time only -.-include <sys.env.mk> -.if !empty(OBJROOT) -.if ${OBJROOT:M*/} != "" -OBJROOT:= ${OBJROOT:tA}/ -.else -OBJROOT:= ${OBJROOT:H:tA}/${OBJROOT:T} -.endif -.export OBJROOT -.endif -.endif - -# now because for universe we want to potentially -# build for multiple MACHINE_ARCH per MACHINE -# we need more than MACHINE in TARGET_SPEC -TARGET_SPEC_VARS= MACHINE MACHINE_ARCH -# see dirdeps.mk -.if ${TARGET_SPEC:Uno:M*,*} != "" -_tspec := ${TARGET_SPEC:S/,/ /g} -MACHINE := ${_tspec:[1]} -MACHINE_ARCH := ${_tspec:[2]} -# etc. -# We need to stop that TARGET_SPEC affecting any submakes -# and deal with MACHINE=${TARGET_SPEC} in the environment. -TARGET_SPEC= -# export but do not track -.export-env TARGET_SPEC -.export ${TARGET_SPEC_VARS} -.for v in ${TARGET_SPEC_VARS:O:u} -.if empty($v) -.undef $v -.endif -.endfor -.endif -# make sure we know what TARGET_SPEC is -# as we may need it to find Makefile.depend* -TARGET_SPEC = ${TARGET_SPEC_VARS:@v@${$v:U}@:ts,} - -# to be consistent with src/Makefile just concatenate with '.'s -TARGET_OBJ_SPEC:= ${TARGET_SPEC:S;,;.;g} -OBJTOP:= ${OBJROOT}${TARGET_OBJ_SPEC} - -.if !empty(SRCTOP) -.if ${.CURDIR} == ${SRCTOP} -RELDIR = . -.elif ${.CURDIR:M${SRCTOP}/*} -RELDIR := ${.CURDIR:S,${SRCTOP}/,,} -.endif -.endif - -HOST_OBJTOP ?= ${OBJROOT}${HOST_TARGET} - -.if ${OBJTOP} == ${HOST_OBJTOP} || ${REQUESTED_MACHINE:U${MACHINE}} == "host" -MACHINE= host -.if ${TARGET_MACHINE:Uno} == ${HOST_TARGET} -# not what we want -TARGET_MACHINE= host -.endif -.endif -.if ${MACHINE} == "host" -OBJTOP := ${HOST_OBJTOP} -.endif - -# the logic in bsd.own.mk forces this dance -.ifndef WITHOUT_META_MODE -WITH_META_MODE= yes - -.ifndef WITHOUT_SYSROOT -WITH_SYSROOT= yes -.endif -.ifndef WITHOUT_STAGING -WITH_STAGING= yes -.ifndef WITHOUT_STAGING_PROG -WITH_STAGING_PROG= yes -.endif -.endif - -PYTHON ?= /usr/local/bin/python - -.if ${.MAKE.LEVEL} == 0 -# just in case -m, MAKESYSPATH or our default has .../ -# export a sanitised version... -# first any -m* from command line, -# then any MAKESYSPATH and finally ${.PARSEDIR} -_makesyspath:= ${.MAKEFLAGS:tW:S/ -m / -m/g:tw:M-m*:S,^-m,,} \ - ${MAKESYSPATH:U} \ - ${.PARSEDIR} -# replace .../.* with ${.PARSEDIR}, not perfect but pretty close -MAKESYSPATH:= ${_makesyspath:S,:, ,g:C,^\.\.\./.*,${.PARSEDIR},:u:ts:} -.export MAKESYSPATH - -# this works best if share/mk is ready for it. -BUILD_AT_LEVEL0= no -# By default only MACHINE0 updates dependencies -# see local.autodep.mk -MACHINE0 := ${MACHINE} -.export MACHINE0 -.export PYTHON -.endif - -# we want to end up with a singe stage tree for all machines -.ifndef WITHOUT_STAGING -.if empty(STAGE_ROOT) -STAGE_ROOT?= ${OBJROOT}stage -.export STAGE_ROOT -.endif -.endif - -.if !empty(STAGE_ROOT) && !defined(WITHOUT_STAGING) -.if ${MACHINE} == "host" -STAGE_MACHINE= ${HOST_TARGET} -.else -STAGE_MACHINE:= ${TARGET_OBJ_SPEC} -.endif -STAGE_OBJTOP:= ${STAGE_ROOT}/${STAGE_MACHINE} -STAGE_COMMON_OBJTOP:= ${STAGE_ROOT}/common -STAGE_HOST_OBJTOP:= ${STAGE_ROOT}/${HOST_TARGET} - -STAGE_LIBDIR= ${STAGE_OBJTOP}${_LIBDIR:U${LIBDIR:U/lib}} -# this is not the same as INCLUDEDIR -STAGE_INCSDIR= ${STAGE_OBJTOP}${INCSDIR:U/include} -# the target is usually an absolute path -STAGE_SYMLINKS_DIR= ${STAGE_OBJTOP} - -.if ${MACHINE} == "host" && defined(EARLY_BUILD) -# we literally want to build with host cc and includes -.else -.ifdef WITH_SYSROOT -SYSROOT?= ${STAGE_OBJTOP}/ -.endif -LDFLAGS_LAST+= -Wl,-rpath-link -Wl,${STAGE_LIBDIR} -STAGED_INCLUDE_DIR= ${STAGE_OBJTOP}/usr/include -.endif -.endif # EARLY_BUILD for host - -# this is sufficient for most of the tree. -.MAKE.DEPENDFILE_DEFAULT = ${.MAKE.DEPENDFILE_PREFIX} - -# but if we have a machine qualified file it should be used in preference -.MAKE.DEPENDFILE_PREFERENCE = \ - ${.MAKE.DEPENDFILE_PREFIX}.${MACHINE} \ - ${.MAKE.DEPENDFILE_PREFIX} - -.undef .MAKE.DEPENDFILE - -.include "sys.dependfile.mk" - -.include "meta.sys.mk" - -.if ${.MAKE.LEVEL} > 0 && ${MACHINE} == "host" && ${.MAKE.DEPENDFILE:E} != "host" -# we can use this but should not update it. -UPDATE_DEPENDFILE= NO -.endif - -.MAKE.META.BAILIWICK = ${SB} ${OBJROOT} ${STAGE_ROOT} - -CSU_DIR.i386 = csu/i386-elf -CSU_DIR.${MACHINE_ARCH} ?= csu/${MACHINE_ARCH} -CSU_DIR := ${CSU_DIR.${MACHINE_ARCH}} - -.endif # meta mode - -# ensure we have a value -.MAKE.MODE ?= normal - MAKE_PRINT_VAR_ON_ERROR+= \ .CURDIR \ .MAKE \ @@ -272,6 +55,7 @@ MAKE_PRINT_VAR_ON_ERROR+= \ MAKEOBJDIRPREFIX \ MAKESYSPATH \ MAKE_VERSION\ + SRCTOP \ OBJTOP \ ${MAKE_PRINT_VAR_ON_ERROR_XTRAS} @@ -279,49 +63,12 @@ MAKE_PRINT_VAR_ON_ERROR+= \ MAKE_PRINT_VAR_ON_ERROR += .MAKE.MAKEFILES .PATH .endif - # these are handy # we can use this for a cheap timestamp at the start of a target's script, # but not at the end - since make will expand both at the same time. -AnEmptyVar= TIME_STAMP_FMT = @ %s [%Y-%m-%d %T] TIME_STAMP = ${TIME_STAMP_FMT:localtime} # this will produce the same output but as of when date(1) is run. TIME_STAMP_DATE = `date '+${TIME_STAMP_FMT}'` TIME_STAMP_END?= ${TIME_STAMP_DATE} -.ifdef WITH_TIMESTAMPS -TRACER= ${TIME_STAMP} ${AnEmptyVar} -.endif - -# toolchains can be a pain - especially bootstrappping them -.if ${MACHINE} == "host" -MK_SHARED_TOOLCHAIN= no -.endif -.ifdef WITH_TOOLSDIR -TOOLSDIR?= ${HOST_OBJTOP}/tools -.elif defined(STAGE_HOST_OBJTOP) && exists(${STAGE_HOST_OBJTOP}/usr/bin) -TOOLSDIR?= ${STAGE_HOST_OBJTOP} -.endif -.if ${.MAKE.LEVEL} == 0 && exists(${TOOLSDIR}/usr/bin) -PATH:= ${PATH:S,:, ,g:@d@${exists(${TOOLSDIR}$d):?${TOOLSDIR}$d:}@:ts:}:${PATH} -.export PATH -.if exists(${TOOLSDIR}/usr/bin/cc) -HOST_CC?= ${TOOLSDIR}/usr/bin/cc -.export HOST_CC -.endif -.endif - -.if ${MACHINE:Nhost:Ncommon} != "" && ${MACHINE} != ${HOST_MACHINE} -# cross-building -.if !defined(FREEBSD_REVISION) -FREEBSD_REVISION!= sed -n '/^REVISION=/{s,.*=,,;s,",,g;p; }' ${SRCTOP}/sys/conf/newvers.sh -.export FREEBSD_REVISION -.endif -CROSS_TARGET_FLAGS= -target ${MACHINE_ARCH}-unknown-freebsd${FREEBSD_REVISION} -CFLAGS+= ${CROSS_TARGET_FLAGS} -ACFLAGS+= ${CROSS_TARGET_FLAGS} -LDFLAGS+= -Wl,-m -Wl,elf_${MACHINE_ARCH}_fbsd -.endif - -.endif # bmake
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201505262144.t4QLiFer003729>