package/python-simplejson: bump version to 3.8.2
[buildroot-gz.git] / package / ncurses / 0002-gcc-5.x-MKlib_gen.patch
blob25c2bd02d10bd344078c6872a78c91509bb675cd
1 Fix gcc 5.x build failure
3 Extracted from upstream commit
4 http://ncurses.scripts.mit.edu/?p=ncurses.git;a=commit;h=97bb4678dc03e753290b39bbff30ba2825df9517.
6 + modify MKlib_gen.sh to work around change in development version of
7 gcc introduced here:
8 https://gcc.gnu.org/ml/gcc-patches/2014-06/msg02185.html
9 https://gcc.gnu.org/ml/gcc-patches/2014-07/msg00236.html
10 (reports by Marcus Shawcroft, Maohui Lei).
12 Original author: Thomas E. Dickey <dickey@invisible-island.net>
13 Signed-off-by: Mikhail Peselnik <bas@bmail.ru>
15 --- a/ncurses/base/MKlib_gen.sh.orig 2015-07-23 21:52:32.239481505 +0300
16 +++ b/ncurses/base/MKlib_gen.sh 2015-07-23 21:53:20.772966587 +0300
17 @@ -437,11 +437,22 @@
18 -e 's/gen_$//' \
19 -e 's/ / /g' >>$TMP
21 +cat >$ED1 <<EOF
22 +s/ / /g
23 +s/^ //
24 +s/ $//
25 +s/P_NCURSES_BOOL/NCURSES_BOOL/g
26 +EOF
28 +# A patch discussed here:
29 +# https://gcc.gnu.org/ml/gcc-patches/2014-06/msg02185.html
30 +# introduces spurious #line markers. Work around that by ignoring the system's
31 +# attempt to define "bool" and using our own symbol here.
32 +sed -e 's/bool/P_NCURSES_BOOL/g' $TMP > $ED2
33 +cat $ED2 >$TMP
35 $preprocessor $TMP 2>/dev/null \
36 -| sed \
37 - -e 's/ / /g' \
38 - -e 's/^ //' \
39 - -e 's/_Bool/NCURSES_BOOL/g' \
40 +| sed -f $ED1 \
41 | $AWK -f $AW2 \
42 | sed -f $ED3 \
43 | sed \