[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Two wishlist patches submitted to allow static build of binutils and gcc



I have submitted two wishlist bugs with patches that may be of embedded interest.

binutils
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=590101

gcc-4.4
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=590102

These are to allow the building of static toolchains by passing an environment variable 'BUILD_STATIC=yes' on the dpkg-buildpackage command line. While static tools are usually not what people normally use, they can be of interest I have found in certain situations.

The rationale for providing the ability to compile a statically linked binutils and gcc is to allow greater portability of that toolchain to environments other than the stock Debian environment in which the toolchain was built. This becomes especially interesting in the embedded world where cross compilers (such as ones that can be created in Debian) have long lifetimes and can be deployed to varied buildserver enviroments to support cross compiling software for target embedded systems. It removes the dependence on such things as having the exact correct version of GLIBC (and other libraries) installed on the buildserver and makes the toolchain standalone. A static toolchain also provides the ultimate in repeatablilty, since it does not depend on dynamically loadable modules that can change on the build system.

Static toolchains can still compile executables that are themselves dynamically linked. It is only the tools themselves that have been statically linked.

-Jim



Reply to: