Installation
Build Requirements
neomc currently builds with:
- a C++20 compiler;
- CMake 3.20 or newer.
Importer-backed workflows additionally require:
- HDF5 with the C component;
- Zlib.
Minimal Library-Only Build
Build the core libraries without importers or benchmark executables:
cmake -S . -B build \
-DNEOMC_BUILD_IMPORTERS=OFF \
-DNEOMC_BUILD_BENCHMARKS=OFF \
-DNEOMC_ENABLE_BENCHMARK_CHECKS=OFF
cmake --build build --parallelDefault Importer And Benchmark Build
The repository defaults are currently:
NEOMC_BUILD_IMPORTERS=ONNEOMC_BUILD_BENCHMARKS=ONNEOMC_ENABLE_BENCHMARK_CHECKS=ON
Example:
cmake -S . -B build
cmake --build build --parallelNEOMC_BUILD_BENCHMARKS cannot be enabled unless NEOMC_BUILD_IMPORTERS is also enabled.
Optional Geant4 reference executables are controlled separately with:
NEOMC_BUILD_GEANT4_BENCHMARKS=ON
Reference Data
Importer-backed benchmarks expect a local reference/ tree. The repository treats reference/ as a local, ignored area for upstream source and data files.
Typical benchmark executables pass reference directly as the first argument or through a --reference-root reference option, depending on the executable.
Common Build Modes
- Core-only library validation:
cmake -S . -B build \
-DNEOMC_BUILD_IMPORTERS=OFF \
-DNEOMC_BUILD_BENCHMARKS=OFF \
-DNEOMC_ENABLE_BENCHMARK_CHECKS=OFF- Importer and benchmark workflow:
cmake -S . -B build- Benchmark workflow with optional Geant4 reference executables:
cmake -S . -B build \
-DNEOMC_BUILD_GEANT4_BENCHMARKS=ONVerification
After building a benchmark-enabled configuration, run:
ctest --test-dir build --output-on-failureThis executes lightweight benchmark checks for the enabled benchmark targets.