Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion core/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@ def build_extension(self, ext):
else:
cmake_args += ['-DCMAKE_CXX_FLAGS="-Wno-pedantic"']
cmake_args += ["-DCMAKE_BUILD_TYPE=" + cfg]
build_args += ["--", "-j4"]
jobs = os.environ.get("MAX_JOBS", "4")
build_args += ["--", f"-j{jobs}"]

env = os.environ.copy()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ Once it is done, you can compile ``opengate_core``.
pip install colored
cd <path-to-opengate>/core
export CMAKE_PREFIX_PATH=<path-to>/geant4.11-build/:<path-to>/itk-build/:${CMAKE_PREFIX_PATH}
export MAX_JOBS=$(nproc) # optional environment variable to set the number of parallel jobs for compilation
pip install -e . -v

The pip install will run cmake, compile the sources and create the
Expand Down
Loading