This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug tui/21482] gdb 8.0 tui doesn't build with native curses on Solaris
- From: "ro at CeBiTec dot Uni-Bielefeld.DE" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Wed, 17 May 2017 08:19:21 +0000
- Subject: [Bug tui/21482] gdb 8.0 tui doesn't build with native curses on Solaris
- Auto-submitted: auto-generated
- References: <bug-21482-4717@http.sourceware.org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=21482
--- Comment #2 from Rainer Orth <ro at CeBiTec dot Uni-Bielefeld.DE> ---
> --- Comment #1 from Yao Qi <qiyao at gcc dot gnu.org> ---
> Close this issue as it is fixed by
> https://sourceware.org/ml/gdb-patches/2017-05/msg00287.html ?
They are completely unrelated, unfortunately: this one persists even
after the fix above went in.
The problem boils down to
$ cat cc.c
#include <string.h>
const char *str = "msg";
void
func (char *str)
{
(void) strlen (str);
}
void
call (void)
{
func (str);
}
$ g++ -c -O2 -Wall -c cc.c
cc.c: In function 'void call()':
cc.c:14:12: error: invalid conversion from 'const char*' to 'char*'
[-fpermissive]
func (str);
^
cc.c:6:1: note: initializing argument 1 of 'void func(char*)'
func (char *str)
^~~~
However (as I wasn't aware initially), you can simply cast the constness
away in all calls to mvwaddstr. I'll give that a whirl.
Rainer
--
You are receiving this mail because:
You are on the CC list for the bug.