tech-toolchain archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: mknative-gdb: curses detection failure ... TUI disabled



In article <20101221175547.GA269464%medusa.sis.pasteur.fr@localhost>,
Nicolas Joly  <njoly%pasteur.fr@localhost> wrote:
>-=-=-=-=-=-
>
>On Tue, Dec 14, 2010 at 12:07:30AM +0100, Nicolas Joly wrote:
>> 
>> Hi,
>> 
>> While trying to add support for 32bit objects in gdb(1) on my -current
>> amd64 workstation, i had to run mknative-gdb tool. But i noticed that
>> generated init.c file had all _initialize_tui_* symbols removed
>> 
>> The problem comes from the gdb/configure script that now fails to detect
>> the curses library :
>> 
>> configure:8145: /local/src/NetBSD/tool/bin/x86_64--netbsd-gcc -isystem
>/local/src/NetBSD/dest/amd64/usr/include
>-L/local/src/NetBSD/dest/amd64/lib
>-L/local/src/NetBSD/dest/amd64/usr/lib
>-B/local/src/NetBSD/dest/amd64/usr/lib/ -o conftest    conftest.c
>-lcurses  -lm  >&5
>>
>/local/src/NetBSD/tool/lib/gcc/x86_64--netbsd/4.1.3/../../../../x86_64--netbsd/bin/ld:
> warning: libterminfo.so.1, needed by
>/local/src/NetBSD/dest/amd64/usr/lib/libcurses.so, not found (try using
>-rpath or -rpath-link)
>> /local/src/NetBSD/dest/amd64/usr/lib/libcurses.so: undefined reference
>to `del_curterm'
>> /local/src/NetBSD/dest/amd64/usr/lib/libcurses.so: undefined reference
>to `ti_setupterm'
>> /local/src/NetBSD/dest/amd64/usr/lib/libcurses.so: undefined reference
>to `t_vparm'
>> /local/src/NetBSD/dest/amd64/usr/lib/libcurses.so: undefined reference
>to `vtparm'
>> /local/src/NetBSD/dest/amd64/usr/lib/libcurses.so: undefined reference
>to `tputs'
>> /local/src/NetBSD/dest/amd64/usr/lib/libcurses.so: undefined reference
>to `ti_puts'
>> /local/src/NetBSD/dest/amd64/usr/lib/libcurses.so: undefined reference
>to `cur_term'
>> /local/src/NetBSD/dest/amd64/usr/lib/libcurses.so: undefined reference
>to `set_curterm'
>> collect2: ld returned 1 exit status
>> configure:8151: $? = 1
>
>For the record, this is a ld(1) problem which does not deals nicely
>with implicit libraries dependencies ... unless they exists in the
>default location (-L flag has no effect).
>
>And on -current libcurses.so now depends on libterminfo.so, which
>works fine with a native compiler/linker, but fails when
>cross-compiling where cross-linker set default location to
>${TOOLDIR}/x86_64--netbsd/lib
>
>The attached patch, which i plan to commit, works around the curses
>detection problem by setting the expected result for waddstr()
>configure tests, in MKNATIVE_CONFIGURE_PRESET.
>

Go for it.

christos



Home | Main Index | Thread Index | Old Index