PYTHON_SOABI returns a host version of SOABI while cross-compiling
@nuclearsandwich is already working on this.
Since May 15, 2020.
- Dominant language
- EmberScript
- Stars
- 26
- Forks
- 68
- Avg merge
- 2d 13h
- Merged PRs (30d)
- 1
Description
Bug report
Required Info:
- Operating System:
- host: Ubuntu 18.04
- target: VxWorks 7
- Installation type:
- source compilation
- Version or commit hash:
- dashing release
- DDS implementation:
- N/A
- Client library (if applicable):
- N/A
Steps to reproduce issue
While cross-compiling the ROS2 dashing release for VxWorks and encounter the following problem
FindPythonExtra.cmake gives back a host PYTHON_SOABI instead of a target one.
It runs get_config_var('SOABI') using native python
"from sysconfig import get_config_var"
"print(get_config_var('SOABI'))"
After that all python ROS2 modules are built with the host extension and not loadable on the target system.
build: _rclpy.cpython-38-x86_64-linux-gnu.so
expected: _rclpy.cpython-38-vxworks.so
Expected behavior
It should give back a target SOABI, not the host one.
Probably a bit more sophisticated check shall be implemented, e.g. run a target version of
python3-config --extension-suffix
Actual behavior
always returns the host python SOABI version
Additional information
It is possible to define -DPYTHON_SOABI="my SOABI" to workaround it.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.