1
0
mirror of https://github.com/golang/go synced 2024-11-05 15:16:11 -07:00

runtime: set _XOPEN_SOURCE_EXTENDED for netbsd

If _XOPEN_SOURCE is defined, then netbsd also requires
_XOPEN_SOURCE_EXTENDED to define stack_t.

For #62440.

Change-Id: Ib05658c3ca7fae1f6b051566e713ce7bc7c037a0
Reviewed-on: https://go-review.googlesource.com/c/go/+/527775
Run-TryBot: Michael Pratt <mpratt@google.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
This commit is contained in:
Michael Pratt 2023-09-12 13:35:15 -04:00
parent 5cc1e99f94
commit e8ba0579e2

View File

@ -6,6 +6,8 @@
// Required for darwin ucontext.
#define _XOPEN_SOURCE
// Required for netbsd stack_t if _XOPEN_SOURCE is set.
#define _XOPEN_SOURCE_EXTENDED
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include <assert.h>