1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
Date: Sat, 16 Jul 2016 23:52:50 +0100
From: Steven Chamberlain <stevenc@debian.org>
Subject: Use _GNU_SOURCE on GNU/kFreeBSD
Forwarded: https://trac.nginx.org/nginx/ticket/2366
Define _GNU_SOURCE not only on GNU/Hurd, but also other glibc-based
platforms including GNU/kFreeBSD.
modified by jan.mojzis@gmail.com
Index: nginx/src/os/unix/ngx_posix_config.h
===================================================================
--- nginx.orig/src/os/unix/ngx_posix_config.h
+++ nginx/src/os/unix/ngx_posix_config.h
@@ -21,10 +21,13 @@
#endif
-#if (NGX_GNU_HURD)
+#if defined(NGX_GNU_HURD) || defined(__GLIBC__)
#ifndef _GNU_SOURCE
#define _GNU_SOURCE /* accept4() */
#endif
+#endif
+
+#if (NGX_GNU_HURD)
#define _FILE_OFFSET_BITS 64
#endif
|