build: Use macOS' compatibility macros to enable all features.

* configure.ac: On macOS, use the compatibility macros to expose every
feature of the libc.  This is the equivalent of _GNU_SOURCE on GNU
libc.
--
Not defining this leads to compilation errors or superfluous warnings
on macOS.

GnuPG-bug-id: 2910
Signed-off-by: Justus Winter <justus@g10code.com>
This commit is contained in:
Justus Winter 2017-02-13 14:58:07 +01:00
parent f8db658f8b
commit 60273e8b2c
No known key found for this signature in database
GPG Key ID: DD1A52F9DA8C9020

View File

@ -167,6 +167,8 @@ case "${host}" in
have_ld_version_script=yes have_ld_version_script=yes
;; ;;
*-apple-darwin*) *-apple-darwin*)
AC_DEFINE(_DARWIN_C_SOURCE, 900000L,
Expose all libc features (__DARWIN_C_FULL).)
AC_DEFINE(_XOPEN_SOURCE, 500, Activate POSIX interface on MacOS X) AC_DEFINE(_XOPEN_SOURCE, 500, Activate POSIX interface on MacOS X)
;; ;;
esac esac