[parsec-users] compiling statically linked vips binary

jcupitt at gmail.com jcupitt at gmail.com
Wed Apr 30 06:34:26 EDT 2008

2008/4/30 Kshitij Sudan <kshitij at cs.utah.edu>:
>  I am trying to compile vips for Linux, such that it's statically
>  linked. I edited gcc.bldconf in $PARSEC/config and also vips specific
>  gcc.bldconf file by adding  -static and -static-libgcc to CCFLAGS,
>  CXXFLAG, and LDFLAGS. Still at the end of compilation, it produces a
>  dynamically linked executable. I am building it using "parsecmgmt"
>  tool.

vips is linked with libtool which (strangely) has it's own
interpretation of these flags. libtool -static means link the object
against the static versions of any uninstalled libtool libraries, but
link dynamically otherwise. -static-all means link against the static
versions of all libraries, including libtool, native, installed and
uninstalled. At least that's my understanding.

Unfortunately, you can't pass -all-static to configure, because then
the compiler sees it (since configure is not using libtool) and
breaks. Instead you have to do:

  make LDFLAGS=-all-static


More information about the parsec-users mailing list