On Sat, Aug 20, 2016 at 7:38 PM, <stim...@comcast.net> wrote: > The whole cross-architecture situation complicates things...in particular > I'm wondering "which" binutils (host versus target sysroot) we are talking > about? I'm trying to figure out if the missing binutils is from the armhf > sysroot or from the x86_64 host I'm building on. There is an armhf > binutils-dev package on the armhf build sysroot, and binutils-dev package on > the aarch64 build sysroot (both the armhf and aarch64 sysroots include > everything needed to build, link, and develop for their particular > architecuture on the systems they were cloned from).
The assembler in the sysroot is an armhf binary, which won't run on the x86_64 host (well, maybe with QEMU but that isn't the right approach). You need a x86_64 cross to armhf binutils on the host. You apparently don't have one. Normal process is to configure/build/install binutils first, and then configure/build/install gcc, using the same configure options for binutils and gcc, in particular prefix and sysroot. A cross gcc can't be built without a cross binutils. A cross binutils doesn't have dependencies on anything else. So binutlis has to be built first. > The x86_64 host has native packages for everything, but in a few cases has > some cross-architecture packages. "as" is missing according to the > config.log, but the assembler is present for native x86_64 and aarch64 > cross-assembling. Would it be correct that the missing packages are > cross-architecture armhf needing to be installed on the x86_64 host, and > that build sysroot is unrelated to the missing package? It seems I probably > need x86_64 host binutils cross-assembling to armhf. Yes, if you are on a debian/ubuntu host, then installing the gcc-arm-linux-gnueabihf package might be sufficient to get the cross binutils that you need. > If I need to build cross-binutils and such, is there any reason to not use > pre-compiled binaries from Linaro 5.2 or 5.3 tool chains? You could try this, but it might end up a bit awkward. GCC needs to be able to find the assembler both at build time, and at run time. The normal way this works is that binutils and gcc must be configured with the same prefix. If you use an assembler from a linaro toolchain, it might not be the same prefix. Perhaps you can arrange to install your gcc build over top the linaro binutils binaries, so that the prefix can be the same. Yes, building cross compilers is complicated. It takes some time to learn how to do it. Jim _______________________________________________ linaro-toolchain mailing list linaro-toolchain@lists.linaro.org https://lists.linaro.org/mailman/listinfo/linaro-toolchain