Public bug reported:

== SRU RISC-V 5.8 Focal backport kernel ==

The 5.8 RISC-V kernel has boot issues when compiled with gcc 9. This can
be fixed by building it with gcc-10.

== Fix ==

Use gcc-10, e.g.:

diff --git a/debian.master/control.stub.in b/debian.master/control.stub.in
index 9c1e956092bf..3b920328caff 100644
--- a/debian.master/control.stub.in
+++ b/debian.master/control.stub.in
@@ -68,7 +68,7 @@ Section: devel
 Priority: optional
 Provides: linux-source
 Depends: ${misc:Depends}, binutils, bzip2, coreutils
-Recommends: libc-dev, gcc, make
+Recommends: libc-dev, gcc-10, make
 Suggests: libncurses-dev | ncurses-dev, kernel-package, libqt3-dev
 Description: Linux kernel source for version PKGVER with Ubuntu patches
  This package provides the source code for the Linux kernel version
diff --git a/debian/rules b/debian/rules
index 627ca3cb968f..425d33b35fde 100755
--- a/debian/rules
+++ b/debian/rules
@@ -8,6 +8,7 @@
 #
 
 DEBIAN=$(shell awk -F= '($$1 == "DEBIAN") { print $$2 }' <debian/debian.env)
+gcc=gcc-10
 
 # dpkg-buildpackage passes options that are incomptatible
 # with the kernel build.

== Testing ==

Without the fix, the kernel will panic during boot. With the fix, the
kernel boots fine.

== Where problems could occur ==

Using a different compiler version can always introduce subtle object
code differences and hence potential bugs, however, the same gcc version
is being used to build the groovy variant of the same kernel and we know
that this works fine w/o any observable gcc specific issues.

** Affects: linux (Ubuntu)
     Importance: Critical
     Assignee: Colin Ian King (colin-king)
         Status: In Progress

** Changed in: linux (Ubuntu)
   Importance: Undecided => Critical

** Changed in: linux (Ubuntu)
       Status: New => In Progress

** Changed in: linux (Ubuntu)
     Assignee: (unassigned) => Colin Ian King (colin-king)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1913864

Title:
  Use gcc-10 to build 5.8 riscv backport kernel for focal

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1913864/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to