[gate-users] compiling on Mac OSX
Paul Vaska
vaska at bnl.gov
Wed May 12 16:22:50 CEST 2004
Hello,
I'm trying to compile GATE on my spiffy new dual 2-GHz Macintosh G5
running the latest OSX 10.3.3 and have run into compiler errors while
making Geant 4.5.2.p02 apparently having to do with the G4OpenGL code.
I know this is a Geant problem, but since Mac is not officially
supported by Geant and the Gate pages say this should work, I thought
someone here might know best. This error seems to prevent Gate from
compiling successfully.
I used all the defaults for the Geant installer (except for /sw for the
clhep directories) and managed to eliminate some initial compiler
errors. The first was that g++3 is not recognized, so I changed it to
just g++ in geant4.5.2.p02/con g/sys/Darwin-g++.gmk. The second was
that certain include files could not be found which were being sought
in /usr/include/GL (I added a link to /sw/lib/root/cint/include/GL
which seemed to have the necessary files). But I don't know what to do
about the remaining errors:
Compiling G4OpenGLImmediateSceneHandler.cc ...
In file included from src/G4OpenGLImmediateSceneHandler.cc:42:
include/G4OpenGLSceneHandler.hh:105: error: parse error before `[' token
include/G4OpenGLSceneHandler.hh:106: warning: ISO C++ forbids
declaration of `
GLubyte' with no type
include/G4OpenGLSceneHandler.hh:106: error: parse error before `[' token
In file included from src/G4OpenGLImmediateSceneHandler.cc:44:
include/G4OpenGLTransform3D.hh:47: warning: ISO C++ forbids declaration
of `
GLdouble' with no type
include/G4OpenGLTransform3D.hh:47: error: parse error before `*' token
include/G4OpenGLTransform3D.hh:49: error: parse error before `[' token
src/G4OpenGLImmediateSceneHandler.cc: In member function `virtual void
G4OpenGLImmediateSceneHandler::BeginPrimitives(const
G4Transform3D&)':
src/G4OpenGLImmediateSceneHandler.cc:74: error: `glPushMatrix'
undeclared
(first use this function)
src/G4OpenGLImmediateSceneHandler.cc:74: error: (Each undeclared
identifier is
reported only once for each function it appears in.)
src/G4OpenGLImmediateSceneHandler.cc:87: error: `GetGLMatrix'
undeclared (first
use this function)
src/G4OpenGLImmediateSceneHandler.cc:87: error: `glMultMatrixd'
undeclared
(first use this function)
src/G4OpenGLImmediateSceneHandler.cc: In member function `virtual void
G4OpenGLImmediateSceneHandler::EndPrimitives()':
src/G4OpenGLImmediateSceneHandler.cc:91: error: `glPopMatrix'
undeclared (first
use this function)
src/G4OpenGLImmediateSceneHandler.cc:93: error: `glFlush' undeclared
(first use
this function)
make[2]: ***
[/Users/paulvaska/geant4.5.2.p02/tmp/Darwin-g++/G4OpenGL/
G4OpenGLImmediateSceneHandler.o] Error 1
make[1]: *** [granular] Error 2
make libmap
and so on...
As instructed, I have the developers package (gcc 3.3) and X11
installed, and used finkcommander to install and compile clhep and
root3 (installing binaries failed perhaps due to a proxy problem?).
Also, I think have set my environment variables properly:
G4INSTALL=/Users/paulvaska/geant4.5.2.p02
GATEHOME=/Users/paulvaska/gate/gate_v1.0
G4SYSTEM=Darwin-g++
G4LIB=/Users/paulvaska/geant4.5.2.p02/lib
G4LEVELGAMMADATA=/Users/paulvaska/geant4.5.2.p02/data/PhotonEvaporation
G4RADIOACTIVEDATA=/Users/paulvaska/geant4.5.2.p02/data/RadiativeDecay
G4LEDATA=/Users/paulvaska/geant4.5.2.p02/../G4EMLOW2.2
NeutronHPCrossSections=/Users/paulvaska/geant4.5.2.p02/../G4NDL3.7
CLHEP_BASE_DIR=/sw
CLHEP_INCLUDE_DIR=/sw/include
CLHEP_LIB_DIR=/sw/lib
CLHEP_LIB=CLHEP
G4VIS_BUILD_OPENGLX_DRIVER=1
G4VIS_USE_OPENGLX=1
OGLHOME=/usr
G4LIB_USE_GRANULAR=1
G4WORKDIR=/Users/paulvaska/geant4
G4VERSION=5.2
ROOTSYS=/root
DYLD_LIBRARY_PATH=/sw/lib/root
LD_LIBRARY_PATH=/sw/lib/root
Any ideas from Mac users out there?
Thanks for your help!
Paul
Paul Vaska, Ph.D.
Medical Department, Building 490
Brookhaven National Laboratory
Upton, NY 11973
vaska at bnl.gov (631)344-6228 fax:(631)344-5311
More information about the Gate-users
mailing list