%endif
%define rel 1
-%define basever 5.15
-%define postver .6
+%define basever 5.18
+%define postver .14
# define this to '-%{basever}' for longterm branch
%define versuffix %{nil}
License: GPL v2
Group: Base/Kernel
Source0: https://www.kernel.org/pub/linux/kernel/v5.x/linux-%{basever}.tar.xz
-# Source0-md5: 071d49ff4e020d58c04f9f3f76d3b594
+# Source0-md5: 58e80452e2d8e1993cd7ec95e697ab5a
%if "%{postver}" != ".0"
Patch0: https://www.kernel.org/pub/linux/kernel/v5.x/patch-%{version}.xz
-# Patch0-md5: a41ce0931f89959fb2457f8a54e5c811
+# Patch0-md5: 05dee8a9a2d04a0cde691b449114177b
%endif
Source1: kernel.sysconfig
Patch2000: kernel-small_fixes.patch
Patch2001: kernel-pwc-uncompress.patch
Patch2003: kernel-regressions.patch
-Patch2004: Revert-ath-add-support-for-special-0x0-regulatory-domain.patch
# for rescuecd
# based on ftp://ftp.leg.uct.ac.za/pub/linux/rip/tmpfs_root-2.6.30.diff.gz
Patch7000: kernel-inittmpfs.patch
# ARM only
-Patch8000: rpi-wm8804.patch
+Patch8000: rpi-sound.patch
Patch8001: kernel-pinebook-pro.patch
Patch8002: atheros-disallow-retrain-nongen1-pcie.patch
URL: https://www.kernel.org/
AutoReqProv: no
BuildRequires: /sbin/depmod
-BuildRequires: bc
-BuildRequires: binutils >= 3:2.18
-BuildRequires: bison
+BuildRequires: bc >= 1.06.95
+BuildRequires: binutils >= 3:2.23
+BuildRequires: bison >= 2.0
%ifarch sparc sparc64
BuildRequires: elftoaout
%endif
BuildRequires: elfutils-devel
-BuildRequires: flex
+BuildRequires: flex >= 2.5.35
BuildRequires: gcc >= 6:7.2.0-6
BuildRequires: gcc-c++
BuildRequires: gcc-plugin-devel
BuildRequires: hostname
BuildRequires: kmod >= %{kmod_ver}
BuildRequires: libstdc++-devel
-BuildRequires: openssl-devel
-BuildRequires: openssl-tools
-BuildRequires: perl-base
+BuildRequires: make >= 1:3.81
+BuildRequires: openssl-devel >= 1.0.0
+BuildRequires: openssl-tools >= 1.0.0
+BuildRequires: perl-base >= 5
BuildRequires: rpm-build >= 4.5-24
BuildRequires: rpmbuild(macros) >= 1.752
BuildRequires: tar >= 1:1.22
BuildRequires: uboot-mkimage
%endif
BuildRequires: xz >= 1:4.999.7
+BuildConflicts: dwarves < 1.16
Requires(post): coreutils
Requires(post): geninitrd >= 12787-6
Requires(post): kmod >= %{kmod_ver}
%patch2000 -p1
%patch2001 -p1
#%patch2003 -p1
-%patch2004 -p1
# Do not remove this, please!
#%%patch50000 -p1
scripts/show_delta \
tools/hv/vmbus_testing \
tools/kvm/kvm_stat/kvm_stat \
- tools/testing/selftests/exec/binfmt_script
+ tools/testing/selftests/exec/binfmt_script.py
find -name '*.pl' -print0 | \
xargs -0 %{__sed} -i -e '1s,/usr/bin/env perl,%{__perl},' \
%ifarch x32
CONFIG_BPF_PRELOAD=n
%endif
+%if %{_ver_ge %(rpm -q --qf='%%{VERSION}' gcc) 12}
+ CONFIG_INIT_STACK_ALL_ZERO=y
+ CONFIG_GCC_PLUGIN_STRUCTLEAK_BYREF_ALL=n
+%else
+ CONFIG_GCC_PLUGIN_STRUCTLEAK_BYREF_ALL=y
+%endif
EOCONFIG
%if %{with rescuecd}
%{__awk} %{?debug:-v dieOnError=1} -v infile=%{objdir}/%{defconfig} -f %{SOURCE8} %{objdir}/.config
+%{__make} \
+ TARGETOBJ=%{targetobj} \
+ %{?with_verbose:V=1} \
+ scripts
+
# build kernel
export DTC_FLAGS=-@
+ICECC_EXTRAFILES="${ICECC_EXTRAFILES:+$ICECC_EXTRAFILES:}$(test -d %{objdir}/scripts/gcc-plugins && find %{objdir}/scripts/gcc-plugins -name '*.so' | paste -s -d :)"
%{__make} \
TARGETOBJ=%{targetobj} \
%{?with_verbose:V=1} \
%install
rm -rf $RPM_BUILD_ROOT
-%{__make} %{MakeOpts} -j1 %{!?with_verbose:-s} modules_install \
+%{__make} %{MakeOpts} %{!?with_verbose:-s} modules_install \
-C %{objdir} \
%{?with_verbose:V=1} \
DEPMOD=%{DepMod} \
ln -sf vmlinuz-%{kernel_release} /boot/vmlinuz
ln -sf System.map-%{kernel_release} /boot/System.map
%ifarch %{arm} aarch64
- mv -f /boot/dtb{,.old} 2> /dev/null
+ test -L /boot/dtb.old && rm /boot/dtb.old
+ test ! -e /boot/dtb.old && mv -f /boot/dtb{,.old} 2> /dev/null
ln -sf dtb-%{kernel_release} /boot/dtb
%endif
%if 0%{?alt_kernel:1}
%{_kernelsrcdir}/arch/x86/ia32/[!M]*
%{_kernelsrcdir}/arch/powerpc/kexec
%{_kernelsrcdir}/arch/powerpc/kvm
+%{_kernelsrcdir}/arch/riscv/kvm
%ifarch ppc ppc64
%exclude %{_kernelsrcdir}/arch/powerpc/lib/crtsavres.*
%endif