From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: Cross-building GHC Date: Fri, 15 Mar 2013 00:20:30 +0100 Message-ID: <8738vxh8ld.fsf@gnu.org> References: <87sj443got.fsf@karetnikov.org> <87620trip2.fsf@gnu.org> <87obelg5iu.fsf@karetnikov.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([208.118.235.92]:42997) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UGHRy-0006zP-Nw for bug-guix@gnu.org; Thu, 14 Mar 2013 19:20:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UGHRx-0007E8-NV for bug-guix@gnu.org; Thu, 14 Mar 2013 19:20:42 -0400 Received: from [2a01:e0b:1:123:ca0a:a9ff:fe03:271e] (port=44288 helo=xanadu.aquilenet.fr) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UGHRx-0007Cy-Gu for bug-guix@gnu.org; Thu, 14 Mar 2013 19:20:41 -0400 In-Reply-To: <87obelg5iu.fsf@karetnikov.org> (Nikita Karetnikov's message of "Thu, 14 Mar 2013 23:12:09 +0400") List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org To: Nikita Karetnikov Cc: bug-guix@gnu.org Nikita Karetnikov skribis: >> You mean it _tries_ to use it, because it=E2=80=99s not available in chr= oot >> builds, right? > > It'll try to use '/usr/bin/ld' if I run 'unset COMPILER_PATH'. I guess > that it's trying to autodetect the right linker during './configure'. > > However, if I run > > export COMPILER_PATH=3D/nix/store/khdyz3i5aih56lxfk6hjvp3884apm7qb-gcc-cr= oss-mips64el-linux-gnu-4.7.2/libexec/gcc/mips64el-linux-gnu:/nix/store/khdy= z3i5aih56lxfk6hjvp3884apm7qb-gcc-cross-mips64el-linux-gnu-4.7.2/libexec/gcc= /mips64el-linux-gnu/4.7.2 > > to specify the location of subprograms, it'll complain about > unrecognized opcodes. For example: Yes, because COMPILER_PATH will influence both the native and the cross-compiler. Same problem as discussed at . That makes COMPILER_PATH unusable in this context. We need to check how to collect2 finds the cross ld, and adjust our cross-GCC accordingly. (That=E2=80=99s admittedly very vague, but finding out the details is left = as an exercise to the reader. ;-)). Thanks, Ludo=E2=80=99.