[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[patch] fix build for gcc5 on PowerPC
From: |
Alex Potapenko |
Subject: |
[patch] fix build for gcc5 on PowerPC |
Date: |
Thu, 29 Oct 2015 00:06:51 +0200 |
Trying to build ncurses (tried 5.9 and 6.0) for PowerPC using gcc5
leads to this kind of error:
http://lists.freebsd.org/pipermail/freebsd-toolchain/2015-March/001508.html
After further investigation, I discovered that output produced by the
cpp has some lines that are not expected by MKlib_gen.sh to be there,
e.g. # 39 "gen__31899.c" lines here:
int gen_attroff ( int z )
{
@@T((T_CALLED("attroff(%s)"), _traceattr2(0,(chtype)z))); returnCode(
wattr_off(stdscr, (attr_t)(z),
# 39 "gen__31899.c" 3 4
((void *)0)
# 39 "gen__31899.c"
) );
}
Thus, I suggest a simple patch that deals with this problem and allows
ncurses to build fine:
--- a/ncurses/base/MKlib_gen.sh
+++ b/ncurses/base/MKlib_gen.sh
@@ -442,6 +442,7 @@
-e 's/ / /g' \
-e 's/^ //' \
-e 's/_Bool/NCURSES_BOOL/g' \
+ -e ':a;N;$!ba;s/\n# [0-9]* "'"${TMP}"'"[^\n]*\n/ /g' \
| $AWK -f $AW2 \
| sed -f $ED3 \
| sed \
Please consider applying it, or resort to some other way to address this issue.
--
Thank you,
Alex Potapenko
- [patch] fix build for gcc5 on PowerPC,
Alex Potapenko <=