Compiling Lesstif on Cygwin

Brian Ford ford@vss.fsi.com
Fri Jul 25 22:38:00 GMT 2003


On Fri, 25 Jul 2003, Gary Nicholson wrote:

> Having done those things, I get the following error:
>
> 	undefined reference to '_XtVaAppInitialize'
>
> Do you know what's happening?
>
That reference should have been resolved by -lXt.

> The compiler string:
>
> gcc -I/usr/X11R6/include -L/usr/X11R6/lib \
> -lXm -lXt -lX11 hello.c -o hello
>
I tried this myself and got different errors like:

/usr/X11R6/lib/libXt.a(Shell.o)(.text+0x37cd):Shell.c: undefined reference
to `_IceConnectionNumber'
and
/usr/X11R6/lib/libXt.a(Shell.o)(.text+0x3536):Shell.c: undefined reference
to `_SmcCloseConnection'

Try:

gcc -I/usr/X11R6/include -L/usr/X11R6/lib \
-lXm -lXt -lX11 -lSM -lICE hello.c -o hello

That should work.

-- 
Brian Ford
Senior Realtime Software Engineer
VITAL - Visual Simulation Systems
FlightSafety International
Phone: 314-551-8460
Fax:   314-551-8444



More information about the Cygwin-xfree mailing list