From 8c5c35b5f3e024c8e7e2d78def6fe7118a9db9fcc4ac3da253c8126254060a2a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Rostecki?= Date: Fri, 11 Mar 2022 13:42:38 +0000 Subject: [PATCH 1/2] Accepting request 960937 from home:jeff_mahoney:branches:devel:libraries:c_c++ - Enable building and packaging of static library. Explicitly enable fat LTO objects. Enabling fat LTO to get successful builds on ppc64. Now removed commented out removal of rm command. OBS-URL: https://build.opensuse.org/request/show/960937 OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/libbpf?expand=0&rev=16 --- libbpf.changes | 6 ++++++ libbpf.spec | 14 +++++++++++++- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/libbpf.changes b/libbpf.changes index 2757210..e6026b8 100644 --- a/libbpf.changes +++ b/libbpf.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Mar 10 18:28:17 UTC 2022 - Jeff Mahoney + +- Enable building and packaging of static library. + Explicitly enable fat LTO objects. + ------------------------------------------------------------------- Fri Mar 4 10:18:54 UTC 2022 - Jan Engelhardt diff --git a/libbpf.spec b/libbpf.spec index 8ba440f..8b097bb 100644 --- a/libbpf.spec +++ b/libbpf.spec @@ -48,17 +48,26 @@ Requires: linux-glibc-devel >= 5.16 %description devel libbpf is a C library which provides API for managing eBPF programs and maps. +%package devel-static +Summary: Static library for libbpf +Requires: %{libname} = %{version} +Requires: %{name}-devel = %{version} +Requires: linux-glibc-devel >= 5.16 + +%description devel-static +libbpf is a C library which provides API for managing eBPF programs and maps. + %prep %autosetup %build +%global _lto_cflags %{_lto_cflags} -ffat-lto-objects cd src %make_build V=1 CFLAGS="%{optflags}" %install cd src %make_install V=1 -rm -f %{buildroot}%{_libdir}/%{name}.a %post -n %{libname} -p /sbin/ldconfig %postun -n %{libname} -p /sbin/ldconfig @@ -73,4 +82,7 @@ rm -f %{buildroot}%{_libdir}/%{name}.a %{_libdir}/%{name}.so %{_libdir}/pkgconfig/%{name}.pc +%files devel-static +%{_libdir}/%{name}.a + %changelog From d1d6e9e7e9e618f1daff598f23e8562443113edf0d05644619beda4119bb7b93 Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Sat, 12 Mar 2022 10:14:07 +0000 Subject: [PATCH 2/2] Accepting request 959865 from home:jengelh:branches:devel:libraries:c_c++ - Python is not used during build; remove it and help break a cycle. OBS-URL: https://build.opensuse.org/request/show/959865 OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/libbpf?expand=0&rev=17 --- libbpf.changes | 6 ++++++ libbpf.spec | 1 - 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/libbpf.changes b/libbpf.changes index e6026b8..736db50 100644 --- a/libbpf.changes +++ b/libbpf.changes @@ -4,6 +4,12 @@ Thu Mar 10 18:28:17 UTC 2022 - Jeff Mahoney - Enable building and packaging of static library. Explicitly enable fat LTO objects. +------------------------------------------------------------------- +Mon Mar 7 11:52:14 UTC 2022 - Jan Engelhardt + +- Python is not used during build; remove it and help break + a cycle. + ------------------------------------------------------------------- Fri Mar 4 10:18:54 UTC 2022 - Jan Engelhardt diff --git a/libbpf.spec b/libbpf.spec index 8b097bb..895059d 100644 --- a/libbpf.spec +++ b/libbpf.spec @@ -28,7 +28,6 @@ Source: https://github.com/libbpf/libbpf/archive/v%{version}.tar.gz#/%{n Source99: baselibs.conf BuildRequires: libelf-devel BuildRequires: linux-glibc-devel >= 4.5 -BuildRequires: python3 BuildRequires: zlib-devel %description