summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2011-03-01 23:40:21 +1030
committerRusty Russell <rusty@rustcorp.com.au>2011-03-01 23:40:21 +1030
commit39dc9e4612339af669e934c47500605f826a2bb4 (patch)
tree19dc253b83602b7385e51efc0cfdc898c3db1832
parentb6df44dc1f0c50bbed35e8f3370117ea2465f74a (diff)
iscsi, nfs, opt, tap: use config.h instead of defining _GNU_SOURCE.
-rw-r--r--ccan/iscsi/discovery.c2
-rw-r--r--ccan/iscsi/login.c2
-rw-r--r--ccan/nfs/init.c2
-rw-r--r--ccan/opt/test/run-checkopt.c2
-rw-r--r--ccan/opt/test/run-helpers.c2
-rw-r--r--ccan/opt/test/run-iter.c1
-rw-r--r--ccan/opt/test/run-usage.c1
-rw-r--r--ccan/opt/test/utils.c2
-rw-r--r--ccan/tap/tap.c5
9 files changed, 7 insertions, 12 deletions
diff --git a/ccan/iscsi/discovery.c b/ccan/iscsi/discovery.c
index 581084e9..2f2952f5 100644
--- a/ccan/iscsi/discovery.c
+++ b/ccan/iscsi/discovery.c
@@ -15,7 +15,7 @@
along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
-#define _GNU_SOURCE
+#include "config.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
diff --git a/ccan/iscsi/login.c b/ccan/iscsi/login.c
index 49a60e92..1fdf35ca 100644
--- a/ccan/iscsi/login.c
+++ b/ccan/iscsi/login.c
@@ -15,7 +15,7 @@
along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
-#define _GNU_SOURCE
+#include "config.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
diff --git a/ccan/nfs/init.c b/ccan/nfs/init.c
index 888504fb..7108b5f3 100644
--- a/ccan/nfs/init.c
+++ b/ccan/nfs/init.c
@@ -15,7 +15,7 @@
along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
-#define _GNU_SOURCE
+#include "config.h"
#include <stdio.h>
#include <stdarg.h>
#include <unistd.h>
diff --git a/ccan/opt/test/run-checkopt.c b/ccan/opt/test/run-checkopt.c
index 9e2f88a7..71ee3c41 100644
--- a/ccan/opt/test/run-checkopt.c
+++ b/ccan/opt/test/run-checkopt.c
@@ -1,4 +1,4 @@
-#define _GNU_SOURCE
+#include "config.h"
#include <stdio.h>
#include <ccan/tap/tap.h>
#include <setjmp.h>
diff --git a/ccan/opt/test/run-helpers.c b/ccan/opt/test/run-helpers.c
index 3bb70eb4..081d27a9 100644
--- a/ccan/opt/test/run-helpers.c
+++ b/ccan/opt/test/run-helpers.c
@@ -1,4 +1,4 @@
-#define _GNU_SOURCE
+#include "config.h"
#include <stdio.h>
#include <ccan/tap/tap.h>
#include <setjmp.h>
diff --git a/ccan/opt/test/run-iter.c b/ccan/opt/test/run-iter.c
index a7cfb746..66fd5db8 100644
--- a/ccan/opt/test/run-iter.c
+++ b/ccan/opt/test/run-iter.c
@@ -1,4 +1,3 @@
-#define _GNU_SOURCE
#include <ccan/tap/tap.h>
#include <stdarg.h>
#include <setjmp.h>
diff --git a/ccan/opt/test/run-usage.c b/ccan/opt/test/run-usage.c
index 37e8993f..73e6a949 100644
--- a/ccan/opt/test/run-usage.c
+++ b/ccan/opt/test/run-usage.c
@@ -1,4 +1,3 @@
-#define _GNU_SOURCE
#include <ccan/tap/tap.h>
#include <stdarg.h>
#include <setjmp.h>
diff --git a/ccan/opt/test/utils.c b/ccan/opt/test/utils.c
index 802b1538..fa0a2022 100644
--- a/ccan/opt/test/utils.c
+++ b/ccan/opt/test/utils.c
@@ -1,4 +1,4 @@
-#define _GNU_SOURCE
+#include "config.h"
#include <ccan/tap/tap.h>
#include <stdarg.h>
#include <stdlib.h>
diff --git a/ccan/tap/tap.c b/ccan/tap/tap.c
index 9c92f7f2..6d3ba0db 100644
--- a/ccan/tap/tap.c
+++ b/ccan/tap/tap.c
@@ -23,10 +23,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*/
-/* FIXME: The real fix is an asprintf module. */
-#ifndef _GNU_SOURCE
-#define _GNU_SOURCE 1
-#endif
+#include "config.h"
#include <ctype.h>
#include <stdarg.h>
#include <stdio.h>