Skip to content
This repository was archived by the owner on May 31, 2025. It is now read-only.

[Windows] make more relocatable wrapper - #1086

Merged
dirk-thomas merged 4 commits into
ros:noetic-develfrom
seanyen:seanyen/relocatable_wrapper
May 20, 2020
Merged

dirk-thomas merged 4 commits into
ros:noetic-develfrom
seanyen:seanyen/relocatable_wrapper

Conversation

@seanyen

@seanyen seanyen commented May 8, 2020

Copy link
Copy Markdown
Contributor

This pull request is to remove a compile time variable dependency to @PYTHON_EXECUTABLE@ variable. This is motivated by trying to relocate an existing ROS installation to a different location in Windows, where one can either use tool (e.g., conda) or its own script to patch the hard-coded paths for the plain-text files (e.g., python scripts, CMake files, pkg-config files, etc.)

However, it is challenging to patch the string literal baked in binary files. So I turned to see why it is not an issue for setuptools wrapper. By reading the launcher code, I realized that it reads the SHEBANG line and use it as the hint of Python runtime location, and fallback to simply use Python.exe if none is specified or found. By this approach, the binary doesn't have the dependency to the compile time variable, and we can be more close to make catkin installation relocatable (at least with existing tools' help).

@dirk-thomas

dirk-thomas commented May 8, 2020 •

Copy link
Copy Markdown
Member

Please target the default branch with any changes.

@seanyen
seanyen force-pushed the seanyen/relocatable_wrapper branch from a11153e to 3620f4e Compare May 8, 2020 21:36
@seanyen
seanyen changed the base branch from kinetic-devel to noetic-devel May 8, 2020 21:37
@seanyen

seanyen commented May 8, 2020

Copy link
Copy Markdown
Contributor Author

Done. Btw, a little bit off-topic, are you open to add GitHub workflow to run the basic Windows CI for catkin? I can work on that.

@dirk-thomas dirk-thomas changed the title [Windows][kinetic] Make more relocatable wrapper. [Windows] make more relocatable wrapper May 8, 2020
@seanyen

seanyen commented May 8, 2020

Copy link
Copy Markdown
Contributor Author

Thanks for the feedback. The new iteration is ready for review.

@seanyen
seanyen force-pushed the seanyen/relocatable_wrapper branch from f5d5431 to c71c042 Compare May 20, 2020 21:02
@dirk-thomas

Copy link
Copy Markdown
Member

Thanks for the patch.

@dirk-thomas
dirk-thomas merged commit e1dff19 into ros:noetic-devel May 20, 2020
@seanyen
seanyen deleted the seanyen/relocatable_wrapper branch May 20, 2020 22:14
@seanyen

seanyen commented May 20, 2020

Copy link
Copy Markdown
Contributor Author

@dirk-thomas Thanks for the merge! And it would be great this can be cherry-picked to kinetic-devel too.

dirk-thomas pushed a commit that referenced this pull request May 21, 2020
* relocatable wrapper.

* address the feedback.

* address the feedback.

* correct the usage.
@dirk-thomas

Copy link
Copy Markdown
Member

Cherry-picked to kinetic-devel in cfbfe87.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants