Thread overview | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
May 30, 2015 (Probably trivial) arm-none-eabi-gdc building problem | ||||
---|---|---|---|---|
| ||||
Hi! I am tried to use step-by-step instructions from wiki (http://wiki.dlang.org/Bare_Metal_ARM_Cortex-M_GDC_Cross_Compiler) to build toolchain on Debian GNU/Linux 8 and got this error after execute "make -j4 all-target-libgcc": checking for arm-none-eabi-lipo... arm-none-eabi-lipo checking for arm-none-eabi-nm... /home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/nm checking for arm-none-eabi-ranlib... arm-none-eabi-ranlib checking for arm-none-eabi-strip... arm-none-eabi-strip checking whether ln -s works... yes checking for arm-none-eabi-gcc... /home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/xgcc -B/home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/bin/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/lib/ -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/include -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/sys-include checking for suffix of object files... configure: error: in `/home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/arm-none-eabi/libgcc': configure: error: cannot compute suffix of object files: cannot compile See `config.log' for more details. config.log: Configured with: ../gcc-4.9.2/configure --target=arm-none-eabi --prefix=/home/denizzz/dembed/arm-none-eabi-gdc/result --enable-languages=d --disable-bootstrap --disable-libssp --disable-libgomp --disable-libmudflap --disable-libphobos --disable-decimal-float --disable-libffi --disable-libmudflap --disable-libquadmath --disable-libssp --disable-libstdcxx --disable-libstdcxx-pch --disable-nls --disable-shared --disable-threads --disable-tls --with-gnu-as --with-gnu-ld --with-mode=thumb --without-headers Thread model: single gcc version 4.9.2 (GCC) configure:3373: $? = 0 configure:3362: /home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/xgcc -B/home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/bin/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/lib/ -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/include -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/sys-include -V >&5 xgcc: error: unrecognized command line option '-V' xgcc: fatal error: no input files compilation terminated. configure:3373: $? = 1 configure:3362: /home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/xgcc -B/home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/bin/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/lib/ -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/include -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/sys-include -qversion >&5 xgcc: error: unrecognized command line option '-qversion' xgcc: fatal error: no input files compilation terminated. configure:3373: $? = 1 configure:3389: /home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/xgcc -B/home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/bin/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/lib/ -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/include -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/sys-include -o conftest -g -O2 conftest.c >&5 /home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/as: 106: exec: -meabi=5: not found configure:3392: $? = 1 configure:3580: checking for suffix of object files configure:3602: /home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/xgcc -B/home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/bin/ -B/home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/lib/ -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/include -isystem /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/sys-include -c -g -O2 conftest.c >&5 /home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/./gcc/as: 106: exec: -meabi=5: not found configure:3606: $? = 1 Why config trying to use deprecated gcc option -V? How to fix this? Same problem discussion on github: https://github.com/JinShil/arm-none-eabi-gdc/issues/1 |
May 30, 2015 Re: (Probably trivial) arm-none-eabi-gdc building problem | ||||
---|---|---|---|---|
| ||||
Posted in reply to denizzzka | On Saturday, 30 May 2015 at 16:55:14 UTC, denizzzka wrote: > Hi! > > I am tried to use step-by-step instructions from wiki (http://wiki.dlang.org/Bare_Metal_ARM_Cortex-M_GDC_Cross_Compiler) to build toolchain on Debian GNU/Linux 8 and got this error after execute "make -j4 all-target-libgcc": > > I did not read the whole thing but this: > checking for suffix of object files... configure: error: in `/home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/arm-none-eabi/libgcc': > configure: error: cannot compute suffix of object files: cannot compile > See `config.log' for more details. > may mean that target binutils are not installed or not found (arm-none-eabi-asm arm-none-eabi-ld etc) Another reason may be wrong configuration options that cause the intermediate compiler fail. The error message is a bit misleading. It means that something we just built does not run or does not find all it needs. Also I have found several times that using -j4 may be too much. One of the jobs may run too fast and does not find something the other jobs have not build yet. Using -j2 has always worked for me. |
June 03, 2015 Re: (Probably trivial) arm-none-eabi-gdc building problem | ||||
---|---|---|---|---|
| ||||
Posted in reply to denizzzka | On Saturday, 30 May 2015 at 16:55:14 UTC, denizzzka wrote: > Hi! > > I am tried to use step-by-step instructions from wiki (http://wiki.dlang.org/Bare_Metal_ARM_Cortex-M_GDC_Cross_Compiler) to build toolchain on Debian GNU/Linux 8 and got this error after execute "make -j4 all-target-libgcc": [snip] I just wanted to let you know that in case you couldn't get a build on your host PC, there may be another way to get a GDC ARM Cortex-M cross-compiler. It has come to my attention that the prebuilt binaries at http://gdcproject.org/downloads are capable of creating ARM Cortex-M binaries. I just tested it myself. I used the arm-linux-gnueabihf build, and the command I used for my STM32F4 (ARM Cortex-M4F) was: arm-gdcproject-linux-gnueabi-gdc -fno-emit-moduleinfo -frelease -mthumb -mcpu=cortex-m4 -fdata-sections -ffunction-sections -c start.d The key is to simply add the platform flags: -mthumb -mcpu=cortex-m4 I hope that helps. Mike |
June 03, 2015 Re: (Probably trivial) arm-none-eabi-gdc building problem | ||||
---|---|---|---|---|
| ||||
Posted in reply to Mike | On Wednesday, 3 June 2015 at 10:50:26 UTC, Mike wrote:
> On Saturday, 30 May 2015 at 16:55:14 UTC, denizzzka wrote:
>> Hi!
>>
>> I am tried to use step-by-step instructions from wiki (http://wiki.dlang.org/Bare_Metal_ARM_Cortex-M_GDC_Cross_Compiler) to build toolchain on Debian GNU/Linux 8 and got this error after execute "make -j4 all-target-libgcc":
> [snip]
>
> I just wanted to let you know that in case you couldn't get a build on your host PC, there may be another way to get a GDC ARM Cortex-M cross-compiler.
>
> It has come to my attention that the prebuilt binaries at http://gdcproject.org/downloads are capable of creating ARM Cortex-M binaries. I just tested it myself.
>
> I used the arm-linux-gnueabihf build, and the command I used for my STM32F4 (ARM Cortex-M4F) was:
> arm-gdcproject-linux-gnueabi-gdc -fno-emit-moduleinfo -frelease -mthumb -mcpu=cortex-m4 -fdata-sections -ffunction-sections -c start.d
>
> The key is to simply add the platform flags: -mthumb -mcpu=cortex-m4
>
> I hope that helps.
>
> Mike
That's correct. All ARM GCC compilers can generate code for all ARM variants (the hf compiler can generate softfloat code and the softfloat compiler can generate hf code as well). The difference between the compilers are the shipped libraries. You probably can't use the shipped libgcc etc from these compilers for thumb targets.
|
June 04, 2015 Re: (Probably trivial) arm-none-eabi-gdc building problem | ||||
---|---|---|---|---|
| ||||
Posted in reply to Johannes Pfau | On Wednesday, 3 June 2015 at 12:54:32 UTC, Johannes Pfau wrote: > > That's correct. All ARM GCC compilers can generate code for all ARM variants (the hf compiler can generate softfloat code and the softfloat compiler can generate hf code as well). The difference between the compilers are the shipped libraries. You probably can't use the shipped libgcc etc from these compilers for thumb targets. I was not aware of this, but it makes perfect sense. Would it be feasible to uses Timo's multilib instructions (http://forum.dlang.org/post/knajzsqzojwrogzafmst@forum.dlang.org) to add support for the Cortex-M variants to the ARM pre-built binaries (excluding libphobos of course)? Also, are the build-scripts used for the pre-built binaries on GitHub? |
June 04, 2015 Re: (Probably trivial) arm-none-eabi-gdc building problem | ||||
---|---|---|---|---|
| ||||
Posted in reply to Mike | Am Thu, 04 Jun 2015 04:05:39 +0000 schrieb "Mike" <none@none.com>: > On Wednesday, 3 June 2015 at 12:54:32 UTC, Johannes Pfau wrote: > > > > That's correct. All ARM GCC compilers can generate code for all ARM variants (the hf compiler can generate softfloat code and the softfloat compiler can generate hf code as well). The difference between the compilers are the shipped libraries. You probably can't use the shipped libgcc etc from these compilers for thumb targets. > > I was not aware of this, but it makes perfect sense. > > Would it be feasible to uses Timo's multilib instructions (http://forum.dlang.org/post/knajzsqzojwrogzafmst@forum.dlang.org) to add support for the Cortex-M variants to the ARM pre-built binaries (excluding libphobos of course)? If you mean adding support to the same binary toolchain package: I don't think that will work. Multilib requires similar systems, it's probably not possible to mix linux+libphobos and baremetal builds. But we could of course provide additional ARM-bare-metal toolchain binaries. > > Also, are the build-scripts used for the pre-built binaries on GitHub? Not yet. Maybe I'll publish them this weekend (I need to write some documentation first) |
June 05, 2015 Re: (Probably trivial) arm-none-eabi-gdc building problem | ||||
---|---|---|---|---|
| ||||
Posted in reply to Johannes Pfau | On Thursday, 4 June 2015 at 18:35:45 UTC, Johannes Pfau wrote: > If you mean adding support to the same binary toolchain package: I don't think that will work. Multilib requires similar systems, it's probably not possible to mix linux+libphobos and baremetal builds. Indeed. I completely glossed over the linux-gnueabi there. > But we could of course provide additional ARM-bare-metal toolchain binaries. Given the post that started this thread, I think that would be great even if they didn't include libphobos or even a standard C library. Just having libgcc and the compiler would be a sufficient start in my opinion. Mike |
June 05, 2015 Re: (Probably trivial) arm-none-eabi-gdc building problem | ||||
---|---|---|---|---|
| ||||
Posted in reply to denizzzka | On Saturday, 30 May 2015 at 16:55:14 UTC, denizzzka wrote: > Hi! > {snip} > /home/denizzz/dembed/arm-none-eabi-gdc/result/arm-none-eabi/sys-include > checking for suffix of object files... configure: error: in `/home/denizzz/dembed/arm-none-eabi-gdc/gcc-build/arm-none-eabi/libgcc': > configure: error: cannot compute suffix of object files: cannot compile > See `config.log' for more details. Usually this means that you need to set your PATH to point to your target binaries. This should normally be set right after you've installed binutils. It might be helpful to look at my PDF and build-script ... <http://d.gpio.dk/> It's made for Mac/PPC only. I've tried the build-script on Debian, but it fails (due to problems with ARM7TDMI). |
Copyright © 1999-2021 by the D Language Foundation