Skip to content
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

Remove sip dependencies for macOS #268

Conversation

srmainwaring
Copy link
Contributor

This PR removes the dependency on qt_gui_cpp_sip when running macOS.

Partial fix for ros-visualization/python_qt_binding#103. See also ros-visualization/python_qt_binding#118 which is a pre-requisite for this change.

Qt bindings for macOS are available using PySide2. The brew formula for pyside@2 is keg only, to build and run using PySide2 set the environment variables:

export CMAKE_PREFIX_PATH=/usr/local/opt/pyside@2:$CMAKE_PREFIX_PATH
export PATH=/usr/local/opt/pyside@2/bin:$PATH
export PYTHONPATH=$PYTHONPATH:/usr/local/opt/pyside@2/lib/python3.10/site-packages

The changes to qt_gui_cpp_shiboken address include path resolution issues that caused the build to fail. The modification for the qt_gui_cpp_INCLUDE_PATH is not very satisfactory. Using the component properties Qt5Core_INCLUDE_DIRS etc. which would be preferable does not seem to work.

- Remove sip and customise shiboken install for macOS

Signed-off-by: Rhys Mainwaring <rhys.mainwaring@me.com>
Signed-off-by: Rhys Mainwaring <rhys.mainwaring@me.com>
@mjcarroll mjcarroll merged commit b5b9e87 into ros-visualization:rolling Mar 1, 2023
@cottsay
Copy link
Member

cottsay commented Mar 2, 2023

This change regressed the RHEL builds (I'm more confident this time). The Shiboken CMake helper script calls find_package(PythonLibs). This change defines PYTHON_LIBRARY and PYTHON_INCLUDE_DIR, which seem to interfere with that resulting in:

-- Could NOT find PythonLibs (missing: PYTHON_LIBRARIES) (found suitable version "3.9.14", minimum required is "3.9")
-- Shiboken binding generator NOT available.

mjcarroll added a commit that referenced this pull request Mar 2, 2023
mjcarroll added a commit that referenced this pull request Mar 2, 2023
@mjcarroll
Copy link
Contributor

I went ahead and reverted to be safe. I will re-work this to make sure that rhel isn't impacted. Thanks for catching it.

@srmainwaring srmainwaring deleted the srmainwaring/humble-devel-macos branch March 4, 2024 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants