Here is a problem and its solution. I am just reporting it so it can be
integrated into the next release. It may even warrant a release; at
least I found it pretty annoying.
The problem: On Fedora Core 5 x86_64 (I don't know if it also happens on
32-bit platforms), the program compiles and links OK. If you right-click
an atom to select it, the program crashes with the following error:
freeglut ERROR: Function <glutBitmapCharacter> called without first
calling 'glutInit'.
Apparently, in the latest versions of freeglut (2.4 and up), glutInit
has to be called first.
The changes I made are:
In xmakemol.c:
- Add a prototype
void glutInit(int *argcp, char **argv);
(I guess it would be cleaner to include glut.h or freeglut.h)
- add a call to this function early in main().
In Makefile:
- add -lglut to the flags in xmakemol_LDADD
I leave figuring out the proper #ifdefs and the exact location where the
function call should go to the authors.
Cheers,
Herbert
--
Herbert Fruchtl
EaStCHEM Fellow
School of Chemistry
University of St Andrews
_______________________________________________
XMakemol-bugs mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/xmakemol-bugs