summaryrefslogtreecommitdiff
path: root/community/go/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'community/go/PKGBUILD')
-rw-r--r--community/go/PKGBUILD19
1 files changed, 17 insertions, 2 deletions
diff --git a/community/go/PKGBUILD b/community/go/PKGBUILD
index d28d6699..4fa88c30 100644
--- a/community/go/PKGBUILD
+++ b/community/go/PKGBUILD
@@ -3,7 +3,7 @@ eval "$(
sed '
/install\( .*\)\? -race /d
'
- declare -f package_go-pie | \
+ declare -f package_go-pie package | \
sed '
s,\(/linux_\)amd64\([_/]\),\1386\2,g
'
@@ -12,6 +12,21 @@ eval "$(
eval "$(
declare -f build check _package \
| sed '
- s/\(export GOARCH=\)amd64/\1386 GO386=387/
+ s/\(export GOARCH=\)amd64/\1386 /
'
)"
+
+# 1.16 dropped non-SSE2 floating point operations, so we must
+# use software floating points (see https://github.com/golang/go/issues/40255)
+if [ "$CARCH" = 'i686' -o "$CARCH" = 'i486' ]; then
+ eval "$(
+ declare -f build \
+ | sed '
+ 2 a export GO386='softfloat'
+ '
+ declare -f check \
+ | sed '
+ 2 a export GO386='softfloat'
+ '
+ )"
+fi