linuxPackages.perf: fix tips.txt lookup, few extra deps

Signed-off-by: Austin Seipp <aseipp@pobox.com>
This commit is contained in:
Austin Seipp 2018-02-19 23:17:02 -06:00
parent 825ff649b5
commit f0fe7bae99

View file

@ -1,7 +1,8 @@
{ lib, stdenv, kernel, elfutils, python, perl, newt, slang, asciidoc, xmlto, makeWrapper
, docbook_xsl, docbook_xml_dtd_45, libxslt, flex, bison, pkgconfig, libunwind, binutils
, libiberty, libaudit, libbfd
, zlib, withGtk ? false, gtk2 ? null }:
, libiberty, libaudit, libbfd, openssl, systemtap, numactl
, zlib, withGtk ? false, gtk2 ? null
}:
with lib;
@ -17,14 +18,16 @@ stdenv.mkDerivation {
cd tools/perf
sed -i s,/usr/include/elfutils,$elfutils/include/elfutils, Makefile
[ -f bash_completion ] && sed -i 's,^have perf,_have perf,' bash_completion
export makeFlags="DESTDIR=$out $makeFlags"
export makeFlags="DESTDIR=$out WERROR=0 $makeFlags"
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -DTIPDIR=\"$out/share/doc/perf-tip\""
'';
# perf refers both to newt and slang
nativeBuildInputs = [ asciidoc xmlto docbook_xsl docbook_xml_dtd_45 libxslt
flex bison libiberty libaudit makeWrapper pkgconfig python perl ];
buildInputs = [ elfutils newt slang libunwind libbfd zlib ] ++
stdenv.lib.optional withGtk gtk2;
buildInputs =
[ elfutils newt slang libunwind libbfd zlib openssl systemtap.stapBuild numactl
] ++ stdenv.lib.optional withGtk gtk2;
# Note: we don't add elfutils to buildInputs, since it provides a
# bad `ld' and other stuff.