summaryrefslogtreecommitdiffstats
path: root/daemon
diff options
context:
space:
mode:
authorRichard W.M. Jones <rjones@redhat.com>2009-04-23 18:51:12 +0100
committerRichard W.M. Jones <rjones@redhat.com>2009-04-23 18:51:12 +0100
commit6eaa49faddeef5ec086ad7c58e0cd591fb4400dc (patch)
tree5ae195f68181d792055042f4ec4722c6f823a0e9 /daemon
parentb18961055531f0107ed4f62c0d2f28e4ac1270e0 (diff)
downloadlibguestfs-6eaa49faddeef5ec086ad7c58e0cd591fb4400dc.tar.gz
libguestfs-6eaa49faddeef5ec086ad7c58e0cd591fb4400dc.tar.xz
libguestfs-6eaa49faddeef5ec086ad7c58e0cd591fb4400dc.zip
Use AC_GNU_SOURCE in daemon. Don't need _GNU_SOURCE in C files any more.
Diffstat (limited to 'daemon')
-rw-r--r--daemon/configure.ac3
-rw-r--r--daemon/file.c2
-rw-r--r--daemon/stubs.c2
-rw-r--r--daemon/tune2fs.c2
4 files changed, 4 insertions, 5 deletions
diff --git a/daemon/configure.ac b/daemon/configure.ac
index e8aebc96..e0ff7ce2 100644
--- a/daemon/configure.ac
+++ b/daemon/configure.ac
@@ -33,6 +33,9 @@ AC_ARG_ENABLE([debug-command],
[AC_DEFINE_UNQUOTED([ENABLE_DEBUG_COMMAND],[1],[Enable the 'debug' command])],
[])
+dnl For strchrnul(3), asprintf(3), futimens(2) and getline(3).
+AC_GNU_SOURCE
+
dnl Check for basic C environment.
AC_PROG_CC
AC_PROG_INSTALL
diff --git a/daemon/file.c b/daemon/file.c
index 24398339..f910b947 100644
--- a/daemon/file.c
+++ b/daemon/file.c
@@ -18,8 +18,6 @@
#include <config.h>
-#define _GNU_SOURCE /* for futimens(2) and getline(3) */
-
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
diff --git a/daemon/stubs.c b/daemon/stubs.c
index 526a8617..e51349ae 100644
--- a/daemon/stubs.c
+++ b/daemon/stubs.c
@@ -19,7 +19,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#define _GNU_SOURCE // for strchrnul
+#include <config.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/daemon/tune2fs.c b/daemon/tune2fs.c
index adf2a98e..742a7d91 100644
--- a/daemon/tune2fs.c
+++ b/daemon/tune2fs.c
@@ -18,8 +18,6 @@
#include <config.h>
-#define _GNU_SOURCE // for strchrnul
-
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>