@cryptotaxi247 / netdata-1 / commits / ce664af13

RPM: Added elfutils-libelf-devel for build with eBPF (#14552)

Find issue with x86_64 mock build ```bash + /builddir/build/BUILD/netdata-v1.38.1/packaging/bundle-libbpf.sh /builddir/build/BUILD/netdata-v1.38.1 centos8 cp: cannot stat '/builddir/build/BUILD/netdata-v1.38.1/packaging/current_libbpf.checksums': No such file or directory cp: cannot stat '/builddir/build/BUILD/netdata-v1.38.1/packaging/current_libbpf.version': No such file or directory v1.1_netdata.tar.gz: OK make: Entering directory '/builddir/build/BUILD/netdata-v1.38.1/externaldeps/libbpf/libbpf-1.1_netdata/src' Package libelf was not found in the pkg-config search path. Perhaps you should add the directory containing `libelf.pc' to the PKG_CONFIG_PATH environment variable Package 'libelf', required by 'virtual:world', not found MKDIR build//staticobjs CC build//staticobjs/bpf.o CC build//staticobjs/btf.o btf.c:18:10: fatal error: gelf.h: No such file or directory #include <gelf.h> ^~~~~~~~ compilation terminated. make: *** [Makefile:131: build//staticobjs/btf .o] Error 1 make: Leaving directory '/builddir/build/BUILD/netdata-v1.38.1/externaldeps/libbpf/libbpf-1.1_netdata/src' error: Bad exit status from /var/tmp/rpm-tmp.2itZZI (%prep) RPM build errors: bogus date in %changelog: Wed Feb 03 2022 Austin Hemmelgarn <austin@netdata.cloud> 0.0.0-16 Bad exit status from /var/tmp/rpm-tmp.2itZZI (%prep) Child return code was: 1 ``` The conditional BuildDeps fixed this issue

Konstantin Shalygin committed Mar 14, 2023 at 20:09 UTC ce664af13daa5a2ba85f1efa0fe63b0ee615689b
1 file changed +16 -5
netdata.spec.in
+16 -5
@@ -185,9 +185,19 @@ Requires(pre): /usr/sbin/useradd
185 # #####################################################################
186 # Functionality-dependent package dependencies
187 # #####################################################################
188 -# Note: Some or all of the Packages may be found in the EPEL repo,
188 +# Note: Some or all of the Packages may be found in the EPEL repo,
189 # rather than the standard ones
190
191 +# epbf dependencies
192 +%if 0%{?_have_ebpf}
193 +%if 0%{?suse_version}
194 +BuildRequires: libelf-devel
195 +%else
196 +BuildRequires: elfutils-libelf-devel
197 +%endif
198 +%endif
199 +# end - ebpf dependencies
200 +
201 # nfacct plugin dependencies
202 BuildRequires: libmnl-devel
203 %if 0%{?fedora} || 0%{?suse_version} >= 1140
@@ -565,14 +575,16 @@ Requires: netdata = %{version}
575
576 %description plugin-freeipmi
577 The IPMI specification defines a set of interfaces for platform management.
568 -It is implemented by a number vendors for system management. The features of IPMI that most users will be interested in
578 +It is implemented by a number vendors for system management. The features of IPMI that most users will be interested in
579 are sensor monitoring, system event monitoring, power control, and serial-over-LAN (SOL).
580
581 %files plugin-freeipmi
582 %attr(4750,root,netdata) %{_libexecdir}/%{name}/plugins.d/freeipmi.plugin
583
584 %changelog
575 -* Wed Feb 03 2022 Austin Hemmelgarn <austin@netdata.cloud> 0.0.0-16
585 +* Thu Feb 16 2023 Konstantin Shalygin <k0ste@k0ste.ru> 0.0.0-17
586 +- Added eBPF build dependency
587 +* Fri Feb 03 2022 Austin Hemmelgarn <austin@netdata.cloud> 0.0.0-16
588 - Bundle updater script in native packages.
589 * Mon Oct 11 2021 Austin Hemmelgarn <austin@netdata.cloud> 0.0.0-15
590 - Remove support code for legacy ACLK implementation.
@@ -609,9 +621,8 @@ First draft refactor on package dependencies section
621 * Wed Jan 02 2019 Pawel Krupa <pkrupa@redhat.com> - 0.0.0-3
622 - Temporary set version statically
623 - Fix changelog ordering
612 -- Comment-out node.d configuration directory
624 +- Comment-out node.d configuration directory
625 * Wed Jan 02 2019 Pawel Krupa <pkrupa@redhat.com> - 0.0.0-2
626 - Fix permissions for log files
627 * Sun Nov 15 2015 Alon Bar-Lev <alonbl@redhat.com> - 0.0.0-1
628 - Initial add.
617 -