From: Nikita Karetnikov <nikita@karetnikov.org>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: bug-guix@gnu.org
Subject: Re: Initial cross-compilation support
Date: Thu, 28 Mar 2013 13:35:08 +0400 [thread overview]
Message-ID: <87wqsrrho3.fsf@karetnikov.org> (raw)
In-Reply-To: <8738wcyxs7.fsf@gnu.org> ("Ludovic Courtès"'s message of "Sun, 03 Mar 2013 22:32:40 +0100")
[-- Attachment #1: Type: text/plain, Size: 5286 bytes --]
>> I think one needs to add the configure parameters "--with-arch=mips64 --
>> with-abi=64" to the cross build of gcc; and maybe "-march=mip64 -mabi=64"
>> to the binutils and glibc. Ludovic should know best where to do it in the
>> code.
> I would add a keyword parameter to ‘cross-gcc’ to allow extra configure
> flags to be passed, or perhaps just an abstract #:abi flag.
I tried to add
"--with-arch=mips64"
"--with-abi=64"
to '#:configure-flags' of 'cross-gcc'. It failed:
/nix/store/g9js73bwv1fl92h1nnf50vf1619irnxf-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2/libexec/gcc/mips64el-linux-gnu/ld: /nix/store/g9js73bwv1fl92h1nnf50vf1619irnxf-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2/lib/gcc/mips64el-linux-gnu/4.7.2/libgcc.a(_fpcmp_parts_tf.o): ABI is incompatible with that of the selected emulation
/nix/store/g9js73bwv1fl92h1nnf50vf1619irnxf-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2/libexec/gcc/mips64el-linux-gnu/ld: failed to merge target specific data of file /nix/store/g9js73bwv1fl92h1nnf50vf1619irnxf-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2/lib/gcc/mips64el-linux-gnu/4.7.2/libgcc.a(_fpcmp_parts_tf.o)
[...]
/nix/store/g9js73bwv1fl92h1nnf50vf1619irnxf-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2/lib/gcc/mips64el-linux-gnu/4.7.2/libgcc.a(_addsub_tf.o): In function `_fpadd_parts':
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:617:(.text+0x3a0): relocation truncated to fit: R_MIPS_GOT_DISP against `__thenan_tf'
/nix/store/g9js73bwv1fl92h1nnf50vf1619irnxf-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2/lib/gcc/mips64el-linux-gnu/4.7.2/libgcc.a(_addsub_tf.o): In function `__addtf3':
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:744:(.text+0x3c4): relocation truncated to fit: R_MIPS_CALL16 against `__unpack_t'
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:745:(.text+0x3e8): relocation truncated to fit: R_MIPS_CALL16 against `__unpack_t'
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:747:(.text+0x3f8): relocation truncated to fit: R_MIPS_GOT_PAGE against `.text'
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:747:(.text+0x404): relocation truncated to fit: R_MIPS_GOT_OFST against `.text'
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:749:(.text+0x410): relocation truncated to fit: R_MIPS_CALL16 against `__pack_t'
/nix/store/g9js73bwv1fl92h1nnf50vf1619irnxf-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2/lib/gcc/mips64el-linux-gnu/4.7.2/libgcc.a(_addsub_tf.o): In function `__subtf3':
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:764:(.text+0x454): relocation truncated to fit: R_MIPS_CALL16 against `__unpack_t'
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:765:(.text+0x478): relocation truncated to fit: R_MIPS_CALL16 against `__unpack_t'
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:769:(.text+0x488): relocation truncated to fit: R_MIPS_GOT_PAGE against `.text'
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:769:(.text+0x49c): relocation truncated to fit: R_MIPS_GOT_OFST against `.text'
/tmp/nix-build-gcc-cross-sans-libc-mips64el-linux-gnu-4.7.2.drv-0/build/mips64el-linux-gnu/libgcc/../../../gcc-4.7.2/libgcc/fp-bit.c:771:(.text+0x4ac): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status
make[2]: *** [/tmp/nix-build-glibc-cross-mips64el-linux-gnu-2.17.drv-0/build/libc.so] Error 1
make[2]: Leaving directory `/tmp/nix-build-glibc-cross-mips64el-linux-gnu-2.17.drv-0/glibc-2.17/elf'
make[1]: *** [elf/subdir_lib] Error 2
make[1]: Leaving directory `/tmp/nix-build-glibc-cross-mips64el-linux-gnu-2.17.drv-0/glibc-2.17'
make: *** [all] Error 2
phase `build' failed after 286 seconds
builder for `/nix/store/jk6f01ribh66daq71b1rzyijm7jqb8w1-glibc-cross-mips64el-linux-gnu-2.17.drv' failed with exit code 1
@ build-failed /nix/store/jk6f01ribh66daq71b1rzyijm7jqb8w1-glibc-cross-mips64el-linux-gnu-2.17.drv /nix/store/74147nkjp39bpiqcpzvmj2gw6a216jzc-glibc-cross-mips64el-linux-gnu-2.17 1 builder for `/nix/store/jk6f01ribh66daq71b1rzyijm7jqb8w1-glibc-cross-mips64el-linux-gnu-2.17.drv' failed with exit code 1
cannot build derivation `/nix/store/68m2mhwasx65793bnnwl4kadckw2rh30-gcc-cross-mips64el-linux-gnu-4.7.2.drv': 1 dependencies couldn't be built
error: build failed: build of `/nix/store/68m2mhwasx65793bnnwl4kadckw2rh30-gcc-cross-mips64el-linux-gnu-4.7.2.drv' failed
I'd also wanted to add "-march=mips64 -mabi=64" to 'cross' but failed to
do it properly.
[-- Attachment #2: Type: application/pgp-signature, Size: 835 bytes --]
next prev parent reply other threads:[~2013-03-28 9:33 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-27 20:05 Initial cross-compilation support Ludovic Courtès
2013-03-03 16:26 ` Andreas Enge
2013-03-03 21:32 ` Ludovic Courtès
2013-03-28 9:35 ` Nikita Karetnikov [this message]
2013-03-28 13:38 ` Ludovic Courtès
2013-03-28 21:00 ` Nikita Karetnikov
2013-03-28 22:41 ` Ludovic Courtès
2013-03-29 1:49 ` Nikita Karetnikov
2013-03-29 9:46 ` Ludovic Courtès
2013-03-29 21:20 ` Nikita Karetnikov
2013-03-29 21:39 ` Ludovic Courtès
2013-03-29 22:06 ` Nikita Karetnikov
2013-05-20 19:40 ` Ludovic Courtès
2013-05-21 18:46 ` Nikita Karetnikov
2013-05-21 20:04 ` Ludovic Courtès
2013-05-21 20:23 ` Nikita Karetnikov
2013-05-21 20:54 ` Nikita Karetnikov
2013-05-21 21:00 ` Ludovic Courtès
2013-03-04 0:19 ` Nikita Karetnikov
2013-03-04 10:10 ` Ludovic Courtès
2013-03-04 16:56 ` Nikita Karetnikov
2013-03-09 9:56 ` Nikita Karetnikov
2013-05-24 21:30 ` Ludovic Courtès
2013-05-24 21:59 ` Nikita Karetnikov
2013-05-24 22:26 ` Ludovic Courtès
2013-05-27 21:49 ` Ludovic Courtès
2013-05-24 22:04 ` Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87wqsrrho3.fsf@karetnikov.org \
--to=nikita@karetnikov.org \
--cc=bug-guix@gnu.org \
--cc=ludo@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).