mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-24 06:33:42 +00:00
27 lines
723 B
Nix
27 lines
723 B
Nix
{ stdenv, fetchurl, gcc, staticBuild ? false }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
name = "libiberty-${gcc.cc.version}";
|
|
|
|
inherit (gcc.cc) src;
|
|
|
|
outputs = [ "out" "dev" ];
|
|
|
|
postUnpack = "sourceRoot=\${sourceRoot}/libiberty";
|
|
|
|
configureFlags = [ "--enable-install-libiberty" ]
|
|
++ stdenv.lib.optional (!staticBuild) "--enable-shared";
|
|
|
|
postInstall = stdenv.lib.optionalString (!staticBuild) ''
|
|
cp pic/libiberty.a $out/lib*/libiberty.a
|
|
'';
|
|
|
|
meta = with stdenv.lib; {
|
|
homepage = http://gcc.gnu.org/;
|
|
license = licenses.lgpl2;
|
|
description = "Collection of subroutines used by various GNU programs";
|
|
maintainers = with maintainers; [ abbradar ericson2314 ];
|
|
platforms = platforms.unix;
|
|
};
|
|
}
|