[12473] | 1 | %global githubname libbpf |
---|
| 2 | %global githubver 0.0.9 |
---|
| 3 | %global githubfull %{githubname}-%{githubver} |
---|
| 4 | |
---|
| 5 | Name: %{githubname} |
---|
| 6 | Version: %{githubver} |
---|
| 7 | Release: 1%{?_dist_release} |
---|
| 8 | Summary: Libbpf library |
---|
| 9 | Group: system |
---|
| 10 | Vendor: Project Vine |
---|
| 11 | Distribution: Vine Linux |
---|
| 12 | |
---|
| 13 | License: LGPLv2 or BSD |
---|
| 14 | URL: https://github.com/%{githubname}/%{githubname} |
---|
| 15 | Source: https://github.com/%{githubname}/%{githubname}/archive/v%{githubver}.tar.gz |
---|
| 16 | BuildRequires: gcc elfutils-libelf-devel elfutils-devel |
---|
| 17 | |
---|
| 18 | %description |
---|
| 19 | A mirror of bpf-next linux tree bpf-next/tools/lib/bpf directory plus its |
---|
| 20 | supporting header files. The version of the package reflects the version of |
---|
| 21 | ABI. |
---|
| 22 | |
---|
| 23 | |
---|
| 24 | %package devel |
---|
| 25 | Summary: Development files for %{name} |
---|
| 26 | Requires: %{name} = %{version}-%{release} |
---|
| 27 | Group: programming |
---|
| 28 | |
---|
| 29 | %description devel |
---|
| 30 | The %{name}-devel package contains libraries header files for |
---|
| 31 | developing applications that use %{name} |
---|
| 32 | |
---|
| 33 | |
---|
| 34 | %package static |
---|
| 35 | Summary: Static library for libbpf development |
---|
| 36 | Group: programming |
---|
| 37 | Requires: %{name}-devel = %{version}-%{release} |
---|
| 38 | |
---|
| 39 | %description static |
---|
| 40 | The %{name}-static package contains static library for |
---|
| 41 | developing applications that use %{name} |
---|
| 42 | |
---|
| 43 | |
---|
| 44 | %global make_flags DESTDIR=%{buildroot} OBJDIR=%{_builddir} CFLAGS="%{optflags}" LDFLAGS="%{?build_ldflags} -Wl,--no-as-needed" LIBDIR=/%{_libdir} NO_PKG_CONFIG=1 |
---|
| 45 | |
---|
| 46 | |
---|
| 47 | %prep |
---|
| 48 | %autosetup -n %{githubfull} |
---|
| 49 | |
---|
| 50 | |
---|
| 51 | %build |
---|
| 52 | %make_build -C ./src %{make_flags} |
---|
| 53 | |
---|
| 54 | |
---|
| 55 | %install |
---|
| 56 | %make_install -C ./src %{make_flags} |
---|
| 57 | |
---|
| 58 | |
---|
| 59 | %post -p /sbin/ldconfig |
---|
| 60 | %postun -p /sbin/ldconfig |
---|
| 61 | |
---|
| 62 | |
---|
| 63 | %files |
---|
| 64 | %{_libdir}/libbpf.so.%{version} |
---|
| 65 | %{_libdir}/libbpf.so.0 |
---|
| 66 | |
---|
| 67 | %files devel |
---|
| 68 | %{_libdir}/libbpf.so |
---|
| 69 | %{_includedir}/bpf/ |
---|
| 70 | %{_libdir}/pkgconfig/libbpf.pc |
---|
| 71 | |
---|
| 72 | %files static |
---|
| 73 | %{_libdir}/libbpf.a |
---|
| 74 | |
---|
| 75 | |
---|
| 76 | %changelog |
---|
| 77 | * Mon Aug 17 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 0.0.9-1 |
---|
| 78 | - new upstream release. |
---|
| 79 | |
---|
| 80 | * Wed Oct 30 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 0.0.5-2 |
---|
| 81 | - initial build for Vine Linux. |
---|
| 82 | |
---|
| 83 | * Thu Oct 03 2019 Jiri Olsa <jolsa@redhat.com> - 0.0.5-1 |
---|
| 84 | - release 0.0.5 |
---|
| 85 | |
---|
| 86 | * Wed Sep 25 2019 Jiri Olsa <jolsa@redhat.com> - 0.0.3-2 |
---|
| 87 | - Fix libelf linking (BZ#1755317) |
---|
| 88 | |
---|
| 89 | * Fri Sep 13 2019 Jiri Olsa <jolsa@redhat.com> - 0.0.3-1 |
---|
| 90 | - Initial release |
---|