|
OpenBSD Packages and Ports Installation and upgrading of packages and ports on OpenBSD. |
|
Thread Tools | Display Modes |
|
|||
Cross compiling from Linux to OpenBSD with gcc
Hello,
I hope not have been in wrong section. I was trying to build from scratch a cross-compiler from x86_64 Linux to x86_64 OpenBSD 5.6, but I encountered some problems. I fail making binutils and this is the error: **** ld does not support target x86_64-pc-openbsd5.6 As much as I can understand linker doesn't support x86_64-pc-openbsd5.6 triplet, but why? I know that is possible compile gcc for openbsd system. However this is configuration with flags: ../gcc-4.9.2/configure --target="amd64-openbsd5.6" --prefix="/usr/local/cross" --with-gnu-as --with-gnu-ld --enable-languages=c,c++ --disable-nls --enable-libssp --enable-gold --enable-ld --with-sysroot="/usr/local/sysroot/openbsd5.6" $opt --disable-libgomp Any ideas? Thank you in advance. |
|
|||
You need OUR binutils and gcc from our source tree if you even hope to have a chance at being successful at this.
But I must ask: why do you want to cross compile OpenBSD? There's only maybe one or two things I can think of for why and I would definitely discourage you from doing this unless you absolutely need to. |
|
|||
Quote:
So, where can I find YOUR binutils and gcc? Thank you! |
|
||||
In the branch of the OpenBSD source tree that contains GPL-licensed components: src/gnu. Specifically, you will find these tools here: src/gnu/usr.bin/{binutils,binutils-2.17,gcc}
Obtaining the correct "flavor" of the OpenBSD source tree is discussed in OpenBSD FAQ 5, Building the System from Source. |
|
|||
Quote:
That guide it's ok to compile system, but also cross-compile gcc and binutils only? Thank you |
Tags |
binutils, cross-compiler, gcc, linux, openbsd |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
How to cross-compile the kernel? | Skinny | OpenBSD General | 11 | 26th November 2012 05:38 PM |
Cross compile on ADM5120 | martijn | NetBSD General | 0 | 21st September 2010 08:08 PM |
Kernel and cross compiling on OpenBSD | Mr-Biscuit | Programming | 3 | 7th September 2010 04:35 AM |
Delete compilers to cross compile | revzalot | OpenBSD Installation and Upgrading | 9 | 28th August 2009 08:06 PM |
Compiling OpenBSD code | WeakSauceIII | OpenBSD General | 4 | 19th May 2008 12:59 AM |