Merge pull request #8023 from thinkpad20/pure_liblapack

added cmake flag to prevent autodetection of SDK directory
This commit is contained in:
Peter Simons 2015-05-28 21:44:07 +02:00
commit bcd5dc6bac

View file

@ -3,6 +3,7 @@ let
atlasMaybeShared = atlas.override { inherit shared; };
usedLibExtension = if shared then ".so" else ".a";
version = "3.4.1";
inherit (stdenv.lib) optional;
in
stdenv.mkDerivation rec {
name = "liblapack-${version}";
@ -21,7 +22,10 @@ stdenv.mkDerivation rec {
"-DBLAS_ATLAS_atlas_LIBRARY=${atlasMaybeShared}/lib/libatlas${usedLibExtension}"
"-DCMAKE_Fortran_FLAGS=-fPIC"
]
++ (stdenv.lib.optional shared "-DBUILD_SHARED_LIBS=ON")
++ (optional shared "-DBUILD_SHARED_LIBS=ON")
# If we're on darwin, CMake will automatically detect impure paths. This switch
# prevents that.
++ (optional stdenv.isDarwin "-DCMAKE_OSX_SYSROOT:PATH=''")
;
doCheck = ! shared;