...
- Download the source from the G4 website
- ungzip and untar the source using GNU's gzip and tar for windows
- Start up a DOS command window
- Run C:\Program Files\Microsoft Visual Studio 9\Common\Tools\vsvars32.bat
- Start up cmake-gui
- Point "Where is the source code" at the G4 source
- Create a separate build directory and point "Where to build binaries" at that location
- Click Configure - you will likely get errors
- Location of CLHEP needs to be set up
- Click "Add Entry" CLHEP_INCLUDE_DIR, type "PATH", and point to the location of the include files.
- It is not clear if CLHEP_INCLUDE_DIRS is the new term, so I also define this as well.
- Click "Add Entry" CLHEP_LIBRARIES, type FilePATH and point to the actual CLHEP.lib file
- Do the same for CLHEP_LIBRARY as it is also not clear if this is needed as well.
- Click "Add Entry" and define CLHEP_ROOT_DIR as PATH
- Click "Add Entry" and define CLHEP_VERSION_OK as a BOOL and check it (this seems to be a bug, it seems we shouldn't have to do this)
- Click "Add Entry" and define GEANT4_USE_SYSTEM_CLHEP as BOOL and check
- Click "Add Entry" and define CMAKE_INSTALL_PREFIX as PATH and point it to the location you desire for the G4 installed binaries.
- There doesn't seem to be a way to set G4VERBOSE or not via CMake
- Click Configure again
- actually looks like CLHEP_INCLUDE_DIR, CLHEP_LIBRARY, CLHEP_ROOT_DIR, and GEANT4_USE_SYSTEM_CLHEP are not needed
- Click Generate
- Open the solution file in Visual Studio
- Update all the static library projects to use /MDd for the multi-threaded debug library (there doesn't seem to be a way to set that via CMake in this version of G4)
http://hypernews.slac.stanford.edu:5090/HyperNews/geant4/get/installconfig/1436/1.html - Choose ALL_BUILD and build
- Choose Install and build
...