diff options
author | joerg <joerg> | 2007-08-01 16:14:17 +0000 |
---|---|---|
committer | joerg <joerg> | 2007-08-01 16:14:17 +0000 |
commit | 07d845558e514fd4523d703b818ccc415e932681 (patch) | |
tree | 44d3459b2e1906ba1125bf7205d3acc89f835103 /mk/bsd.prefs.mk | |
parent | a1273168e4261b8af52403cd8d52de97766974fd (diff) | |
download | pkgsrc-07d845558e514fd4523d703b818ccc415e932681.tar.gz |
Begin adding some of the basic, non-intrusive pieces of the
cross-compile support.
- NATIVE_MACHINE_GNU_ARCH, NATIVE_LOWER_ARCH, NATIVE_MACHINE_ARCH,
NATIVE_MACHINE_PLATFORM and NATIVE_MACHINE_GNU_PLATFORM work
like the counterpars without NATIVE_ prefix. Expansion of
NATIVE_LOWER_ARCH and NATIVE_MACHINE_ARCH is enforced early,
so that MACHINE_ARCH can be overriden in mk.conf to specify the
target architecture.
- Provide a default of NO for USE_CROSS_COMPILE. This will be the
main switch to activate cross-compiling and adding it now makes
it possible to merge more of the patches for specific packages.
- Set --build and --host when cross-compiling, the former using the
just added variable NATIVE_MACHINE_GNU_PLATFORM.
Supported-by: Google SoC 2007
Looks good: jlam@
Diffstat (limited to 'mk/bsd.prefs.mk')
-rw-r--r-- | mk/bsd.prefs.mk | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/mk/bsd.prefs.mk b/mk/bsd.prefs.mk index 722046ed736..0b7eb62f03c 100644 --- a/mk/bsd.prefs.mk +++ b/mk/bsd.prefs.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.prefs.mk,v 1.259 2007/08/01 12:21:56 joerg Exp $ +# $NetBSD: bsd.prefs.mk,v 1.260 2007/08/01 16:14:17 joerg Exp $ # # Make file, included to get the site preferences, if any. Should # only be included by package Makefiles before any .if defined() @@ -88,7 +88,8 @@ GNU_ARCH.m68000?= m68010 GNU_ARCH.mips?= mipsel GNU_ARCH.sh3eb?= sh GNU_ARCH.sh3el?= shle -MACHINE_GNU_ARCH?= ${GNU_ARCH.${MACHINE_ARCH}:U${MACHINE_ARCH}} +NATIVE_MACHINE_GNU_ARCH?= ${GNU_ARCH.${NATIVE_MACHINE_ARCH}:U${NATIVE_MACHINE_ARCH}} +MACHINE_GNU_ARCH?= ${GNU_ARCH.${MACHINE_ARCH}:U${MACHINE_ARCH}} .if ${OPSYS} == "NetBSD" LOWER_OPSYS?= netbsd @@ -232,11 +233,17 @@ OS_VERSION:= ${OS_VERSION} MAKEFLAGS+= LOWER_OPSYS=${LOWER_OPSYS:Q} -LOWER_VENDOR?= # empty ("arch--opsys") -LOWER_ARCH?= ${MACHINE_GNU_ARCH} - -MACHINE_PLATFORM?= ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} -MACHINE_GNU_PLATFORM?= ${LOWER_ARCH}-${LOWER_VENDOR}-${LOWER_OPSYS}${APPEND_ELF}${LOWER_OPSYS_VERSUFFIX} +LOWER_VENDOR?= # empty ("arch--opsys") +LOWER_ARCH?= ${MACHINE_GNU_ARCH} +# Expand now as MACHINE_ARCH can be overriden in mk.conf and +# LOWER_ARCH is typically derived from it. +NATIVE_LOWER_ARCH:= ${LOWER_ARCH} +NATIVE_MACHINE_ARCH:= ${MACHINE_ARCH} + +NATIVE_MACHINE_PLATFORM?= ${OPSYS}-${OS_VERSION}-${NATIVE_MACHINE_ARCH} +MACHINE_PLATFORM?= ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} +NATIVE_MACHINE_GNU_PLATFORM?= ${NATIVE_LOWER_ARCH}-${LOWER_VENDOR}-${LOWER_OPSYS}${APPEND_ELF}${LOWER_OPSYS_VERSUFFIX} +MACHINE_GNU_PLATFORM?= ${LOWER_ARCH}-${LOWER_VENDOR}-${LOWER_OPSYS}${APPEND_ELF}${LOWER_OPSYS_VERSUFFIX} # Needed to prevent an "install:" target from being created in bsd.own.mk. NEED_OWN_INSTALL_TARGET=no |