Merge pull request #5855 from peti/dont-use-special-gmp-variant-for-haskell
Enable static libraries in "gmp" to allow static linking of Haskell programs.
This commit is contained in:
commit
ef6b18c0ec
@ -1,8 +1,8 @@
|
||||
{ stdenv, fetchurl, m4, cxx ? true, withStatic ? false }:
|
||||
{ stdenv, fetchurl, m4, cxx ? true, withStatic ? true }:
|
||||
|
||||
with { inherit (stdenv.lib) optional; };
|
||||
|
||||
stdenv.mkDerivation (rec {
|
||||
stdenv.mkDerivation rec {
|
||||
name = "gmp-5.1.3";
|
||||
|
||||
src = fetchurl { # we need to use bz2, others aren't in bootstrapping stdenv
|
||||
@ -30,6 +30,8 @@ stdenv.mkDerivation (rec {
|
||||
|
||||
doCheck = true;
|
||||
|
||||
dontDisableStatic = withStatic;
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
@ -63,6 +65,3 @@ stdenv.mkDerivation (rec {
|
||||
maintainers = [ maintainers.simons ];
|
||||
};
|
||||
}
|
||||
// stdenv.lib.optionalAttrs withStatic { dontDisableStatic = true; }
|
||||
)
|
||||
|
||||
|
@ -3494,7 +3494,7 @@ let
|
||||
|
||||
# Import Haskell infrastructure.
|
||||
|
||||
haskell = let pkgs_ = pkgs // { gmp = gmp.override { withStatic = true; }; };
|
||||
haskell = let pkgs_ = pkgs // { /* add necessary overrides here */ };
|
||||
callPackage = newScope pkgs_;
|
||||
newScope = extra: lib.callPackageWith (pkgs_ // pkgs_.xorg // extra);
|
||||
in callPackage ./haskell-defaults.nix { pkgs = pkgs_; inherit callPackage newScope; };
|
||||
|
@ -14,24 +14,24 @@ rec {
|
||||
libiconv = pkgs.darwin.libiconv;
|
||||
});
|
||||
|
||||
ghc6104 = callPackage ../development/compilers/ghc/6.10.4.nix { ghc = compiler.ghc6102Binary; gmp = pkgs.gmp.override { withStatic = true; }; };
|
||||
ghc6123 = callPackage ../development/compilers/ghc/6.12.3.nix { ghc = compiler.ghc6102Binary; gmp = pkgs.gmp.override { withStatic = true; }; };
|
||||
ghc704 = callPackage ../development/compilers/ghc/7.0.4.nix ({ ghc = compiler.ghc704Binary; gmp = pkgs.gmp.override { withStatic = true; }; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
ghc6104 = callPackage ../development/compilers/ghc/6.10.4.nix { ghc = compiler.ghc6102Binary; };
|
||||
ghc6123 = callPackage ../development/compilers/ghc/6.12.3.nix { ghc = compiler.ghc6102Binary; };
|
||||
ghc704 = callPackage ../development/compilers/ghc/7.0.4.nix ({ ghc = compiler.ghc704Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
libiconv = pkgs.darwin.libiconv;
|
||||
});
|
||||
ghc722 = callPackage ../development/compilers/ghc/7.2.2.nix ({ ghc = compiler.ghc704Binary; gmp = pkgs.gmp.override { withStatic = true; }; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
ghc722 = callPackage ../development/compilers/ghc/7.2.2.nix ({ ghc = compiler.ghc704Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
libiconv = pkgs.darwin.libiconv;
|
||||
});
|
||||
ghc742 = callPackage ../development/compilers/ghc/7.4.2.nix ({ ghc = compiler.ghc704Binary; gmp = pkgs.gmp.override { withStatic = true; }; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
ghc742 = callPackage ../development/compilers/ghc/7.4.2.nix ({ ghc = compiler.ghc704Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
libiconv = pkgs.darwin.libiconv;
|
||||
});
|
||||
ghc763 = callPackage ../development/compilers/ghc/7.6.3.nix ({ ghc = compiler.ghc704Binary; gmp = pkgs.gmp.override { withStatic = true; }; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
ghc763 = callPackage ../development/compilers/ghc/7.6.3.nix ({ ghc = compiler.ghc704Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
libiconv = pkgs.darwin.libiconv;
|
||||
});
|
||||
ghc784 = callPackage ../development/compilers/ghc/7.8.4.nix ({ ghc = compiler.ghc742Binary; gmp = pkgs.gmp.override { withStatic = true; }; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
ghc784 = callPackage ../development/compilers/ghc/7.8.4.nix ({ ghc = compiler.ghc742Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
libiconv = pkgs.darwin.libiconv;
|
||||
});
|
||||
ghc7101 = callPackage ../development/compilers/ghc/7.10.1.nix ({ ghc = compiler.ghc784; gmp = pkgs.gmp.override { withStatic = true; }; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
ghc7101 = callPackage ../development/compilers/ghc/7.10.1.nix ({ ghc = compiler.ghc784; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
libiconv = pkgs.darwin.libiconv;
|
||||
});
|
||||
ghcHEAD = callPackage ../development/compilers/ghc/head.nix ({ inherit (packages.ghc784) ghc alex happy; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
||||
|
Loading…
Reference in New Issue
Block a user