Bug 1912666 - Build failure when depending on golang-github-aws-sdk on 32 bit architectures
Summary: Build failure when depending on golang-github-aws-sdk on 32 bit architectures
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: golang-github-aws-sdk
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Robert-André Mauchin 🐧
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-01-05 05:53 UTC by Davide Cavalca
Modified: 2021-01-05 21:51 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-01-05 21:51:22 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Davide Cavalca 2021-01-05 05:53:18 UTC
While packaging golang-github-facebookincubator-go2chef, which depends on github(github.com/aws/aws-sdk-go/service/s3/s3manager) among other things, I've noticed the build reliably fails on 32 bit architectures with:

cd /usr/share/gocode/src/github.com/aws/aws-sdk-go/service/s3/s3manager
/usr/lib/golang/pkg/tool/linux_386/compile -o $WORK/b208/_pkg_.a -trimpath "$WORK/b208=>" -shared -p github.com/aws/aws-sdk-go/service/s3/s3manager -complete -installsuffix shared -buildid MqWIQnR-z1xFDxhJy1xn/MqWIQnR-z1xFDxhJy1xn -goversion go1.15.6 -D "" -importcfg $WORK/b208/importcfg -pack ./batch.go ./bucket_region.go ./buffered_read_seeker.go ./default_read_seeker_write_to.go ./default_writer_read_from.go ./doc.go ./download.go ./pool.go ./read_seeker_write_to.go ./upload.go ./upload_input.go ./writer_read_from.go
/usr/lib/golang/pkg/tool/linux_386/buildid -w $WORK/b208/_pkg_.a # internal
cp $WORK/b208/_pkg_.a /builddir/.cache/go-build/74/7417daa55ae11f355d381a666c1bbf4cec33f58dd8abec6137010f3f69eb5db3-d # internal
error: Bad exit status from /var/tmp/rpm-tmp.LwbfXg (%build)

You can see the full log in https://koji.fedoraproject.org/koji/taskinfo?taskID=58954995

It also looks like there's some preexisting issue as the tests have been disabled on 32 bit arches in https://src.fedoraproject.org/rpms/golang-github-aws-sdk/c/e8c7914aaec79e86d823c43ed7b37f9c01046fed but I couldn't find any other context on that.

Comment 1 Davide Cavalca 2021-01-05 06:05:36 UTC
You can find the specfile and src.rpm I used for this in #1912668, I've added an ExcludeArch to unblock things for now but you can just remove it to repro the issue.

Comment 2 Robert-André Mauchin 🐧 2021-01-05 12:17:30 UTC
Problem comes from your package:

# github.com/facebookincubator/go2chef
_build/src/github.com/facebookincubator/go2chef/multilogger.go:26:3: constant 9223372036854775807 overflows int
github.com/jmespath/go-jmespath


Tip: search "# " + import path to get to the actual error.


Try patching it with

// NewMultiLogger returns a MultiLogger with the provided list
// of loggers set up to receive logs.
func NewMultiLogger(loggers []Logger) *MultiLogger {
	return &MultiLogger{
		loggers: loggers,
		debug:   int64(math.MaxInt64),
		level:   LogLevelDebug,
	}
}

Comment 3 Davide Cavalca 2021-01-05 15:44:01 UTC
Thanks! I've filed https://github.com/facebookincubator/go2chef/issues/43 to get this sorted out upstream.


Note You need to log in before you can comment on or make changes to this bug.