summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2017-02-15 13:05:27 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2017-02-15 13:05:27 +0100
commit661be207776e84acbfce438347bce7c34dfabadf (patch)
tree01f8e1aa3fffddfd312c527f013a3887fdf507e7
parentbsps/sparc: Fix warnings (diff)
downloadrtems-661be207776e84acbfce438347bce7c34dfabadf.tar.bz2
shell: Fix warnings
-rw-r--r--cpukit/libmisc/shell/hexdump-conv.c5
-rw-r--r--cpukit/libmisc/shell/hexdump-odsyntax.c7
2 files changed, 8 insertions, 4 deletions
diff --git a/cpukit/libmisc/shell/hexdump-conv.c b/cpukit/libmisc/shell/hexdump-conv.c
index a157aaecc4..d37c6d988a 100644
--- a/cpukit/libmisc/shell/hexdump-conv.c
+++ b/cpukit/libmisc/shell/hexdump-conv.c
@@ -39,7 +39,10 @@
#ifndef lint
static const char sccsid[] = "@(#)conv.c 8.1 (Berkeley) 6/6/93";
#endif /* not lint */
-#endif
+#else /* __rtems__ */
+/* For wcwidth() visibility */
+#define _GNU_SOURCE
+#endif /* __rtems__ */
#include <sys/cdefs.h>
__FBSDID("$FreeBSD: src/usr.bin/hexdump/conv.c,v 1.9 2006/07/31 14:17:04 jkoshy Exp $");
diff --git a/cpukit/libmisc/shell/hexdump-odsyntax.c b/cpukit/libmisc/shell/hexdump-odsyntax.c
index 88c7b80501..bc6211b0d5 100644
--- a/cpukit/libmisc/shell/hexdump-odsyntax.c
+++ b/cpukit/libmisc/shell/hexdump-odsyntax.c
@@ -39,13 +39,14 @@
#if 0
static char sccsid[] = "@(#)odsyntax.c 8.2 (Berkeley) 5/4/95";
#endif /* not lint */
+#ifdef __rtems__
+/* For asprintf() visibility */
+#define _GNU_SOURCE
+#endif /* __rtems__ */
#include <sys/cdefs.h>
__FBSDID("$FreeBSD: src/usr.bin/hexdump/odsyntax.c,v 1.17 2004/07/22 13:14:42 johan Exp $");
#endif
-#ifdef __rtems__
-#define _GNU_SOURCE
-#endif
#include <sys/types.h>
#include <ctype.h>