Undefined symbols

Steve Lamont (spl@szechuan.ucsd.edu)
Wed, 16 Apr 97 15:58:21 PDT

To subscribers of the xforms list from spl@szechuan.ucsd.edu (Steve Lamont) :

> I have just started to learn xforms a few days ago. I am having problem
> compiling a sample code (filename = glwin.c) that was bundled with the
> xforms source package (under directory DEMOS). ...
> [...]
>
> /opt/SUNWspro/bin/cc -Xa -DSVR4 -O -KPIC -I../FORMS -I/usr/openwin/include -Ifd -c glwin.c
> /opt/SUNWspro/bin/cc -Xa -DSVR4 -O -s -R/usr/openwin/lib:/usr/lib:/usr/local/openwin/lib -o glwin glwin.o -L../FORMS -lforms -lGL -lXext -L/usr/openwin/lib -lX11 -lnsl -lm
> Undefined first referenced
> symbol in file
> fl_glwincreate glwin.o

You need to also add gl.c, which should be in the FORMS directory of
your XForms distribution. NOTE: This is *not* the same as the file
gl.c in the DEMOS directory.

> I try an additional library flag "-lGlu" and that makes it compile successfully.

I'm surprised this compiles or links. As far as I'm aware,
fl_glwincreate() isn't in libGLU.a. I'd expect the same error
messages as above.

> HOWEVER, the execution of the output causes segmentation faults.

Probably because of an unresolved reference.

spl
_________________________________________________
To unsubscribe, send the message "unsubscribe" to
xforms-request@bob.usuf2.usuhs.mil or see
http://bob.usuf2.usuhs.mil/mailserv/xforms.html
Xforms Home Page: http://bragg.phys.uwm.edu/xforms
List Archive: http://bob.usuf2.usuhs.mil/mailserv/list-archives/xforms-archive/