+++ /dev/null
---- poldek-0.30/cli/shell.c~ 2010-11-25 22:30:09.000000000 +0100
-+++ poldek-0.30/cli/shell.c 2011-02-06 20:20:23.502000232 +0100
-@@ -18,6 +18,13 @@
- # include "config.h"
- #endif
-
-+#ifndef __USE_EXTERN_INLINES
-+# define __USE_EXTERN_INLINES
-+# include <argp.h>
-+# undef __USE_EXTERN_INLINES
-+#else
-+# include <argp.h>
-+#endif
- #include <stdio.h>
- #include <stdlib.h>
- #include <stdint.h>
-@@ -28,7 +35,6 @@
- #include <sys/errno.h>
- #include <sys/param.h>
- #include <signal.h>
--#include <argp.h>
- #include <fnmatch.h>
- #include <unistd.h>
-
--- /dev/null
+commit c6c6020ba55a3a14fc2ca190c5623bf51ac0d8b6
+Author: Kacper Kornet <draenog@pld-linux.org>
+Date: Mon Mar 24 06:58:32 2014 +0000
+
+ Don't use internal glibc function
+
+diff --git a/cli/shell.c b/cli/shell.c
+index bcd334a..58067e8 100644
+--- a/cli/shell.c
++++ b/cli/shell.c
+@@ -73,6 +73,11 @@ struct sh_ctx {
+
+ static struct sh_ctx sh_ctx = { COMPLETITION_CTX_NONE, NULL };
+
++inline static int option_is_end (const struct argp_option *__opt)
++{
++ return !__opt->key && !__opt->name && !__opt->doc && !__opt->group;
++}
++
+ static
+ int is_upgradeable(struct poclidek_ctx *cctx, struct pkg *pkg, int reverse)
+ {
+@@ -191,7 +196,7 @@ static char *command_options_generator(const char *text, int state)
+
+ len = strlen(&text[2]);
+
+- for (i = 0; !_option_is_end(&command->argp_opts[i]); i++) {
++ for (i = 0; !option_is_end(&command->argp_opts[i]); i++) {
+ const struct argp_option *argp_opt = &command->argp_opts[i];
+
+ /* skip hidden options */
Source101: %{name}-multilib-snap.conf
Source102: %{name}-debuginfo-snap.conf
Patch0: %{name}-size-type.patch
-Patch1: %{name}-Os-fail-workaround.patch
+Patch1: %{name}-glibc-internal.patch
Patch2: %{name}-config.patch
Patch3: at-char-completion.patch
Patch4: %{name}-ignore-too-long-paths.patch
%{__automake}
cd ..
-CPPFLAGS="%{rpmcppflags} -std=gnu99"
+CPPFLAGS="%{rpmcppflags} -std=gnu99 -fgnu89-inline"
%configure \
%{?with_static:--enable-static --disable-shared} \
%{!?with_imode:--disable-imode} \