[pkg-golang-devel] Bug#807294: golang-go: contains some but not all race-enabled packages

Michael Hudson-Doyle michael.hudson at canonical.com
Wed Feb 3 08:18:13 UTC 2016


On 3 February 2016 at 19:02, Tianon Gravi <admwiggin at gmail.com> wrote:
>> + # On linux/amd64 run.bash installs some race enabled standard library
>> + # packages. Delete them again to avoid accidentally including them in
>> + # the package.
>> + rm -rf "$(GOROOT)/pkg/linux_amd64_race/"
>
> This seems like the most correct solution to me, but I'm a little
> confused about why we're hard-coding "linux_amd64" here -- shouldn't
> this be "$(GOOS)_$(GOARCH)" so that it's whatever architecture we
> build on?  Or perhaps "$(GOROOT)"/pkg/*_race/ ?

It's because the race detector is only supported on amd64 (and I
alternate between forgetting about and not caring about
Debian/kFreeBSD, I guess). GOOS and GOARCH are not defined in
debian/rules any more, but I guess we could shell out to go tool dist
env like the invocation of run.bash does. I tried to use the wildcard
at first but it's annoying because make is not shell. Attaching a new,
slightly cleaner, patch.

Cheers,
mwh
-------------- next part --------------
A non-text attachment was scrubbed...
Name: delete-race-pkgs.patch
Type: text/x-patch
Size: 622 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-golang-devel/attachments/20160203/5faf0bb2/attachment.bin>


More information about the pkg-golang-devel mailing list