[Bug 221297] lang/go: Fix arm build

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Fri Apr 12 16:00:28 UTC 2019


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221297

Dmitri Goutnik <dg at syrec.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dg at syrec.org
 Attachment #203615|                            |maintainer-approval?
              Flags|                            |

--- Comment #21 from Dmitri Goutnik <dg at syrec.org> ---
Created attachment 203615
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=203615&action=edit
Updated patch for the current lang/go

- Set CGO_ENABLED=1 unconditionally. CGO_ENABLED already defaults to 1 on all
supported archs except ARM [1], so effectively this change just enables it on
ARM.

- Set GOARM from ARCH for ARM archs. The appropriate GOARM value is supposed to
be chosen automatically when compiling on target hardware but on FreeBSD, it is
always set to "5" due to the code [2] from a 4 years old commit. I don't know
if "FreeBSD has broken VFP support." is still true, maybe a FreeBSD/ARM expert
can chime in on that.

QA:

Builds fine in poudriere on 12a, 12i and 11a but otherwise untested - lang/go
doesn't currently build in poudriere/qemu on amd64 hosts (comment #14) and
qemu-sbruno is marked as BROKEN on i386. 

[1] https://github.com/golang/go/blob/master/src/cmd/dist/build.go#L1486
[2] https://github.com/golang/go/blob/master/src/cmd/dist/util.go#L400

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-ports-bugs mailing list