OpenGL and Mesa Linking Question

OpenGL and Mesa Linking Question

Post by Michael PAPASIME » Wed, 12 Nov 1997 04:00:00



Hi all,

I've been working on a Motif/OpenGL app at work where the Makefile
generates two executables, one linked with the SGI OpenGL libs
and the other linked with Mesa so that we can display it on
standard X-Terminals.

This was run an SGI Onyx running IRIX 5.3 using both cc and gcc
and everything worked fine. The system was upgraded recently
to IRIX 6.2 and I have been having a few problems.

The main problem is with the linking stage of the app linked
with Mesa. Linking with OpenGL works fine. Linking with the Mesa
libs work fine but I get a huge number of warnings for every single
function in the GL, GLU and GLX libraries that I am using.
The warnings are of the following form:

ld: WARNING 85: definition of glBegin in
/usr/people/michp/Mesa-2.2/lib/libMesaGL.a (api.o) preempts that
definition in /usr/lib/libGL.so

From this I presume it is trying to link in the standard OpenGL lib
in /usr/lib and you get a each function being defined twice even
though I only specified the Mesa libs on the link line.
Going through the ld man pages, mentions about looking in standard
directories such as /usr/lib to look for libraries, but I couldn't
figure how to solve this problem so as not to get all the error
messages as in IRIX 5.3.

Any one have any ideas how to fix this?

Your help is much appreciated.

Michael Papasimeon

 
 
 

OpenGL and Mesa Linking Question

Post by Stephane Morv » Wed, 12 Nov 1997 04:00:00


Michael,

I think that eventhough you may be doing something like -Lpathtomesa on
your cmd line, ld will still look into /usr/lib/ for the libraries to link
with. Check into man cc to find out what option you have to use in order
to avoid looking for libs into /usr/lib/.

It may also have to do with the order with which it is specified in your
cmd line. I had some warning as well when we moved from 5.3 to 6.2, and I
just had to make sure that the libs were specified in the right order in
my makefile.

Stephane

--
Stephane Morvan

Remove whatevr is odd in my email adress to respond...
***********************************************************
*   WWW Homepage: http://www.eng.clemson.edu/~smorvan/    *
*   IVECS Homepage: http://design.vr.clemson.edu/ivecs/   *
***********************************************************

 
 
 

1. OpenGL and Mesa Linking Question

Hi all,

I've been working on a Motif/OpenGL app at work where the Makefile
generates two executables, one linked with the SGI OpenGL libs
and the other linked with Mesa so that we can display it on
standard X-Terminals.

This was run an SGI Onyx running IRIX 5.3 using both cc and gcc
and everything worked fine. The system was upgraded recently
to IRIX 6.2 and I have been having a few problems.

The main problem is with the linking stage of the app linked
with Mesa. Linking with OpenGL works fine. Linking with the Mesa
libs work fine but I get a huge number of warnings for every single
function in the GL, GLU and GLX libraries that I am using.
The warnings are of the following form:

ld: WARNING 85: definition of glBegin in
/usr/people/michp/Mesa-2.2/lib/libMesaGL.a (api.o) preempts that
definition in /usr/lib/libGL.so

From this I presume it is trying to link in the standard OpenGL lib
in /usr/lib and you get a each function being defined twice even
though I only specified the Mesa libs on the link line.
Going through the ld man pages, mentions about looking in standard
directories such as /usr/lib to look for libraries, but I couldn't
figure how to solve this problem so as not to get all the error
messages as in IRIX 5.3.

Any one have any ideas how to fix this?

Your help is much appreciated.

Michael Papasimeon

2. Need to save a circular image, but having trouble.

3. dynamically linking with Mesa or OpenGL shared libraries

4. 3D inverse kinematics

5. Questions about Mesa and OpenGL

6. gh!SP - Entertainment SoftWare Services!!

7. Mesa-5.0: linking to libGLU undefined references (-lGLU)

8. Multipass texturing in OpenGL

9. linking problems with Mesa/Linux

10. problems while linking a mesa program

11. MESA and Linux RedHat 4.2 Problem linking!!!!

12. Mesa Linking error

13. Help!!! Trouble compiling and linking Mesa 2.5 programs