Skip to content
Snippets Groups Projects
Commit 89704795 authored by Benjamin Morgan's avatar Benjamin Morgan
Browse files

Enable SHARED and STATIC build of single library

Rephrase option to BUILD_SINGLE_LIB to reflect ability to build both
types of library.

Build static object libraries with standard options so they are non-PIC
by default. Change single library name to "geant4_{shared,static}" for
clarity.

Bump minimum required CMake version to 3.12 in order to allow
direct linking between OBJECT libraries. From 10.6 Geant4 passes all
usage requirements through target properties. This version bump allows
a significant simplification to the single library build and reuses all
internal/external dependency knowledge already in the Geant4 scripts.

Should ATLAS need to support CMake < 3.12, then additional logic would
be required in G4SingleLibrary.cmake to track and extract include
directories etc from the external library targets used (e.g. CLHEP).

Update Geant4Config.cmake template to use single libraries when built.
As with modular libraries, the shared/static variants can be chosen to
fill Geant4_LIBRARIES using the "static" component.
parent 5ef1f877
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment