From: Denys Vlasenko <dvlasenk(a)redhat.com>
kernel.spec: remove "RPM_VMLINUX_H=$DevelDir/vmlinux.h" code chunk in %install
Remove this code block in %install:
if [ -f $DevelDir/vmlinux.h ]; then
RPM_VMLINUX_H=$DevelDir/vmlinux.h
fi
It was added by commit b4cac22848f6cfdbd7e52bf5fd0a2e6381f7b552
kernel.spec: Add support to use vmlinux.h
The commit added two copies of it. The second instance, in %install,
does not actually work: $DevelDir is not set, so (unless your root
indeed has a /vmlinux.h file) RPM_VMLINUX_H is not set, but it
would not be used in %install anyway.
Signed-off-by: Denys Vlasenko <dvlasenk(a)redhat.com>
diff --git a/redhat/kernel.spec.template b/redhat/kernel.spec.template
index blahblah..blahblah 100644
--- a/redhat/kernel.spec.template
+++ b/redhat/kernel.spec.template
@@ -2811,10 +2811,6 @@ rm -f %{buildroot}%{_bindir}/timerlat
popd
%endif
-if [ -f $DevelDir/vmlinux.h ]; then
- RPM_VMLINUX_H=$DevelDir/vmlinux.h
-fi
-
%if %{with_bpftool}
pushd tools/bpf/bpftool
%{bpftool_make} prefix=%{_prefix} bash_compdir=%{_sysconfdir}/bash_completion.d/
mandir=%{_mandir} install doc-install
--
https://gitlab.com/cki-project/kernel-ark/-/merge_requests/2458