[comp.unix.aix] Compiling an SGI demo on RS/6000

hucka@eecs.umich.edu (Michael Hucka) (11/24/90)

Hi,
I am trying to learn how to use the graphics capabilities of an RS/6000 (AIX
3.1), on which we are planning to try running some programs developed on an
SGI Iris 4D.  So far I have had some trouble.  As a test I've copied the
jello demo sources from our Iris and tried compiling them on the IBM like
this:
	cc jello.c -lgl -lm
This works fine on the Iris but on the IBM this results in 

	0706-317 ERROR: Unresolved or undefined symbols detected:
                 Symbols in error (followed by references) are
                 dumped to the load map.
	._gl_sincos

Looking in the jello.c sources, I find that the routine "gl_sincos" (no
leading '.' character) is called in a few places.  Looking at /lib/libgl.a
reveals the following:

	> nm libgl.a | grep gl_sincos
	00025128 T ._gl_sincos
	00025128 t ._gl_sincos

So I thought maybe copying libgl.a and running ranlib over it would fix up
whatever reference was missing.  No dice; same error results.  I checked in
the jello.c source file and found that gl_sincos was not declared anywhere as
being external, so I added an extern statement at the top, but no change.
I searched extensively through the info facility, without luck.

Curiously, running
	find /usr/include -print -exec grep gl_sincos "{}" ";"
on both the IBM and SGI in an attempt to find out where gl_sincos is located,
reveals no reference to it on either machine.

Since I'm new to both systems, I'm sure I must be making a dumb error, but I
have exhausted all my ideas.  Can someone please point me in the right
direction?

Any help appreciated,
Mike

--
Mike Hucka                     | Internet: hucka@caen.engin.umich.edu    
University of Michigan AI Lab  | 1101 Beal Ave., Ann Arbor, MI 48109 

mkibler@eecs.wsu.edu (Michael K. Kibler) (11/26/90)

I have jello running on my 530 and it does not make reference to gl_sincos.
It uses only sin and cos. This source was ported by someone at IBM.


-- 
 ---- Mike  ( ~~ Radiosity is more than just heat! )
 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 Michael K. Kibler        INTERNET:  mkibler@eecs.wsu.edu
 Elect/Compt. Engr. Dept. UUCP    :  ...uunet!eecs.wsu.edu!mkibler