munin: simplify setting of PERL5PATH
Use lib.makePerlPath instead of manually duplicating "/lib/perl5/site_perl" all over.
This commit is contained in:
parent
920f6007fa
commit
f2d5fe86bd
1 changed files with 5 additions and 6 deletions
|
@ -99,18 +99,17 @@ stdenv.mkDerivation rec {
|
|||
ln -s $out/nix-support/propagated-native-build-inputs $out/nix-support/propagated-user-env-packages
|
||||
fi
|
||||
|
||||
# TODO: toPerlLibPath can be added to
|
||||
# pkgs/development/interpreters/perl5.16/setup-hook.sh (and the other perl
|
||||
# versions) just like for python. NOTE: it causes massive rebuilds.
|
||||
# $(toPerlLibPath $out perlPackages.Log4Perl ...)
|
||||
|
||||
for file in "$out"/bin/munindoc "$out"/sbin/munin-* "$out"/lib/munin-* "$out"/www/cgi/*; do
|
||||
# don't wrap .jar files
|
||||
case "$file" in
|
||||
*.jar) continue;;
|
||||
esac
|
||||
wrapProgram "$file" \
|
||||
--set PERL5LIB "$out/lib/perl5/site_perl:${perlPackages.Log4Perl}/lib/perl5/site_perl:${perlPackages.IOSocketInet6}/lib/perl5/site_perl:${perlPackages.Socket6}/lib/perl5/site_perl:${perlPackages.URI}/lib/perl5/site_perl:${perlPackages.DBFile}/lib/perl5/site_perl:${perlPackages.DateManip}/lib/perl5/site_perl:${perlPackages.HTMLTemplate}/lib/perl5/site_perl:${perlPackages.FileCopyRecursive}/lib/perl5/site_perl:${perlPackages.FCGI}/lib/perl5/site_perl:${perlPackages.NetSNMP}/lib/perl5/site_perl:${perlPackages.NetServer}/lib/perl5/site_perl:${perlPackages.ListMoreUtils}/lib/perl5/site_perl:${perlPackages.TimeHiRes}/lib/perl5/site_perl:${rrdtool}/lib/perl:${perlPackages.DBDPg}/lib/perl5/site_perl:${perlPackages.LWPUserAgent}/lib/perl5/site_perl"
|
||||
--set PERL5LIB "$out/lib/perl5/site_perl:${with perlPackages; stdenv.lib.makePerlPath [
|
||||
Log4Perl IOSocketInet6 Socket6 URI DBFile DateManip
|
||||
HTMLTemplate FileCopyRecursive FCGI NetSNMP NetServer
|
||||
ListMoreUtils TimeHiRes DBDPg LWPUserAgent
|
||||
]}"
|
||||
done
|
||||
'';
|
||||
|
||||
|
|
Loading…
Reference in a new issue