summaryrefslogtreecommitdiff
path: root/mk/configure
diff options
context:
space:
mode:
authorjoerg <joerg@pkgsrc.org>2007-08-01 16:14:17 +0000
committerjoerg <joerg@pkgsrc.org>2007-08-01 16:14:17 +0000
commit29777c8ec515d539bd0c24665aebd511ea61d8c3 (patch)
tree44d3459b2e1906ba1125bf7205d3acc89f835103 /mk/configure
parent13157ce5e2f70c31da7dc1f66e22495eb7c54ccc (diff)
downloadpkgsrc-29777c8ec515d539bd0c24665aebd511ea61d8c3.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/configure')
-rw-r--r--mk/configure/gnu-configure.mk5
1 files changed, 4 insertions, 1 deletions
diff --git a/mk/configure/gnu-configure.mk b/mk/configure/gnu-configure.mk
index 7962d035b6f..0853673e090 100644
--- a/mk/configure/gnu-configure.mk
+++ b/mk/configure/gnu-configure.mk
@@ -1,4 +1,4 @@
-# $NetBSD: gnu-configure.mk,v 1.5 2007/07/12 18:59:15 jlam Exp $
+# $NetBSD: gnu-configure.mk,v 1.6 2007/08/01 16:14:17 joerg Exp $
_VARGROUPS+= gnu-configure
_USER_VARS.gnu-configure= # none
@@ -25,6 +25,9 @@ CONFIGURE_ARGS+= --prefix=${GNU_CONFIGURE_PREFIX:Q}
USE_GNU_CONFIGURE_HOST?= yes
.if !empty(USE_GNU_CONFIGURE_HOST:M[yY][eE][sS])
+. if !empty(USE_CROSS_COMPILE:M[yY][eE][sS])
+CONFIGURE_ARGS+= --build=${NATIVE_MACHINE_GNU_PLATFORM:Q}
+. endif
CONFIGURE_ARGS+= --host=${MACHINE_GNU_PLATFORM:Q}
.endif