logrotate: fix build with gcc 6
[buildroot-gz.git] / package / util-linux / 0001-build-sys-fix-uClibc-ng-scanf-check.patch
blob801b72b26d8e8eea9f1df3a645be888e1bd439cd
1 From bac7fbdb2d141879526ca4342d56d2c749ba8af5 Mon Sep 17 00:00:00 2001
2 From: Waldemar Brodkorb <wbx@uclibc-ng.org>
3 Date: Fri, 3 Jun 2016 04:23:28 +0200
4 Subject: [PATCH] build-sys: fix uClibc-ng scanf check
6 uClibc-ng tries to be compatible with GNU libc and defines
7 __GLIBC__ and pretend to be version 2.2.
8 We once changed it to 2.10, but then some hard to fix problems
9 in different software packages (gcc) occured.
10 It would be better if we disable the special GNU libc checks
11 for uClibc-ng here. uClibc-ng implements the required scanf
12 functionality.
14 Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
15 ---
16 configure.ac | 2 +-
17 1 file changed, 1 insertion(+), 1 deletion(-)
19 diff --git a/configure.ac b/configure.ac
20 index 3ba723f..ec197ee 100644
21 --- a/configure.ac
22 +++ b/configure.ac
23 @@ -581,7 +581,7 @@ AC_CACHE_VAL([scanf_cv_alloc_modifier],
24 #include <stdio.h>
25 #include <unistd.h>
27 - #ifdef __GLIBC__
28 + #if defined(__GLIBC__) && !defined(__UCLIBC__)
30 #if !(__GLIBC_PREREQ(2, 7))
31 #error %m is not available
32 --
33 2.1.4