View mode: basic / threaded / horizontal-split · Log in · Help
March 15, 2007
Proposal to make building cross compilers easier
Currently the major impediment to building cross compilers is creating the frag-gen, frag-math, and frag-unix files. This requires cross compiling the generator programs, then running them on the target, then moving the output back to the host and rebuilding with --enable-phobos-config-dir. This especially becomes a problem if you are trying to make a simple, reproducable, build system, or if you are using crosstool to generate your cross compilers.

There is no good reason for these files to be generated at build time. It isn't like they change for a given target configuration. What would make this work much better would be to create directories under d/phobos/config with target config names like powerpc-603-linux-gnu or x86-pc-linux-gnu. The config script could look first for the presence of a directory with a name matching the current $(target) variable and, if found, automatically configure it. 

This would still allow dynamic configuration, but the major supported targets wouldn't need it. It would also make for easy patching of the source distribution for any configuration to create a push button archive.

I would like to see this implemented in the next version. Unfortunately, my powers of autoconfig are not very well developed, or I would offer to do the work...

Matt
Top | Discussion index | About this forum | D home