Bug 2079761

Summary: podman fails to build with golang-1.18
Product: Red Hat Enterprise Linux 8 Reporter: Jindrich Novy <jnovy>
Component: podmanAssignee: Jindrich Novy <jnovy>
Status: CLOSED ERRATA QA Contact: Joy Pu <ypu>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 8.7CC: bbaude, dwalsh, jligon, jnovy, lsm5, mheon, pthomas, tsweeney, umohnani, vrothber, ypu
Target Milestone: rcKeywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: podman-4.1.0-2.el8 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-11-08 09:15:45 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jindrich Novy 2022-04-28 08:08:46 UTC
Description of problem:
+ GO111MODULE=off
+ go build -buildmode pie -compiler gc '-tags=rpm_crashtraceback remote seccomp btrfs_noversion exclude_graphdriver_devicemapper exclude_graphdriver_btrfs libdm_no_deferred_remove selinux systemd libsubid' -ldflags ' -linkmode=external -compressdwarf=false -B 0x120bcfebae6f11029aff2c514eb87a4fd0e6731a -extldflags '\''-Wl,-z,relro  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld'\''' -a -v -o bin/gvproxy github.com/containers/gvisor-tap-vsock/cmd/gvproxy
package github.com/containers/gvisor-tap-vsock/cmd/gvproxy
	imports github.com/containers/gvisor-tap-vsock/pkg/virtualnetwork
	imports github.com/containers/gvisor-tap-vsock/pkg/services/dhcp
	imports github.com/containers/gvisor-tap-vsock/pkg/tap
	imports gvisor.dev/gvisor/pkg/tcpip
	imports gvisor.dev/gvisor/pkg/state
	imports gvisor.dev/gvisor/pkg/state/wire
	imports gvisor.dev/gvisor/pkg/gohacks: build constraints exclude all Go files in /builddir/build/BUILD/podman-62534053086fdeba7b93117e7c4dc6e797835a3e/gvisor-tap-vsock-0.1.0/_build/src/github.com/containers/gvisor-tap-vsock/vendor/gvisor.dev/gvisor/pkg/gohacks
error: Bad exit status from /var/tmp/rpm-tmp.TjfgxM (%build)
    Bad exit status from /var/tmp/rpm-tmp.TjfgxM (%build)
RPM build errors:
Child return code was: 1

It compiles fine with 1.16.5 or 1.17.x. Maybe a gvisor update is required to make it pass?

Comment 1 Jindrich Novy 2022-04-28 08:10:16 UTC
Valentin, I'd assign this one to you as we discussed this previously, if you don't mind.

Comment 2 Valentin Rothberg 2022-04-28 08:52:52 UTC
Jindrich, isn't it a golang issue?

Which version of Podman?

Comment 3 Jindrich Novy 2022-04-28 09:02:39 UTC
It's the latest released podman-4.0.3: https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=44922614

I filed a separate bug #2078777 against golang itself. The purpose of this bug is if this couldn't be worked around by e.g. gvisor version update.

Comment 4 Valentin Rothberg 2022-04-28 09:07:45 UTC
Thanks, Jindrich!

I cannot reproduce with Go 1.18 on Fedora 36 but I am giving it a shot on 8.7.

Comment 5 Valentin Rothberg 2022-04-28 09:36:20 UTC
I setup a RHEL 8.7 VM and tried to reproduce manually with golang-1.18.0-2.module+el8.7.0+14880+f5e30240.src.rpm.

Unfortunately, it compiles just fine.  I do not know why the package build fails.

Comment 6 Tom Sweeney 2022-04-28 19:42:50 UTC
I think Brent has been chasing/fixed this one.  Assigning to @bbaude

Comment 10 Jindrich Novy 2022-05-09 06:48:14 UTC
Still the same error in podman-4.1.0: https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=45157418

Comment 11 Jindrich Novy 2022-05-11 08:20:55 UTC
*** Bug 2078777 has been marked as a duplicate of this bug. ***

Comment 12 Jindrich Novy 2022-05-11 08:21:51 UTC
Just updated gvisor-tap-vsock to 0.2.0 to fix compilation with golang 1.18

Comment 13 Jindrich Novy 2022-05-11 08:23:12 UTC
Can we get qa ack please?

Comment 14 Joy Pu 2022-05-12 16:37:14 UTC
Checked with the build log of podman-4.1.0-2.module+el8.7.0+15223+3987d347 and it is already compiled with golang 1.18 so set the Tested flag.
DEBUG util.py:636:   golang                             x86_64  1.18.0-2.module+el8.7.0+14880+f5e30240 build  694 k

Comment 17 Joy Pu 2022-05-19 05:35:35 UTC
Checked the build log of podman-4.1.0-3.module+el8.7.0+15271+4011683a.x86_64, all arch is compiled with 1.18.0-2.module+el8.7.0+14880+f5e30240, so set it to verified.

Comment 19 errata-xmlrpc 2022-11-08 09:15:45 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: container-tools:rhel8 security, bug fix, and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2022:7457