diff options
author | Sebastian Müller <gsenpo@gmail.com> | 2019-12-20 12:24:54 (GMT) |
---|---|---|
committer | Sebastian Müller <gsenpo@gmail.com> | 2019-12-21 14:38:00 (GMT) |
commit | 776d27d4a4eb27f5618e682dafc1d44fba8598c6 (patch) | |
tree | 671560defc90f6bec639982692c36dbe5cbebca7 /Tests/FindPython/VirtualEnv | |
parent | 9f75f9974f974611ab899675aa7bb987078e3b0d (diff) | |
download | CMake-776d27d4a4eb27f5618e682dafc1d44fba8598c6.zip CMake-776d27d4a4eb27f5618e682dafc1d44fba8598c6.tar.gz CMake-776d27d4a4eb27f5618e682dafc1d44fba8598c6.tar.bz2 |
FindPython: Extend virtual environment handling by considering conda
- Add functionality to recognize and use CONDA_PREFIX environment variable
- Add tests for conda virtual environments
- Fixes: #20111
Diffstat (limited to 'Tests/FindPython/VirtualEnv')
-rw-r--r-- | Tests/FindPython/VirtualEnv/CMakeLists.txt | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Tests/FindPython/VirtualEnv/CMakeLists.txt b/Tests/FindPython/VirtualEnv/CMakeLists.txt index 64ba201..9e8c673 100644 --- a/Tests/FindPython/VirtualEnv/CMakeLists.txt +++ b/Tests/FindPython/VirtualEnv/CMakeLists.txt @@ -21,22 +21,26 @@ endif() add_test(NAME FindPython3.VirtualEnvDefault COMMAND "${CMAKE_COMMAND}" -E env --unset=PYTHONHOME + --unset=CONDA_PREFIX "VIRTUAL_ENV=${Python3_VIRTUAL_ENV}" "${CMAKE_COMMAND}" "-DPYTHON3_VIRTUAL_ENV=${Python3_VIRTUAL_ENV}" -P "${CMAKE_CURRENT_LIST_DIR}/VirtualEnvDefault.cmake") add_test(NAME FindPython3.VirtualEnvOnly COMMAND "${CMAKE_COMMAND}" -E env --unset=PYTHONHOME + --unset=CONDA_PREFIX "VIRTUAL_ENV=${Python3_VIRTUAL_ENV}" "${CMAKE_COMMAND}" "-DPYTHON3_VIRTUAL_ENV=${Python3_VIRTUAL_ENV}" -P "${CMAKE_CURRENT_LIST_DIR}/VirtualEnvOnly.cmake") add_test(NAME FindPython3.UnsetVirtualEnvOnly COMMAND "${CMAKE_COMMAND}" -E env --unset=PYTHONHOME --unset=VIRTUAL_ENV + --unset=CONDA_PREFIX "${CMAKE_COMMAND}" -P "${CMAKE_CURRENT_LIST_DIR}/VirtualEnvOnly.cmake") add_test(NAME FindPython3.VirtualEnvStandard COMMAND "${CMAKE_COMMAND}" -E env --unset=PYTHONHOME + --unset=CONDA_PREFIX "VIRTUAL_ENV=${Python3_VIRTUAL_ENV}" "${CMAKE_COMMAND}" "-DPYTHON3_VIRTUAL_ENV=${Python3_VIRTUAL_ENV}" -P "${CMAKE_CURRENT_LIST_DIR}/VirtualEnvStandard.cmake") |