1 { pkgs ? import ./pinned-22.05.nix {} }:
5 ghc = pkgs.haskell.compiler.ghc8107;
6 igraph_0_10_4 = pkgs.igraph.overrideAttrs (finalAttrs: previousAttrs: {
9 src = pkgs.fetchFromGitHub {
13 hash = "sha256-LsTOxUktGZcp46Ec9QH3+9C+VADMYTZZCjKF1gp36xk=";
17 echo "0.10.4" > IGRAPH_VERSION
20 outputs = [ "out" "doc" ];
30 ] ++ pkgs.lib.optionals pkgs.stdenv.cc.isClang [
31 pkgs.llvmPackages.openmp
35 "-DIGRAPH_USE_INTERNAL_BLAS=OFF"
36 "-DIGRAPH_USE_INTERNAL_LAPACK=OFF"
37 "-DIGRAPH_USE_INTERNAL_ARPACK=OFF"
38 "-DIGRAPH_USE_INTERNAL_GLPK=OFF"
39 "-DIGRAPH_USE_INTERNAL_GMP=OFF"
40 "-DIGRAPH_USE_INTERNAL_PLFIT=OFF"
41 "-DIGRAPH_GLPK_SUPPORT=ON"
42 "-DIGRAPH_GRAPHML_SUPPORT=ON"
43 "-DIGRAPH_OPENMP_SUPPORT=ON"
44 "-DIGRAPH_ENABLE_LTO=AUTO"
45 "-DIGRAPH_ENABLE_TLS=ON"
46 "-DBUILD_SHARED_LIBS=ON"
51 cp -r doc "$out/share"
54 postFixup = previousAttrs.postFixup + ''
56 cd "$out/include/igraph" && cp *.h ../
65 nonhsBuildInputs = with pkgs; [
72 #haskell-language-server
91 ] ++ ( lib.optionals stdenv.isDarwin [
92 darwin.apple_sdk.frameworks.Accelerate
94 libPaths = pkgs.lib.makeLibraryPath nonhsBuildInputs;
96 export LD_LIBRARY_PATH="${pkgs.gfortran7.cc.lib}:${libPaths}:$LD_LIBRARY_PATH"
97 export LIBRARY_PATH="${pkgs.gfortran7.cc.lib}:${libPaths}"
99 shell = pkgs.mkShell {
100 name = "gargantext-shell";
101 buildInputs = hsBuildInputs ++ nonhsBuildInputs;