Backport golang 1.16 to Bionic
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
golang-1.16 (Ubuntu) |
Invalid
|
Undecided
|
Unassigned | ||
Bionic |
Fix Released
|
Undecided
|
Matthieu Clemenceau |
Bug Description
[Impact]
To enable packages that are backported wholesale to all releases of Ubuntu (i.e. runc and docker.io) to stop depending on what is now a fairly ancient version of Go (some of them require at least Go 1.16), we are going to upload 1.16 to bionic (this version is in focal already). This is an unusual "SRU" but the plan has been concocted with the approval of the Ubuntu security team (who I will ask to comment here to confirm their acceptance of the plan).
[Test Plan]
A smoke test, like this:
$ apt install golang-1.16-go
$ PATH=/usr/
$ go version
< check it's 1.16 >
$ cat > trivial.go
package main
func main() {}
$ go run trivial.go
$ cat > trivialcgo.go
package main
import "C"
func main() {}
$ go run trivialcgo.go
Then we should verify that runc/1.
+export GO111MODULE := off
+export GOCACHE := $(CURDIR)/.cache
Also add a new changelog entry with something like this:
$ dch -v 1.1.0-0ubuntu1~
and upload that to a PPA that has bionic-proposed enabled and check it builds on all architectures.
[Where problems could occur]
It's a new package so should not impact any existing behavior. I'm not at all proposing to update the default version of Go in a stable release. FWIW golang-1.16 is already co-installable with other golang versions in other releases.
Changed in golang-1.16 (Ubuntu): | |
status: | New → Invalid |
description: | updated |
description: | updated |
Changed in golang-1.16 (Ubuntu Bionic): | |
status: | New → In Progress |
assignee: | nobody → Lucas Kanashiro (lucaskanashiro) |
description: | updated |
golang-1.16-go from Focal has Breaks: dh-golang (<< 1.43~) which is unsatisfiable in Bionic, where we have dh-golang/1.34.2. This made runc version 1.1.0-0ubuntu1 FTBFS with golang 1.16.
According to the discussion on the commit message (https:/ /salsa. debian. org/go- team/compiler/ golang/ -/commit/ daea28cbf7eb639 7e7), version 1.40 of dh-golang is actually needed. After checking the diff between version 1.34.2 and 1.40, I noticed that the main changes needed are:
* Set GO111MODULE to off
* Set GOCACHE directory
After applying those changes directly to runc, it built with golang 1.16 and dh-golang 1.34.2. This might help others trying to make some package build with golang 1.16 in bionic once it lands.
So the required changes to backport golang- 1.16/1. 16.2-0ubuntu1~ 20.04 from Focal to Bionic are:
* Downgrade debhelper compatibility level to 11. Compat 12 is not available in Bionic.
* Remove Breaks: dh-golang (<< 1.43~) from d/control{,.in}.