diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2020-02-22 15:59:13 -0500 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2020-02-22 15:59:13 -0500 |
| commit | 936d0b18b116ea126893d2f165f9be72f8bef845 (patch) | |
| tree | 8481d2c4265d34217e6b045cbf1c7e34c30aab51 /src/os.cpp | |
| parent | 0cd89e9176ab36fc5e267120dc4d75cb79d32684 (diff) | |
| download | zig-936d0b18b116ea126893d2f165f9be72f8bef845.tar.gz zig-936d0b18b116ea126893d2f165f9be72f8bef845.zip | |
update std lib to integrate with libc for environ
closes #3511
Diffstat (limited to 'src/os.cpp')
| -rw-r--r-- | src/os.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/os.cpp b/src/os.cpp index 268e812050..8e0bcc433b 100644 --- a/src/os.cpp +++ b/src/os.cpp @@ -81,11 +81,7 @@ static clock_serv_t macos_monotonic_clock; #include <errno.h> #include <time.h> -// Apple doesn't provide the environ global variable -#if defined(__APPLE__) && !defined(environ) -#include <crt_externs.h> -#define environ (*_NSGetEnviron()) -#elif defined(ZIG_OS_FREEBSD) || defined(ZIG_OS_NETBSD) || defined(ZIG_OS_DRAGONFLY) +#if !defined(environ) extern char **environ; #endif |
