Skip to content

Commit

Permalink
add python_install_package as ccmake option, adapt example test
Browse files Browse the repository at this point in the history
  • Loading branch information
JulienDoerner committed Feb 22, 2024
1 parent 3498d82 commit 76fef90
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/test_examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
run: |
mkdir build
cd build
cmake .. -DCMAKE_INSTALL_PREFIX=$HOME/.local -DENABLE_PYTHON=True -DPython_EXECUTABLE=${{ matrix.config.py }} -DENABLE_TESTING=Off -DENABLE_SWIG_BUILTIN=${{ matrix.config.swig_builtin }} -DSIMD_EXTENSIONS=native
cmake .. -DCMAKE_INSTALL_PREFIX=$HOME/.local -DENABLE_PYTHON=True -DPython_EXECUTABLE=${{ matrix.config.py }} -DENABLE_TESTING=Off -DENABLE_SWIG_BUILTIN=${{ matrix.config.swig_builtin }} -DSIMD_EXTENSIONS=native -DPython_INSTALL_PACKAGE_DIR=/home/runner/.local/
- name: Build CRPropa
run: |
cd build
Expand Down
4 changes: 1 addition & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -466,9 +466,7 @@ if(ENABLE_PYTHON AND Python_FOUND)


# use Python_INSTALL_PACKAGE_DIR if provided; otherwise, install in Python_SITELIB
if(NOT DEFINED Python_INSTALL_PACKAGE_DIR)
set(Python_INSTALL_PACKAGE_DIR "${Python_SITELIB}")
endif(NOT DEFINED Python_INSTALL_PACKAGE_DIR)
set(Python_INSTALL_PACKAGE_DIR "${Python_SITELIB}" CACHE PATH "folder in which the python package is installed")
message(STATUS " package install directory: ${Python_INSTALL_PACKAGE_DIR}")


Expand Down

0 comments on commit 76fef90

Please sign in to comment.