Fix build on systems where Pythia is not available
Compare changes
+ 27
− 27
@@ -85,33 +85,34 @@ if (Pythia8_FOUND)
@@ -123,7 +124,6 @@ target_link_libraries (stopping_power
IAP GITLAB
The build process was broken on systems that did not have Pythia8.
The vertical_EAS
example requires Pythia however the current CMake build process would still try to compile the example code even when Pythia was unavailable (resulting in a compile error). This MR explicitly adds the dependence on Pythia8 into the CMake configuration for the vertical air shower example (using an existing if (Pythia8-FOUND)
-block). This has been tested on systems with and without Pythia.
The README suggests that Pythia is an optional component - is the plan for Pythia to remain optional? If so, it would probably be good to create at least one CI task to build CORSIKA8 on a system without Pythia.