Hi Stefan, Thanks. Kudos also go to Richie for his old gcc49 Hackweek project for openSUSE glibc targets, without which I wouldn't have come this far. Am 15.05.2016 um 19:11 schrieb Stefan Bruens:
As far as I understand your current work would be usable also for arm-none- eabi toolchains, e.g. for the STM32Fxxx series?
First of all, I had demonstrated back in 2014 that it's possible to use our armv7l gcc on an ARM board for developing for STM32F429 [1] under some constraints, namely the lack of a suitable libgcc. For U-Boot I had to enable (and tweak) its private libgcc copy; Linux built fine; and as bootloader I created my own afboot-stm32 [2] that was trivial enough not to have the libgcc dependency in the first place. If you need a linker script, feel free to use mine as template. One could probably use qemu-linux-user to run a native armv7hl gcc in a chroot on x86_64, but it'll be cumbersome and slow. Now for cross-compiling I believe we're still stuck with just one cross-arm-binutils, which does not work for cross-armv7hl-gcc5 (boo#936463) - the safest solution seems duplicating binutils packages to match the name gcc expects and offering a separate sysroot. For uClibc I therefore SR'ed binutils to allow, e.g., armv7ml-uclibc as target name, so in theory arm-none should be possible, too. You would probably also want multilib support for such targets, i.e. multiple copies of libraries to cope with Cortex-M0 vs. M3 vs. M4F etc. But my plan is to start with some simple target like Epiphany and move on to more complicated ones such as ARM later. :) The biggest hurdle has been gcc being a moving target, with its changing tarball names frequently breaking branches for new targets. Another issue has been about target installation, where gcc built okay but some target files ended up in an x86_64 lib64 subdirectory where they were not searched for 32-bit targets. If you want to play with it, note that while you can branch binutils as cross-foo-binutils and newlib as cross-foo-newlib-devel to add your target, you must branch gcc5 as gcc5 and create a project-local link for cross-foo-gcc5. Cheers, Andreas [1] https://en.opensuse.org/openSUSE:ARM_Tech_Symposia_2014/STM32F429 [2] https://github.com/afaerber/afboot-stm32 -- SUSE Linux GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB 21284 (AG Nürnberg) -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org