Fix build for noarch and x86_64

i9-ispras-fuzzing-kmsan
ebasov 2 weeks ago
parent 20c06309a8
commit 2ff7dcf29d
Signed by: ebasov
GPG Key ID: 23356EDA24E5499D

@ -1295,8 +1295,13 @@ popd > /dev/null
%endif %endif
%if %{with_bpftool} %if %{with_bpftool}
%ifarch aarch64
%global bpftool_make \ %global bpftool_make \
%{__make} -s EXTRA_CFLAGS="${RPM_OPT_FLAGS}" EXTRA_LDFLAGS="%{__global_ldflags}" DESTDIR=$RPM_BUILD_ROOT VMLINUX_H="${RPM_VMLINUX_H}" %{__make} -s EXTRA_CFLAGS="${RPM_OPT_FLAGS}" EXTRA_LDFLAGS="%{__global_ldflags}" DESTDIR=$RPM_BUILD_ROOT VMLINUX_H="${RPM_VMLINUX_H}"
%else
%global bpftool_make \
%{__make} -s EXTRA_CFLAGS="-O2 -Wall -Wextra -Werror" EXTRA_LDFLAGS="%{__global_ldflags}" DESTDIR=$RPM_BUILD_ROOT VMLINUX_H="${RPM_VMLINUX_H}"
%endif
pushd tools/bpf/bpftool > /dev/null pushd tools/bpf/bpftool > /dev/null
%{bpftool_make} %{bpftool_make}
@ -1465,6 +1470,7 @@ popd > /dev/null
### ###
### Scripts. ### Scripts.
### ###
%ifarch x86_64 aarch64
%if %{with_tools} %if %{with_tools}
%post -n %{name}-tools-libs %post -n %{name}-tools-libs
/sbin/ldconfig /sbin/ldconfig
@ -1472,6 +1478,7 @@ popd > /dev/null
%postun -n %{name}-tools-libs %postun -n %{name}-tools-libs
/sbin/ldconfig /sbin/ldconfig
%endif %endif
%endif
# #
# This macro defines a %%post script for a kernel-lt*-devel package. # This macro defines a %%post script for a kernel-lt*-devel package.
@ -1612,6 +1619,7 @@ fi
%{python3_sitearch}/* %{python3_sitearch}/*
%endif %endif
%ifarch x86_64 aarch64
%if %{with_tools} %if %{with_tools}
%files -n %{name}-tools -f cpupower.lang %files -n %{name}-tools -f cpupower.lang
%{_bindir}/cpupower %{_bindir}/cpupower
@ -1652,6 +1660,7 @@ fi
%files -n %{name}-tools-libs-devel %files -n %{name}-tools-libs-devel
%{_libdir}/libcpupower.so %{_libdir}/libcpupower.so
%endif %endif
%endif
%if %{with_bpftool} %if %{with_bpftool}
%files -n bpftool %files -n bpftool

Loading…
Cancel
Save