Merge pull request #118121 from martinetd/bcc-devendor-libbpf

bcc: devendor libbpf
This commit is contained in:
Jörg Thalheim 2021-04-20 14:19:39 +01:00 committed by GitHub
commit 3e8217986f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,7 +1,7 @@
{ lib, stdenv, fetchurl, fetchpatch { lib, stdenv, fetchFromGitHub
, makeWrapper, cmake, llvmPackages, kernel , makeWrapper, cmake, llvmPackages, kernel
, flex, bison, elfutils, python, luajit, netperf, iperf, libelf , flex, bison, elfutils, python, luajit, netperf, iperf, libelf
, systemtap, bash , systemtap, bash, libbpf
}: }:
python.pkgs.buildPythonApplication rec { python.pkgs.buildPythonApplication rec {
@ -10,9 +10,11 @@ python.pkgs.buildPythonApplication rec {
disabled = !stdenv.isLinux; disabled = !stdenv.isLinux;
src = fetchurl { src = fetchFromGitHub {
url = "https://github.com/iovisor/bcc/releases/download/v${version}/bcc-src-with-submodule.tar.gz"; owner = "iovisor";
sha256 = "sha256-TEH8Gmp+8ghLQ8UsGy5hBCMLqfMeApWEFr8THYSOdOQ="; repo = "bcc";
rev = "v${version}";
sha256 = "sha256:0k807vzznlb2icczw64ph6q28605kvghya2kd4h3c7jmap6gq1qg";
}; };
format = "other"; format = "other";
@ -20,6 +22,7 @@ python.pkgs.buildPythonApplication rec {
llvm clang-unwrapped kernel llvm clang-unwrapped kernel
elfutils luajit netperf iperf elfutils luajit netperf iperf
systemtap.stapBuild flex bash systemtap.stapBuild flex bash
libbpf
]; ];
patches = [ patches = [
@ -38,6 +41,7 @@ python.pkgs.buildPythonApplication rec {
"-DREVISION=${version}" "-DREVISION=${version}"
"-DENABLE_USDT=ON" "-DENABLE_USDT=ON"
"-DENABLE_CPP_API=ON" "-DENABLE_CPP_API=ON"
"-DCMAKE_USE_LIBBPF_PACKAGE=ON"
]; ];
postPatch = '' postPatch = ''