4.4.  Building Test Applications Against Your Development Build

A key feature of developing Geant4 with CMake is that you do not need to install your current build to be able to use it. A typical use case here is that you have a simple application which you want to build against your current development build of Geant4 for testing.

Versions of the geant4cmake.(c)sh (described in Section 3.2.1), Geant4Config.cmake (described in Section 3.2.2) and geant4-config (described in Section 3.2.3) scripts are created in the build directory. Each of these are configured to use the libraries as they exist in the build directory, and headers from the source directory, without installation.

You can therefore use these scripts as described earlier in Chapter 3 to build your test applications against a specific build tree. You therefore don't need to install Geant4 everytime you make a small update.