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

{ros2} Add required ROS2 SDK environment variables #1261

Draft
wants to merge 177 commits into
base: master-next
Choose a base branch
from

Conversation

sgstreet
Copy link
Contributor

@sgstreet sgstreet commented Nov 20, 2024

This PR adds the following environment variable when the SDK is setup:

PYTHON_SOABI required to avoid setup failures with python packages
PYTHON3_NUMPY_INCLUDE_DIR required to using python opencv binding
PYTHONWARNINGS to suppress setuptool warmings
AMENT_SKIP_SHELL_PATH to prevent ament from prepending $OECORE_TARGET_SYSROOT/opt/ros/$ROS_DISTRO/bin to glocal PATH variable
PYTHONPATH to include the target site-packages to the python environment

If the Yocto enviroment variable ROS_SDK_UNIFY is not empty, $OECORE_TARGET_SYSROOT/opt/ros/$ROS_DISTRO/setup.bash or friends is source during SDK setup. The value of ROS_SDK_UNIFY should one of the following "sh", "bash" or "zsh"

@sgstreet sgstreet marked this pull request as draft November 25, 2024 22:13
@sgstreet
Copy link
Contributor Author

Still verifying this on master-next and styhead-next

@sgstreet
Copy link
Contributor Author

sgstreet commented Nov 25, 2024

@robwoolley I verify this by building examples, demos and example-interfaces with master-next and styhead-next. We still have the issue of PYTHON_SOABI verses _PYTHON_SYSCONFIGDATA_NAME. I have been unable to make the latter work.

Ensure that the previous value of PYTHONPATH is preserved when
the ROS opt prefix Python site-packages directory is added.

Signed-off-by: Rob Woolley <[email protected]>
The prefix-path file contains references to TMPDIR which causes
package QA warnings.  Disable the generation of the prefix-path files
as we presently are not using them to build on the target.

Signed-off-by: Rob Woolley <[email protected]>
Duplicate workaround in setuptools3_legacy.bbclass but
customized for the ROS opt prefix.

Resolves problems in setuptools3 packages which add a redundant
directory (eg. /opt/ros/rolling/share/ament_package/ament_package)

Substitute mv for cp and rm to avoid condition where mv failed
when there was an existing directory with the same name.

Signed-off-by: Rob Woolley <[email protected]>
Add libfyaml recipe needed as a dependency for mrpt2.

Signed-off-by: Rob Woolley <[email protected]>
The optional dependency on octomap is necessary for building moveit.

Signed-off-by: Rob Woolley <[email protected]>
Add new recipes for suitesparse, leaving the older recipes if needed
by older ROS 2 distros.

Update the WORKDIR variable for old recipes to use git directory name.

The suitesparse-cholmod and suitesparse-spqr recipes had incorrect
version numbers that were ahead of the latest versions.  Reset the
versions to correspond to CMakeLists.txt in the latest releases.

Signed-off-by: Rob Woolley <[email protected]>
This removes suitesparse-metis as it is reportedly broken in the latest
version of ceres-solver in meta-openembedded.

Signed-off-by: Rob Woolley <[email protected]>
Add new recipe for backward-ros and gz-tools2.

Signed-off-by: Rob Woolley <[email protected]>
Add new recipe as needed dependency for ipopt.

Signed-off-by: Rob Woolley <[email protected]>
New recipe required for libtiff, openexr, and gdal.

Signed-off-by: Rob Woolley <[email protected]>
Add gts recipe for gz-common5.

Signed-off-by: Rob Woolley <[email protected]>
Recipe was moved to meta-ros-common.

Signed-off-by: Rob Woolley <[email protected]>
robwoolley and others added 24 commits November 25, 2024 19:06
The gfortran compiler does not have a flag to remove the source file from
the output. We must ignore the QA issues instead.

Signed-off-by: Rob Woolley <[email protected]>
The GTSAM_SOURCE_TREE_DATASET_DIR is embedded as a default
search path inside the binaries produced. This is not relevant
when cross-compiling and causes a buildpath QA issue.

Remove the references to resolve the QA issue.

Signed-off-by: Rob Woolley <[email protected]>
@sgstreet
Copy link
Contributor Author

I have made a mess out of this, fixing now.

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.

8 participants