diff options
author | Martin Weinelt <mweinelt@users.noreply.github.com> | 2021-05-07 22:33:13 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-07 22:33:13 +0200 |
commit | 2d64c6d79bc5f9071fec3045161093c551875042 (patch) | |
tree | f7fbfb3f2b7070a6b7111962b5352b96c8414dcc /pkgs/development/libraries/igraph/default.nix | |
parent | 72755406669073a469b655429f1a9d967bd8cf46 (diff) |
igraph: enable autodetection for LTO support (#122058)
> The IGRAPH_ENABLE_LTO build option now supports the AUTO value, which > uses LTO only if the compiler supports it. Warning: CMake may not > always be able to detect that LTO is not fully supported. Therefore, > the default setting is OFF. https://igraph.org/2021/03/23/igraph-0.9.1-c.html
Diffstat (limited to 'pkgs/development/libraries/igraph/default.nix')
-rw-r--r-- | pkgs/development/libraries/igraph/default.nix | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/pkgs/development/libraries/igraph/default.nix b/pkgs/development/libraries/igraph/default.nix index 8dab59e99472a..29e12cc8541d0 100644 --- a/pkgs/development/libraries/igraph/default.nix +++ b/pkgs/development/libraries/igraph/default.nix @@ -77,15 +77,17 @@ stdenv.mkDerivation rec { "-DIGRAPH_USE_INTERNAL_GMP=OFF" "-DIGRAPH_GLPK_SUPPORT=ON" "-DIGRAPH_GRAPHML_SUPPORT=ON" - "-DIGRAPH_ENABLE_LTO=ON" + "-DIGRAPH_ENABLE_LTO=AUTO" "-DIGRAPH_ENABLE_TLS=ON" "-DBUILD_SHARED_LIBS=ON" ]; doCheck = true; - preCheck = '' - # needed to find libigraph.so + # needed to find libigraph, and liblas on darwin + preCheck = if stdenv.isDarwin then '' + export DYLD_LIBRARY_PATH="${lib.makeLibraryPath [ blas ]}:$PWD/src" + '' else '' export LD_LIBRARY_PATH="$PWD/src" ''; |