This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug go/80964] cross-gotools are not executable on host system
- From: "bernd.edlinger at hotmail dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 04 Jun 2017 07:19:58 +0000
- Subject: [Bug go/80964] cross-gotools are not executable on host system
- Auto-submitted: auto-generated
- References: <bug-80964-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80964
--- Comment #3 from Bernd Edlinger <bernd.edlinger at hotmail dot de> ---
I think this would do what you want:
Not building gotools for build==host!=target,
but build the gotools for build!=host==target (canadian),
At least the gotools are built without error in the
latter case, but I have not tested if they actually work
on the target.
Index: configure
===================================================================
--- configure (revision 248852)
+++ configure (working copy)
@@ -3783,7 +3783,7 @@
ac_compiler_gnu=$ac_cv_c_compiler_gnu
- if test "$cross_compiling" = no; then
+ if test x"$host_alias" == x"$target_alias"; then
NATIVE_TRUE=
NATIVE_FALSE='#'
else
Index: configure.ac
===================================================================
--- configure.ac (revision 248852)
+++ configure.ac (working copy)
@@ -46,7 +46,7 @@
AC_PROG_CC
AC_PROG_GO
-AM_CONDITIONAL(NATIVE, test "$cross_compiling" = no)
+AM_CONDITIONAL(NATIVE, test x"$host_alias" == x"$target_alias")
dnl Test for -lsocket and -lnsl. Copied from libjava/configure.ac.
AC_CACHE_CHECK([for socket libraries], gotools_cv_lib_sockets,