libgo: only build syscall test with -static on GNU/Linux

For https://gcc.gnu.org/PR95061

Change-Id: If10904a30345af7b205bdd037ddc22080dff7fcb
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/234019
Reviewed-by: Cherry Zhang <cherryyz@google.com>
2 files changed