summaryrefslogtreecommitdiffstats
path: root/discover
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2013-12-16 16:21:50 +0800
committerJeremy Kerr <jk@ozlabs.org>2013-12-18 10:19:21 +0800
commit66bf929fa97fabb70198455f9eec2e9ccf0661fa (patch)
treedf9944b43cb30900f4947c7b1ea7e777d16b0d19 /discover
parentdf46fcfe4867fd16729bb10dfb82dcd43595c6c2 (diff)
downloadtalos-petitboot-66bf929fa97fabb70198455f9eec2e9ccf0661fa.tar.gz
talos-petitboot-66bf929fa97fabb70198455f9eec2e9ccf0661fa.zip
configure: Use AC_GNU_SOURCE
Rather than #defining _GNU_SOURCE in our .c files, we can define this from config.h instead. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'discover')
-rw-r--r--discover/boot.c4
-rw-r--r--discover/event.c1
-rw-r--r--discover/kboot-parser.c4
-rw-r--r--discover/parser-conf.c4
-rw-r--r--discover/paths.c4
-rw-r--r--discover/pxe-parser.c4
-rw-r--r--discover/resource.c4
-rw-r--r--discover/udev.c4
-rw-r--r--discover/user-event.c1
-rw-r--r--discover/yaboot-parser.c4
10 files changed, 24 insertions, 10 deletions
diff --git a/discover/boot.c b/discover/boot.c
index 0d61f0e..e5803a7 100644
--- a/discover/boot.c
+++ b/discover/boot.c
@@ -1,5 +1,7 @@
-#define _GNU_SOURCE
+#if defined(HAVE_CONFIG_H)
+#include "config.h"
+#endif
#include <stdbool.h>
#include <stdlib.h>
diff --git a/discover/event.c b/discover/event.c
index d4bb2c5..6434b40 100644
--- a/discover/event.c
+++ b/discover/event.c
@@ -2,7 +2,6 @@
#include "config.h"
#endif
-#define _GNU_SOURCE
#include <string.h>
#include <log/log.h>
diff --git a/discover/kboot-parser.c b/discover/kboot-parser.c
index 8572674..cebe787 100644
--- a/discover/kboot-parser.c
+++ b/discover/kboot-parser.c
@@ -1,4 +1,6 @@
-#define _GNU_SOURCE
+#if defined(HAVE_CONFIG_H)
+#include "config.h"
+#endif
#include <assert.h>
#include <stdlib.h>
diff --git a/discover/parser-conf.c b/discover/parser-conf.c
index 79193ed..5f2b978 100644
--- a/discover/parser-conf.c
+++ b/discover/parser-conf.c
@@ -16,7 +16,9 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
-#define _GNU_SOURCE
+#if defined(HAVE_CONFIG_H)
+#include "config.h"
+#endif
#include <assert.h>
#include <ctype.h>
diff --git a/discover/paths.c b/discover/paths.c
index 64b218e..0c8cc8b 100644
--- a/discover/paths.c
+++ b/discover/paths.c
@@ -1,4 +1,6 @@
-#define _GNU_SOURCE
+#if defined(HAVE_CONFIG_H)
+#include "config.h"
+#endif
#include <assert.h>
#include <string.h>
diff --git a/discover/pxe-parser.c b/discover/pxe-parser.c
index 811679d..2fc261b 100644
--- a/discover/pxe-parser.c
+++ b/discover/pxe-parser.c
@@ -1,5 +1,7 @@
-#define _GNU_SOURCE
+#if defined(HAVE_CONFIG_H)
+#include "config.h"
+#endif
#include <string.h>
#include <talloc/talloc.h>
diff --git a/discover/resource.c b/discover/resource.c
index f9019d1..04e14cb 100644
--- a/discover/resource.c
+++ b/discover/resource.c
@@ -1,5 +1,7 @@
-#define _GNU_SOURCE
+#if defined(HAVE_CONFIG_H)
+#include "config.h"
+#endif
#include <assert.h>
#include <stdbool.h>
diff --git a/discover/udev.c b/discover/udev.c
index 305df95..09c24fd 100644
--- a/discover/udev.c
+++ b/discover/udev.c
@@ -1,5 +1,7 @@
-#define _GNU_SOURCE
+#if defined(HAVE_CONFIG_H)
+#include "config.h"
+#endif
#include <assert.h>
#include <errno.h>
diff --git a/discover/user-event.c b/discover/user-event.c
index d7e0d19..69e6f7d 100644
--- a/discover/user-event.c
+++ b/discover/user-event.c
@@ -20,7 +20,6 @@
#include "config.h"
#endif
-#define _GNU_SOURCE
#include <assert.h>
#include <errno.h>
#include <string.h>
diff --git a/discover/yaboot-parser.c b/discover/yaboot-parser.c
index f16ac72..41f43eb 100644
--- a/discover/yaboot-parser.c
+++ b/discover/yaboot-parser.c
@@ -1,4 +1,6 @@
-#define _GNU_SOURCE
+#if defined(HAVE_CONFIG_H)
+#include "config.h"
+#endif
#include <assert.h>
#include <stdlib.h>
OpenPOWER on IntegriCloud