D for embedded system

Timo Sintonen t.sintonen at luukku.com
Wed Jan 9 22:26:24 PST 2013


On Wednesday, 9 January 2013 at 08:31:01 UTC, Freddie Chopin 
wrote:

> but actually I was hoping I could "drop" GDC into a linaro  
> distribution of ARM bare-metal toolchain - 
> launchpad.net/gcc-arm-embedded - it's a 4.7.x version, I don't 
> know how big problem that is... So I haven't yet tried 
> compiling the toolchain, but I guess that without your files it 
> would not work anyway, right? (;
>
You can and in this case you should make the toolchain first 
without library. It is possible to compile programs with gdc 
without the library as long as only c style functions are used.
A working linker script is needed to make the executable and a 
proper startup file is needed to make the executable work in the 
target platform. A suitable bootloader is needed to transfer the 
executable to the target processor.

When all these are working, the runtime library is needed.

The toolchain in https://launchpad.net/gcc-arm-embedded seems to 
be a good starting point for arm cortex processors. It has all 
the tools and also suitable linker scripts and startup files. But 
it is not aware of D.

As mentioned earlier in this thread, nobody has made this yet. So 
there is not an easy way to go. As long as gdc is not part of the 
gcc package, some extra work is always needed.
If the toolchain works, it is worth of try to replace gcc in 
there with the newest gcc with d patches. Some modifications are 
needed in the build script to enable d and disable libphobos.




More information about the D.gnu mailing list