Scripts: kconfig: nconf: fix _GNU_SOURCE redefined warning
authorCheah Kok Cheong <thrust73@gmail.com>
Sun, 27 Nov 2016 16:28:26 +0000 (00:28 +0800)
committerMichal Marek <mmarek@suse.com>
Tue, 29 Nov 2016 13:03:14 +0000 (14:03 +0100)
Fix below warning when make nconfig is run initially
or after make clean.

  HOSTCC  scripts/kconfig/nconf.o
scripts/kconfig/nconf.c:8:0: warning: "_GNU_SOURCE" redefined
 #define _GNU_SOURCE
 ^
<command-line>:0:0: note: this is the location of the previous definition

Signed-off-by: Cheah Kok Cheong <thrust73@gmail.com>
Signed-off-by: Michal Marek <mmarek@suse.com>
scripts/kconfig/nconf.c

index d42d534a66cd7006a38e113b4b5b8e30359e7a76..a9bc5334a478d6774d1409a837665b4f143d8597 100644 (file)
@@ -5,7 +5,9 @@
  * Derived from menuconfig.
  *
  */
+#ifndef _GNU_SOURCE
 #define _GNU_SOURCE
+#endif
 #include <string.h>
 #include <stdlib.h>