root: wrap python executables
In normal use of ROOT the PYTHONPATH is intended to be set when user sources the thisroot.{,s}sh. We do that in the setupHook. This covers the case when thisroot.sh was not sourced.
This commit is contained in:
parent
c5aacb2350
commit
0b28198f23
@ -1,5 +1,6 @@
|
||||
{ stdenv, fetchurl, cmake, gl2ps, gsl, libX11, libXpm, libXft, libXext
|
||||
, libGLU, libGL, libxml2, lz4, lzma, pcre, pkgconfig, python, xxHash, zlib
|
||||
{ stdenv, fetchurl, makeWrapper, cmake, gl2ps, gsl, libX11, libXpm, libXft
|
||||
, libXext, libGLU, libGL, libxml2, lz4, lzma, pcre, pkgconfig, python, xxHash
|
||||
, zlib
|
||||
, Cocoa, OpenGL, noSplash ? false }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
@ -11,7 +12,7 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "196ghma6g5a7sqz52wyjkgvmh4hj4vqwppm0zwdypy33hgy8anii";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake pkgconfig ];
|
||||
nativeBuildInputs = [ makeWrapper cmake pkgconfig ];
|
||||
buildInputs = [ gl2ps pcre python zlib libxml2 lz4 lzma gsl xxHash ]
|
||||
++ stdenv.lib.optionals (!stdenv.isDarwin) [ libX11 libXpm libXft libXext libGLU libGL ]
|
||||
++ stdenv.lib.optionals (stdenv.isDarwin) [ Cocoa OpenGL ]
|
||||
@ -73,6 +74,13 @@ stdenv.mkDerivation rec {
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
postInstall = ''
|
||||
for prog in rootbrowse rootcp rooteventselector rootls rootmkdir rootmv rootprint rootrm rootslimtree; do
|
||||
wrapProgram "$out/bin/$prog" \
|
||||
--prefix PYTHONPATH : "$out/lib"
|
||||
done
|
||||
'';
|
||||
|
||||
setupHook = ./setup-hook.sh;
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
Loading…
Reference in New Issue
Block a user