-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use FindPython from CMake 3.12. #180
Conversation
188d3f5
to
56b360f
Compare
This needs to be rebased after #199 is merged |
Per the CMake 3.27.0 release notes:
I should probably rebase this 😞 |
71b2f3e
to
9d48bc0
Compare
b48b258
to
9c9394c
Compare
This is ready to go for CMake 3.27 compatibility. |
The `distutils` module will be tossed in Python 3.12, so compensate for that.
install(TARGETS PyHSPlasma | ||
RUNTIME DESTINATION bin | ||
LIBRARY DESTINATION lib | ||
LIBRARY DESTINATION bin |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CMake's FindPython3 (source of Python3_add_library
) thinks Python extension modules are libraries. 🙄
To facilitate the writing of a vcpkg port, this updates the PyHSPlasma CMake to use the FindPython module from CMake 3.12. The previously used module has since been deprecated. To manually specify artifacts from a specific python version, set the keys
Python_INCLUDE_DIR
andPython_LIBRARY
. Note the casing has changed fromPYTHON
(deprecated) toPython
.I think these changes were previously included in #166, but the ability to manually specify the artifacts did not land until CMake 3.16.