From 38bc86ac6c2fa8febcfa99b427e84ed92c05838f Mon Sep 17 00:00:00 2001 From: Austin Seipp Date: Tue, 20 Feb 2018 09:11:12 -0600 Subject: systemtap: add pyparsing deps for 'dtrace' script Otherwise, if it fails, it fails with a very bad error about not being able to import ParseException. Signed-off-by: Austin Seipp --- pkgs/development/tools/profiling/systemtap/default.nix | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'pkgs/development/tools/profiling') diff --git a/pkgs/development/tools/profiling/systemtap/default.nix b/pkgs/development/tools/profiling/systemtap/default.nix index b397f02665bc..7b313f301413 100644 --- a/pkgs/development/tools/profiling/systemtap/default.nix +++ b/pkgs/development/tools/profiling/systemtap/default.nix @@ -1,5 +1,5 @@ { fetchgit, pkgconfig, gettext, runCommand, makeWrapper -, elfutils, kernel, gnumake, python2, pythonPackages +, elfutils, kernel, gnumake, python2, python2Packages }: let @@ -17,7 +17,7 @@ let name = "systemtap-${version}"; src = fetchgit { inherit url rev sha256; }; nativeBuildInputs = [ pkgconfig ]; - buildInputs = [ elfutils gettext python2 pythonPackages.setuptools ]; + buildInputs = [ elfutils gettext python2 python2Packages.setuptools ]; # FIXME: Workaround for bug in kbuild, where quoted -I"/foo" flags would get mangled in out-of-tree kbuild dirs postPatch = '' substituteInPlace buildrun.cxx --replace \ @@ -39,6 +39,8 @@ let done ''; + pypkgs = with python2Packages; makePythonPath [ pyparsing ]; + in runCommand "systemtap-${kernel.version}-${version}" { inherit stapBuild kernelBuildDir; buildInputs = [ makeWrapper ]; @@ -54,8 +56,10 @@ in runCommand "systemtap-${kernel.version}-${version}" { for bin in $stapBuild/bin/*; do # hello emacs */ ln -s $bin $out/bin done - rm $out/bin/stap + rm $out/bin/stap $out/bin/dtrace makeWrapper $stapBuild/bin/stap $out/bin/stap \ --add-flags "-r $kernelBuildDir" \ --prefix PATH : ${lib.makeBinPath [ stdenv.cc.cc stdenv.cc.bintools elfutils gnumake ]} + makeWrapper $stapBuild/bin/dtrace $out/bin/dtrace \ + --prefix PYTHONPATH : ${pypkgs} '' -- cgit 1.4.1