Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[cmake] Respect Python virtualenv on macOS
Fix issue where CMake ignores the Python interpreter specified by a virtual environment by default. This results in the generate targets failing when the Python package requirements are installed in a virtual environment but the system interpreter is found by CMake. This patch replaces the use of `CMAKE_FIND_FRAMEWORK` with the more precise `Python3_FIND_FRAMEWORK`. It also sets the `Python3_FIND_STRATEGY` to `LOCATION` which stops searching once the first Python interpreter is found, i.e. the interpreter from an activated virtual environment, or the system interpreter otherwise.
- Loading branch information