diff options
author | Lluís Batlle i Rossell <viric@vicerveza.homeunix.net> | 2010-02-01 19:55:40 +0000 |
---|---|---|
committer | Lluís Batlle i Rossell <viric@vicerveza.homeunix.net> | 2010-02-01 19:55:40 +0000 |
commit | 1741bb2597a152821474242ad1a9b37a4d171ed9 (patch) | |
tree | 1df65e3f8e531052fafa6884d084d919b5a8e281 /pkgs/development/libraries/boost | |
parent | 936f161c001e677b1772952f288308e21560c392 (diff) | |
download | nixlib-1741bb2597a152821474242ad1a9b37a4d171ed9.tar nixlib-1741bb2597a152821474242ad1a9b37a4d171ed9.tar.gz nixlib-1741bb2597a152821474242ad1a9b37a4d171ed9.tar.bz2 nixlib-1741bb2597a152821474242ad1a9b37a4d171ed9.tar.lz nixlib-1741bb2597a152821474242ad1a9b37a4d171ed9.tar.xz nixlib-1741bb2597a152821474242ad1a9b37a4d171ed9.tar.zst nixlib-1741bb2597a152821474242ad1a9b37a4d171ed9.zip |
Making 'boost' optionally build with -fPIC (with enableStatic, will produce
static libraries linkable in a shared object) svn path=/nixpkgs/trunk/; revision=19759
Diffstat (limited to 'pkgs/development/libraries/boost')
-rw-r--r-- | pkgs/development/libraries/boost/1.41.0.nix | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/pkgs/development/libraries/boost/1.41.0.nix b/pkgs/development/libraries/boost/1.41.0.nix index 7b1166fb656f..1bd500e270a2 100644 --- a/pkgs/development/libraries/boost/1.41.0.nix +++ b/pkgs/development/libraries/boost/1.41.0.nix @@ -5,6 +5,7 @@ , enableMultiThreaded ? true , enableShared ? true , enableStatic ? false +, enablePIC ? false }: let @@ -27,6 +28,8 @@ let (enableShared && enableStatic)) then "tagged" else "system"; + cflags = if (enablePIC) then "cflags=-fPIC cxxflags=-fPIC linkflags=-fPIC" else ""; + in stdenv.mkDerivation { @@ -48,7 +51,7 @@ stdenv.mkDerivation { configureScript = "./bootstrap.sh"; configureFlags = "--with-icu=${icu} --with-python=${python}/bin/python"; - buildPhase = "./bjam -sEXPAT_INCLUDE=${expat}/include -sEXPAT_LIBPATH=${expat}/lib --layout=${finalLayout} variant=${variant} threading=${threading} link=${link} install"; + buildPhase = "./bjam -sEXPAT_INCLUDE=${expat}/include -sEXPAT_LIBPATH=${expat}/lib --layout=${finalLayout} variant=${variant} threading=${threading} link=${link} ${cflags} install"; installPhase = ":"; } |