diff options
author | Nikolay Amiantov <ab@fmap.me> | 2016-04-26 15:27:05 +0300 |
---|---|---|
committer | Nikolay Amiantov <ab@fmap.me> | 2016-04-26 15:37:43 +0300 |
commit | c1e9ea6c86343541978593fe1af068d9d62d4e2a (patch) | |
tree | 53513c5347bc1460f0872a6b3f9fa2b2c4e5fe97 /pkgs/applications/misc/rxvt_unicode | |
parent | d40e636bdc27341ca8dc72b0dd6763126930138c (diff) |
rxvt_unicode-with-plugins: use symlinkJoin
Diffstat (limited to 'pkgs/applications/misc/rxvt_unicode')
-rw-r--r-- | pkgs/applications/misc/rxvt_unicode/wrapper.nix | 33 |
1 files changed, 13 insertions, 20 deletions
diff --git a/pkgs/applications/misc/rxvt_unicode/wrapper.nix b/pkgs/applications/misc/rxvt_unicode/wrapper.nix index 2f68e4ec5f11c..c9b0823fb51f8 100644 --- a/pkgs/applications/misc/rxvt_unicode/wrapper.nix +++ b/pkgs/applications/misc/rxvt_unicode/wrapper.nix @@ -1,28 +1,21 @@ -{ stdenv, buildEnv, rxvt_unicode, makeWrapper, plugins }: +{ stdenv, symlinkJoin, rxvt_unicode, makeWrapper, plugins }: let rxvt = rxvt_unicode.override { perlSupport = true; }; - drv = buildEnv { - name = "${rxvt.name}-with-plugins"; +in symlinkJoin { + name = "${rxvt.name}-with-plugins"; - paths = [ rxvt ] ++ plugins; + paths = [ rxvt ] ++ plugins; - postBuild = '' - # TODO: This could be avoided if buildEnv could be forced to create all directories - if [ -L $out/bin ]; then - rm $out/bin - mkdir $out/bin - for i in ${rxvt}/bin/*; do - ln -s $i $out/bin - done - fi - wrapProgram $out/bin/urxvt \ - --suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl" - wrapProgram $out/bin/urxvtd \ - --suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl" - ''; - }; -in stdenv.lib.overrideDerivation drv (x : { buildInputs = x.buildInputs ++ [ makeWrapper ]; }) + buildInputs = [ makeWrapper ]; + + postBuild = '' + wrapProgram $out/bin/urxvt \ + --suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl" + wrapProgram $out/bin/urxvtd \ + --suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl" + ''; +} |