diff options
author | Vladimír Čunát <vcunat@gmail.com> | 2017-02-27 18:03:34 +0100 |
---|---|---|
committer | Vladimír Čunát <vcunat@gmail.com> | 2017-02-27 18:18:39 +0100 |
commit | 78e4f9d8d7f6124713a7694140e44713fe70e209 (patch) | |
tree | 1972cbd91afa82f17410a129a15d512816270f3b /pkgs/development/libraries/libevent | |
parent | 079353e20851073e9b5de183ab24414d7cd54ccb (diff) | |
download | nixpkgs-78e4f9d8d7f6124713a7694140e44713fe70e209.tar nixpkgs-78e4f9d8d7f6124713a7694140e44713fe70e209.tar.gz nixpkgs-78e4f9d8d7f6124713a7694140e44713fe70e209.tar.bz2 nixpkgs-78e4f9d8d7f6124713a7694140e44713fe70e209.tar.lz nixpkgs-78e4f9d8d7f6124713a7694140e44713fe70e209.tar.xz nixpkgs-78e4f9d8d7f6124713a7694140e44713fe70e209.tar.zst nixpkgs-78e4f9d8d7f6124713a7694140e44713fe70e209.zip |
libevent: split _openssl into a separate output
... to save ~3.4 MB of openssl from the default closure.
Diffstat (limited to 'pkgs/development/libraries/libevent')
-rw-r--r-- | pkgs/development/libraries/libevent/default.nix | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/pkgs/development/libraries/libevent/default.nix b/pkgs/development/libraries/libevent/default.nix index 4abd0b03375..d2ba84bb5dd 100644 --- a/pkgs/development/libraries/libevent/default.nix +++ b/pkgs/development/libraries/libevent/default.nix @@ -23,11 +23,21 @@ stdenv.mkDerivation { | grep -v '^dh-autoreconf' | sed 's|^|debian/patches/|')" ''; - outputs = [ "out" "dev" ]; + # libevent_openssl is moved into its own output, so that openssl isn't present + # in the default closure. + outputs = [ "out" "dev" "openssl" ]; outputBin = "dev"; + propagatedBuildOutputs = [ "out" "openssl" ]; buildInputs = [ openssl ] ++ stdenv.lib.optional stdenv.isCygwin findutils; + postInstall = '' + moveToOutput "lib/libevent_openssl*" "$openssl" + substituteInPlace "$dev/lib/pkgconfig/libevent_openssl.pc" \ + --replace "$out" "$openssl" + sed "/^libdir=/s|$out|$openssl|" -i "$openssl"/lib/libevent_openssl.la + ''; + meta = with stdenv.lib; { description = "Event notification library"; longDescription = '' |