Re: XForms: Mesa Question

Steve Lamont (spl@szechuan.ucsd.edu)
Wed, 28 May 97 06:14:03 PDT

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

> I find this in xforms/DEMOS/01Readme:
> If you're using Mesa version other than
> 2.0, you probably should compile ../FORMS/gl.c and replace the
> one in the library.
>
> How do I do the latter?? Or is this not the reason?

Well, it is and it isn't. The full text of the paragraph in question
reads:

OpenGL/Mesa demos are by default not generated. If you have
the necessary libaries (OpenGL or Mesa2.0) and are using the
static library, type make gl glwin to generate the demos. If
you're using Mesa version other than 2.0, you probably should
compile ../FORMS/gl.c and replace the one in the library.

If you use the static version on the library. Check your
compiler/loader man pages for how to do this. On a Sun running gcc
it's

gcc ... -Xlinker -Bstatic -lforms -Xlinker -Bdynamic ...

I believe Linux is similar but check your documentation to be sure.

You can indeed add gl.c to the library -- compile and use

ar rv libforms.a gl.o

to add it to the static library. Offhand, I don't recall how to add
it to the dynamic library since I hate the things and never build them
if I have the choice.

Perhaps the easiest way to get the FORMS/gl.c stuff is to just add it
to your compile:

gcc -O -fPIC -I../FORMS -I/usr/X11R6/include -Ifd -c gl.c -o gl.o
gcc -O -fPIC -I../FORMS -I/usr/X11R6/include -Ifd -c ../FORMS/gl.c \
-o ../FORMS/gl.o
gcc -O -s -o gl gl.o ../FORMS/gl.o -L/usr/local/lib -lforms -lGL \
-lXext -L/usr/X11R6/lib -lX11 -lm

should do it.

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/