Skip to content

Fix how to find Numpy headers for Windows debug #165

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

Closed
wants to merge 1 commit into from

Conversation

ivanpauno
Copy link
Member

Issue was introduced in #160.
Example issue: https://ci.ros2.org/view/nightly/job/nightly_win_deb/2357/console.

I'm honestly guessing, worst case I will restore the logic to find Numpy headers using before #160.

@ivanpauno ivanpauno added the bug Something isn't working label May 16, 2022
@ivanpauno ivanpauno self-assigned this May 16, 2022
@ivanpauno
Copy link
Member Author

  • Windows Build Status

@@ -21,6 +21,11 @@ find_package(PythonInterp 3.6 REQUIRED)

find_package(python_cmake_module REQUIRED)
find_package(PythonExtra MODULE REQUIRED)
set(_PYTHON_EXECUTABLE ${PYTHON_EXECUTABLE})
if(WIN32 AND "${CMAKE_BUILD_TYPE}" STREQUAL "Debug")
set(PYTHON_EXECUTABLE ${PYTHON_EXECUTABLE_DEBUG})
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd guess setting Python3_EXECUTABLE to PYTHON_EXECUTABLE_DEBUG before find_package(Python3 ...) would allow using the the debug version of NumPY on Windows

https://cmake.org/cmake/help/latest/module/FindPython3.html#artifacts-specification

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's exactly what I wanted to do, but I didn't do it correctly.

@ivanpauno
Copy link
Member Author

I will also fix this in #164, as managin two PRs is making things more complicated

@ivanpauno ivanpauno closed this May 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants