From 2221774aa03269b5c3e3e1fbc216fe164587b630 Mon Sep 17 00:00:00 2001 From: Jerome Marchand Date: Tue, 18 May 2021 12:02:20 +0200 Subject: [PATCH] Build bcc from standard sources We provide libbpf package and bcc is already link to it. We don't need to bother with bcc-src-with-submodule.tar.gz source file. Libbpf tools still build and link to the submodule libbpf package, so make sure that libbpf tools are linked to the externel libbpf library. --- .gitignore | 1 + bcc.spec | 13 +++++++------ sources | 2 +- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/.gitignore b/.gitignore index 4ef0033..ab9e546 100644 --- a/.gitignore +++ b/.gitignore @@ -13,3 +13,4 @@ /0001-Add-libbcc-no-libbpf.so-library.patch /0002-Use-libbpf-static-instead-of-libbpf-debugsource-for-.patch /bcc-src-with-submodule.tar.gz +/bcc-0.20.0.tar.gz diff --git a/bcc.spec b/bcc.spec index 7480fdb..9eb4e91 100644 --- a/bcc.spec +++ b/bcc.spec @@ -27,13 +27,11 @@ Name: bcc Version: 0.20.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: BPF Compiler Collection (BCC) License: ASL 2.0 URL: https://github.com/iovisor/bcc -# Upstream now provides a release with the git submodule embedded in it -Source0: %{url}/releases/download/v%{version}/%{name}-src-with-submodule.tar.gz -#Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz +Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz # Arches will be included as upstream support is added and dependencies are # satisfied in the respective arches @@ -129,7 +127,7 @@ Command line libbpf tools for BPF Compiler Collection (BCC) %endif %prep -%autosetup -p1 -n %{name} +%autosetup -p1 %build @@ -147,7 +145,7 @@ Command line libbpf tools for BPF Compiler Collection (BCC) # take them. %if %{with libbpf_tools} pushd libbpf-tools; -make BPFTOOL=bpftool +make BPFTOOL=bpftool LIBBPF_OBJ=%{_libdir}/libbpf.a make DESTDIR=./tmp-install prefix= install (cd tmp-install/bin; for file in *; do mv $file bpf-$file; done;) popd @@ -226,6 +224,9 @@ install libbpf-tools/tmp-install/bin/* %{buildroot}/%{_sbindir} %endif %changelog +* Tue May 18 2021 Jerome Marchand - 0.20.0-2 +- Build bcc from standard sources + * Mon May 17 2021 Rafael dos Santos - 0.20.0-1 - Rebase to latest upstream (#1957727) diff --git a/sources b/sources index 1d9ad9f..3c845c8 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (bcc-src-with-submodule.tar.gz) = 60ab3e7e11015878895d009afb2290d1e677e3c7bc04f493eb586136af190d7c0930757b34e721822eaf6700ecc17edeb30a4b04ea29c4a26cb885164060030a +SHA512 (bcc-0.20.0.tar.gz) = fa7c50a4fc64846ad798b6652101aa414cda53d08779cf48bd505191189cb23da2838f7511e700d59e086d35216f4e3bc9867b614738061630984dff3c4576dc