From: Axel Kohlmeyer (akohlmey_at_cmm.chem.upenn.edu)
Date: Sat Mar 08 2008 - 20:51:50 CST

On Sat, 8 Mar 2008, Dan Strahs wrote:

DS>
DS> Hello everyone:

hello dan,

DS> I'm stumped on a compile problem, and hoping that someone might have some
DS> pointers.
DS>
DS> I'm compiling VMD1.8.6 from source in Fedora Core 4. I've got the Mesa
DS> Libs/GLUT 6.4.2 installed in /usr/local. My current configure options for
DS> VMD are LINUX MESA FLTK TK IMD TCL PTHREADS ACTC NETCDF PYTHON NUMPY; the
DS> RPMS/sources for these other options were installed for VMD1.8.4 (which I
DS> installed about 1.5 years ago). FLTK was updated from 1.1.5 to 1.1.7.
DS>
DS> I first tried compiling VMD1.8.6 with the OPENGL configure option, but this
DS> failed almost immediately during the compile of
DS> OpenGLRenderer.C:OpenGLRenderer.C (which is the third file in the
DS> compilation list):
DS>
DS> In member function void OpenGLRenderer::cylinder(float*, float*, int, float,
DS> float):
DS> OpenGLRenderer.C:686: error: sqrtf was not declared in this scope
DS> OpenGLRenderer.C:689: error: acosf was not declared in this scope
DS> make: *** [OpenGLRenderer.o] Error 1

DS> This suggested to me that the GL header files in my OS were a problem, so I
DS> installed Mesa 6.4.2. I realize that
DS> http://www.ks.uiuc.edu/Research/vmd/current/linuxrelnotes.html suggests Mesa
DS> 4.X, but I suspected that Mesa 6.X would be fully compatible (if this is
DS> wrong, please tell me!)

as far as i can tell, you are wrong. the error you see comes from
the math header. the missing functions are single precision math
functions. if that is not included properly, you may have a buggy
compiler...

as far as OpenGL is concerned, you should not worry about those
headers, since VMD only uses only standardized APIs and ships
its own standard OpenGL headers. i've been compiling VMD on FC4
before so it should work.

DS> The VMD lib/Mesa/{include,lib_LINUX) were symlinked respectively to
DS> /usr/local/{include/GL,lib). From past experience with 1.8.3, I had already
DS> added several -I include dirs and -L lib dirs to src/Makefile:
DS> /usr/include/python2.4 /usr/local/include/ac /usr/local/include
DS> /usr/lib/python2.4/config /usr/local/lib /usr/X11R6/lib.
DS>
DS> After I cleaned up the previous installation and configured with LINUX MESA
DS> etc.., make still complained with the same error in OpenGLRenderer.C.
DS>
DS> Based on the sqrtf/acosf complaints, I also added -I/usr/include/c++/4.0.2
DS> and -I/usr/include/c++/4.0.2/i386-redhat-linux/bits, and added
DS> include statements for glext.h, c++config.h, and cstdlib. But the VMD
DS> compile still fails with the same error.
DS>
DS> At this point I'm stumped, since math.h was already included. Any pointers
DS> would be greatly appreciated!

i would rather first _remove_ include directories and try to get
it to work with the minimum.

cheers,
    axel.

DS>
DS> Dan Strahs
DS> Assistant Professor
DS> Biology and Health Sciences
DS> Pace University
DS>
DS>
DS>

-- 
=======================================================================
Axel Kohlmeyer   akohlmey_at_cmm.chem.upenn.edu   http://www.cmm.upenn.edu
   Center for Molecular Modeling   --   University of Pennsylvania
Department of Chemistry, 231 S.34th Street, Philadelphia, PA 19104-6323
tel: 1-215-898-1582,  fax: 1-215-573-6233,  office-tel: 1-215-898-5425
=======================================================================
If you make something idiot-proof, the universe creates a better idiot.