SUMMARY: referencing errors in curses.a compiling ntalk

From: Emile Bartole (bartole@crpcu.lu)
Date: Tue Aug 02 1994 - 11:08:00 CDT


Hi Sun-Managers,

many thanks to:

Pat Myrto <rwing!pat@ole.cdac.com>
Casper Dik <casper@fwi.uva.nl>
Christian Masopust <Christian.Masopust@emndev.siemens.co.at>

who gave interesting suggestions, but I have not been able
to solve the problem. In my opinion, there are bugs in the
libcurses.a libraries; the two functions

        noecho();
        crmode();

seem to be incorrectly implemented in /usr/ccs/lib/libcurses.a.
Replacing -lcurses -ltermlib by the equivalent -ltermcap (as
Pat Myrto suggested) brought the same linker errors as before.

Even the function

        cbreak();

, meant to replace the obsolete
        
        crmode();

gave the same linker errors as crmode().

The Berkeley Version of libcurses.a, /usr/ucblib/libcurses.a,
still gives the same fatal multiple definition error. Including
-lucb (as Casper Dik suggested) brought no different result either.

The only workaround to compile 'ntalk' seems to be to throw
both calls out of the sourcetext; the program then will work,
but has difficulties converting CRs to LFs.

Maybe I'm luckier next time,

        Emile Bartole

>
>
> Hi gurus,
>
> I have a problem compiling ntalk on my Solaris 2 station.
> This is the error message issued by the linker:
>
>
> Undefined first referenced
> symbol in file
> _tty init_disp.o
> _echoit init_disp.o
> _tty_ch init_disp.o
> _rawmode init_disp.o
> ld: fatal: Symbol referencing errors. No output written to ntalk
> *** Error code 1
> make: Fatal error: Command failed for target `ntalk'
>
>
> The two routines responsible for the error in init_disp.c are:
>
> noecho();
> crmode();
>
> as, if they are commented out, the compilation will succeed.
> As in the standard Makefile I compiled using the libraries
> libcurses.a and libtermlib.a (both from directory /usr/ccs/lib).
>
> I tried also using the libcurses.a library from /usr/ucblib which
> does not give the linker error above; but there I got the linker errors:
>
> ld: fatal: symbol `Def_term' is multiply defined:
> (file /usr/ucblib/libcurses.a(curses.o) and file /usr/ccs/lib/libtermlib.a(setupterm.o));
> ld: warning: symbol `ttytype' has differing sizes:
> (file /usr/ucblib/libcurses.a(curses.o) value=0x32; file /usr/ccs/lib/libtermlib.a(setupterm.o) value=0x80);
> /usr/ccs/lib/libtermlib.a(setupterm.o) definition taken
> ld: fatal: File processing errors. No output written to ntalk
> *** Error code 1
> make: Fatal error: Command failed for target `ntalk'
>
>
> Anyway I would prefer a solution using the original /usr/ccs/lib/libcurses.a
> library.
>
> So, what am I missing? Any library? Any patch? Any sign from heaven?
>
> Thanks to all those who will respond,
>



This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:09:06 CDT