aboutsummaryrefslogtreecommitdiff
path: root/src/run.bash
diff options
context:
space:
mode:
Diffstat (limited to 'src/run.bash')
-rwxr-xr-xsrc/run.bash19
1 files changed, 12 insertions, 7 deletions
diff --git a/src/run.bash b/src/run.bash
index 90afaaa4e6..15184fd875 100755
--- a/src/run.bash
+++ b/src/run.bash
@@ -158,13 +158,18 @@ android-arm | dragonfly-386 | dragonfly-amd64 | freebsd-386 | freebsd-amd64 | fr
go test -ldflags '-linkmode=external' ../nocgo || exit 1
go test -ldflags '-linkmode=external -extldflags "-static -pthread"' ../nocgo || exit 1
fi
- if ! $CC -xc -o /dev/null -pie - 2>/dev/null <<<'int main() {}' ; then
- echo "No support for -pie found, skip cgo PIE test."
- else
- go test -ldflags '-linkmode=external -extldflags "-pie"' || exit 1
- go test -ldflags '-linkmode=external -extldflags "-pie"' ../testtls || exit 1
- go test -ldflags '-linkmode=external -extldflags "-pie"' ../nocgo || exit 1
- fi
+ case "$GOHOSTOS-$GOARCH" in
+ freebsd-amd64) ;; # clang -pie fails to link misc/cgo/test
+ *)
+ if ! $CC -xc -o /dev/null -pie - 2>/dev/null <<<'int main() {}' ; then
+ echo "No support for -pie found, skip cgo PIE test."
+ else
+ go test -ldflags '-linkmode=external -extldflags "-pie"' || exit 1
+ go test -ldflags '-linkmode=external -extldflags "-pie"' ../testtls || exit 1
+ go test -ldflags '-linkmode=external -extldflags "-pie"' ../nocgo || exit 1
+ fi
+ ;;
+ esac
;;
esac
;;