diff --git a/ChangeLog b/ChangeLog index 384e2b0e5..6e29e2912 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2009-04-12 Pavel Roskin + + * configure.ac: Change the logic when we check for target tools. + Do it when the target is specified and it's different from the + specified value of the host. + 2009-04-11 Felix Zielcke * util/hostdisk.c [__FreeBSD_kernel__]: Include sys/disk.h. diff --git a/configure b/configure index c4312f42b..23869ce05 100644 --- a/configure +++ b/configure @@ -5942,9 +5942,8 @@ esac { echo "$as_me:$LINENO: result: $TARGET_OBJ2ELF" >&5 echo "${ECHO_T}$TARGET_OBJ2ELF" >&6; } -# For cross-compiling. -if test "x$build" != "x$host"; then - # XXX this depends on the implementation of autoconf! +# Find tools for the target. +if test "x$target_alias" != x && test "x$host_alias" != "x$target_alias"; then tmp_ac_tool_prefix="$ac_tool_prefix" ac_tool_prefix=$target_alias- diff --git a/configure.ac b/configure.ac index c316f1784..ef143de53 100644 --- a/configure.ac +++ b/configure.ac @@ -231,9 +231,8 @@ esac AC_SUBST(TARGET_OBJ2ELF) AC_MSG_RESULT([$TARGET_OBJ2ELF]) -# For cross-compiling. -if test "x$build" != "x$host"; then - # XXX this depends on the implementation of autoconf! +# Find tools for the target. +if test "x$target_alias" != x && test "x$host_alias" != "x$target_alias"; then tmp_ac_tool_prefix="$ac_tool_prefix" ac_tool_prefix=$target_alias-