diff options
author | Guillem Jover <guillem@debian.org> | 2009-08-15 20:38:48 +0200 |
---|---|---|
committer | Guillem Jover <guillem@debian.org> | 2009-08-15 22:05:11 +0200 |
commit | 93f043e69f1d44913a1ec265eece7099ae3db884 (patch) | |
tree | ced6c7fd94f8383e20f9fbfc8a60f350ce15dcc7 /m4 | |
parent | 934a97e6ef744501d48cfd39fa0a38e715b2bde1 (diff) | |
download | dpkg-93f043e69f1d44913a1ec265eece7099ae3db884.tar.gz |
Check for host system instead of target at build time
Using AC_CANONICAL_TARGET is needed when wanting to support building
cross-compiling software. But there's too many assumptions in dpkg that
the host system in dpkg-dev is going to match the build system.
Diffstat (limited to 'm4')
-rw-r--r-- | m4/arch.m4 | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/m4/arch.m4 b/m4/arch.m4 index e6292e20f..b2c889cd7 100644 --- a/m4/arch.m4 +++ b/m4/arch.m4 @@ -3,22 +3,22 @@ # Use dpkg-architecture from the source tree to set sh_var using DEB_VAR for # the target architecture, to avoid duplicating its logic. AC_DEFUN([_DPKG_ARCHITECTURE], [ -AC_REQUIRE([AC_CANONICAL_TARGET])dnl +AC_REQUIRE([AC_CANONICAL_HOST])dnl $2=`cd $srcdir/scripts; \ - PERL5LIB=$(pwd) ./dpkg-architecture.pl -t$target -q$1 2>/dev/null` + PERL5LIB=$(pwd) ./dpkg-architecture.pl -t$host -q$1 2>/dev/null` ])# _DPKG_ARCHITECURE # DPKG_CPU_TYPE # ------------- -# Parse the target cpu name and check it against the cputable to determine +# Parse the host cpu name and check it against the cputable to determine # the Debian name for it. Sets ARCHITECTURE_CPU. AC_DEFUN([DPKG_CPU_TYPE], [AC_MSG_CHECKING([dpkg cpu type]) _DPKG_ARCHITECTURE([DEB_HOST_ARCH_CPU], [cpu_type]) if test "x$cpu_type" = "x"; then - cpu_type=$target_cpu + cpu_type=$host_cpu AC_MSG_RESULT([$cpu_type]) - AC_MSG_WARN([$target_cpu not found in cputable]) + AC_MSG_WARN([$host_cpu not found in cputable]) else AC_MSG_RESULT([$cpu_type]) fi @@ -28,15 +28,15 @@ AC_DEFINE_UNQUOTED(ARCHITECTURE_CPU, "${cpu_type}", # DPKG_OS_TYPE # ------------ -# Parse the target operating system name and check it against a list of +# Parse the host operating system name and check it against a list of # special cases to determine what type it is. Sets ARCHITECTURE_OS. AC_DEFUN([DPKG_OS_TYPE], [AC_MSG_CHECKING([dpkg operating system type]) _DPKG_ARCHITECTURE([DEB_HOST_ARCH_OS], [os_type]) if test "x$os_type" = "x"; then - os_type=$target_os + os_type=$host_os AC_MSG_RESULT([$os_type]) - AC_MSG_WARN([$target_os not found in ostable]) + AC_MSG_WARN([$host_os not found in ostable]) else AC_MSG_RESULT([$os_type]) fi @@ -46,7 +46,7 @@ AC_DEFINE_UNQUOTED(ARCHITECTURE_OS, "${os_type}", # DPKG_ARCHITECTURE # ------------------------ -# Determine the Debian name for the target operating system, +# Determine the Debian name for the host operating system, # sets ARCHITECTURE. AC_DEFUN([DPKG_ARCHITECTURE], [DPKG_CPU_TYPE |