Re: How to force gcc to build always statically linked binaries?

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

 



Hi Ioannis,

Try this (in shorthand):

mkdir ~/MySpoofedGCC

PATH=~/MySpoofedGCC:$PATH

vi ~/MySpoofedGCC/gcc
-----------------
#!/bin/bash

/bin/gcc -static "$@"
-----------------

Does that make sense?

I've used that successfully to put in a few flags I wanted everywhere and
always, such as -D_GLIBCXX_FULLY_DYNAMIC_STRING.  But I used a BIG HAMMER.
I changed gcc to gcc-real, and made my script where gcc was located.  That
works on a personal machine, but would make people upset if it was a shared
gcc for a lot of people.

--Eljay


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux