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

cc_import system_provided still sets rpath #10190

Open
wesleyw72 opened this issue Nov 7, 2019 · 4 comments
Open

cc_import system_provided still sets rpath #10190

wesleyw72 opened this issue Nov 7, 2019 · 4 comments
Labels
not stale Issues or PRs that are inactive but not considered stale P4 This is either out of scope or we don't have bandwidth to review a PR. (No assignee) team-Rules-CPP Issues for C++ rules type: support / not a bug (process)

Comments

@wesleyw72
Copy link

wesleyw72 commented Nov 7, 2019

Description of the problem / feature request:

I have a cc_import with interface_library set and system_provided set to true. I'd expect a binary depending on this would show the library as NEEDED but not to add it to the RUNPATH of the binary. I'm however seeing it being added into the RUNPATH. Is this the intended behaviour?

@aiuto aiuto added team-Rules-CPP Issues for C++ rules untriaged labels Nov 7, 2019
@oquenchil oquenchil added P3 We're not considering working on this, but happy to review a PR. (No assignee) type: bug and removed untriaged labels Feb 18, 2020
@cdump
Copy link

cdump commented Nov 17, 2020

@wesleyw72 have you found a solution/workaround for this?

@oquenchil oquenchil added P4 This is either out of scope or we don't have bandwidth to review a PR. (No assignee) type: support / not a bug (process) and removed type: bug P3 We're not considering working on this, but happy to review a PR. (No assignee) labels Nov 19, 2020
@cdump
Copy link

cdump commented Dec 14, 2020

Paths for RPATH constructed in LibrariesToLinkCollector.java

I think we should add something like that:

if (input.getArtifactCategory() == ArtifactCategory.INTERFACE_LIBRARY && input.isInterfaceLibrarySystemProvided()) {
 // skip add to rpath. (isInterfaceLibrarySystemProvided not exists)
}

I've also found another possible bug - input's ArtifactCategory here is DYNAMIC_LIBRARY (not INTERFACE_LIBRARY) for cc_import(interface_library="",system_provided=true). That's why:

  1. CcImport.java:
  1. LibraryToLink.java
  1. LinkerInputs.java:

I don't know the "right" way to fix this issue and need some help from more experienced in bazel source code developers.

@sgowroji sgowroji added the stale Issues or PRs that are stale (no activity for 30 days) label Feb 10, 2023
@sgowroji
Copy link
Member

Hi there! We're doing a clean up of old issues and will be closing this one. Please reopen if you’d like to discuss anything further. We’ll respond as soon as we have the bandwidth/resources to do so.

@cdump
Copy link

cdump commented Feb 10, 2023

Hi! Problem (bug) still exists and fix/help wanted

@sgowroji sgowroji added not stale Issues or PRs that are inactive but not considered stale and removed stale Issues or PRs that are stale (no activity for 30 days) labels Feb 10, 2023
@sgowroji sgowroji reopened this Feb 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
not stale Issues or PRs that are inactive but not considered stale P4 This is either out of scope or we don't have bandwidth to review a PR. (No assignee) team-Rules-CPP Issues for C++ rules type: support / not a bug (process)
Projects
None yet
Development

No branches or pull requests

5 participants