[ODE] Mac OS X installation of drawstuff

Peggy Skelly mxs70 at po.cwru.edu
Mon Mar 17 09:28:02 2003


After some work I got ode-0.035 along with the drawstuff-lib to compile in Mac OS X under gcc using the makefile. Here's what had to do:

1. to compile the drawstuff-lib:
in response to the 
	GL/gl.h and GL/glu.h: no such file or directory
and then later all the X11 headers, I _copied_ the gl and x headers from /usr/X11R6 into GL and X11 directories created in ode-0.035/include/. Just creating symbolic links didn't work for me.

2. ranlib problem: I got the following errors:
	ld: archive: lib/libode.a has no table of contents, add one with ranlib(1) (can't load from it)
	ld: archive: lib/libdrawstuff.a has no table of contents, add one with ranlib(1) (can't load from it)
Since just running ranlib on the files ("ranlib libode.a") did not work, I changed the line in makefile.osx to: RANLIB=ranlib. Running make reconfigured and recompiled, and both ode and drawstuff libs work.
	
3. compiling ode-test: linking test_chain2.o complains of undefined symbols. It needs the c++ lib. So in makefile.osx I changed  LINK_MATH=-lm by adding -lstdc++ 
	
4. After that, everything works fine -- if I remember to start up X11. If I forget, and just try to run one of the test apps from a terminal without X11 also running, I would get  "Error: Bus error."  I tracked the bus error down to a call to dsError in createMainWindow in x11.cpp. Was: dsError (0,"can not open X11 display"); but it should be: dsError ("can not open X11 display");. So now if X11 isn't running, it gives the more descriptive error.

Hope that helps,
Peggy