runtime: include <syscall.h> and <sys/syscall.h> if available
authorIan Lance Taylor <ian@gcc.gnu.org>
Fri, 15 Feb 2019 14:25:12 +0000 (14:25 +0000)
committerIan Lance Taylor <ian@gcc.gnu.org>
Fri, 15 Feb 2019 14:25:12 +0000 (14:25 +0000)
    Fixes Solaris build.

    Reviewed-on: https://go-review.googlesource.com/c/162885

From-SVN: r268940

gcc/go/gofrontend/MERGE
libgo/runtime/go-varargs.c

index 993916e9b680c261235d986f50fef44bc2924a59..00bc1e514b4294b3395b3c4f1ac166700011ece9 100644 (file)
@@ -1,4 +1,4 @@
-a9c1a76e14b66a356d3c3dfb50f1e6138e97733c
+6877c95a5f44c3ab4f492d2000ce07771341d7b7
 
 The first line of this file holds the git revision number of the last
 merge done from the gofrontend repository.
index dda99590dc7091c79b1214847fd27f58a0e2b754..cf033afbbd33bfedd143aebb8084ffc872eeb62c 100644 (file)
 #include <sys/types.h>
 #include <fcntl.h>
 #include <sys/ioctl.h>
+#ifdef HAVE_SYSCALL_H
+#include <syscall.h>
+#endif
+#ifdef HAVE_SYS_SYSCALL_H
+#include <sys/syscall.h>
+#endif
 
 /* The syscall package calls C functions.  The Go compiler can not
    represent a C varargs functions.  On some systems it's important