summaryrefslogtreecommitdiff
path: root/test/argp/argp-ex1.c
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@uclibc-ng.org>2016-11-03 20:19:02 +0100
committerWaldemar Brodkorb <wbx@uclibc-ng.org>2016-11-03 20:19:02 +0100
commit24b4b8b66366176b40525baa1b2f056e8a68d0ce (patch)
treec705733ff04ff1d089eff6494622668632565a62 /test/argp/argp-ex1.c
parent3384c45e66ddf18f235654b67ae34ac7dcb07534 (diff)
argp: be sure uClibc-ng feature is available
Diffstat (limited to 'test/argp/argp-ex1.c')
-rw-r--r--test/argp/argp-ex1.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/argp/argp-ex1.c b/test/argp/argp-ex1.c
index 7bb5f22..5a4f93b 100644
--- a/test/argp/argp-ex1.c
+++ b/test/argp/argp-ex1.c
@@ -6,10 +6,16 @@
a (rather pointless) messages for --help. */
#include <stdlib.h>
+#if (defined(__GLIBC__) && !defined(__UCLIBC__)) || defined(__UCLIBC_HAS_ARGP__)
#include <argp.h>
+#endif
int main (int argc, char **argv)
{
+#if (defined(__GLIBC__) && !defined(__UCLIBC__)) || defined(__UCLIBC_HAS_ARGP__)
argp_parse (0, argc, argv, 0, 0, 0);
exit (0);
+#else
+ return 23;
+#endif
}