-
Notifications
You must be signed in to change notification settings - Fork 469
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
Fix shared library rpath once for all #7096
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/7096
Note: Links to docs will display an error until the docs builds have been completed. ❌ 1 Cancelled JobAs of commit 8b55993 with merge base 2a292c3 ( CANCELLED JOB - The following job was cancelled. Please retry:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
kirklandsign
approved these changes
Nov 26, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
That's much cleaner! |
larryliu0820
added a commit
that referenced
this pull request
Dec 3, 2024
Summary: This is a followup to #7096. That PR was aiming to rely on `CMAKE_INSTALL_RPATH_USE_LINK_PATH` to set RPATH automatically. However due to the caveat that we are not installing `_portable_lib.so` into the correct path in CMake stage (we move the .so in setup.py after it's installed), we are not able to add the correct RPATH to libcustom_ops_aot_lib.so. This PR still set the INSTALL_RPATH manually and adds TODOs to fix it later. Test Plan: Reviewers: Subscribers: Tasks: Tags:
larryliu0820
added a commit
that referenced
this pull request
Dec 3, 2024
* [pybind] Fix rpath for custom ops Summary: This is a followup to #7096. That PR was aiming to rely on `CMAKE_INSTALL_RPATH_USE_LINK_PATH` to set RPATH automatically. However due to the caveat that we are not installing `_portable_lib.so` into the correct path in CMake stage (we move the .so in setup.py after it's installed), we are not able to add the correct RPATH to libcustom_ops_aot_lib.so. This PR still set the INSTALL_RPATH manually and adds TODOs to fix it later. Test Plan: Reviewers: Subscribers: Tasks: Tags: * Remove typo Summary: Test Plan: Reviewers: Subscribers: Tasks: Tags:
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
ciflow/binaries/all
Release PRs with this label will build wheels for all python versions
ciflow/binaries
ciflow/trunk
CLA Signed
This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
topic: not user facing
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary:
Fixes #7086
Based on this wiki:
https://gitlab.kitware.com/cmake/community/-/wikis/doc/cmake/RPATH-handling
Takeaway of reading this doc:
CMAKE_BUILD_WITH_INSTALL_RPATH
to False so that we don't add install path (pip-out
,cmake-out
) into RPATH.CMAKE_INSTALL_RPATH
to be able to refer to libraries in the same install directory if any.CMAKE_INSTALL_RPATH_USE_LINK_PATH
to True so that we include other so files outside of the build tree can be added to RPATH.Test Plan:
Tested on Colab:
Reviewers:
Subscribers:
Tasks:
Tags:
Summary
[PLEASE REMOVE] See CONTRIBUTING.md's Pull Requests for ExecuTorch PR guidelines.
[PLEASE REMOVE] If this PR closes an issue, please add a
Fixes #<issue-id>
line.[PLEASE REMOVE] If this PR introduces a fix or feature that should be the upcoming release notes, please add a "Release notes: " label. For a list of available release notes labels, check out CONTRIBUTING.md's Pull Requests.
Test plan
[PLEASE REMOVE] How did you test this PR? Please write down any manual commands you used and note down tests that you have written if applicable.