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

Allow passing labels for builtin_sysroot instead of string #21156

Open
shmuelamit opened this issue Jan 31, 2024 · 0 comments
Open

Allow passing labels for builtin_sysroot instead of string #21156

shmuelamit opened this issue Jan 31, 2024 · 0 comments
Labels
P3 We're not considering working on this, but happy to review a PR. (No assignee) team-Rules-CPP Issues for C++ rules type: feature request

Comments

@shmuelamit
Copy link

Description of the feature request:

For some non-obvious reason create_cc_toolchain_config_info gets the field builtin_sysroot as a string instead of as a label. This causes some major projects to use a hack in which they depend on the hard-coded path external/{target name} instead of a target label which imo will be a better approach. For example:

Which category does this issue belong to?

Rules API

What underlying problem are you trying to solve with this feature?

The fact that users of toolchains need to hard-code sysroot paths instead of using the natural approach which is labels.

Which operating system are you running Bazel on?

Rocky Linux

What is the output of bazel info release?

release 6.4.0

If bazel info release returns development version or (@non-git), tell us how you built Bazel.

No response

What's the output of git remote get-url origin; git rev-parse HEAD ?

No response

Have you found anything relevant by searching the web?

Stack overflow which shows how to use sysroot path
https://stackoverflow.com/questions/62451307/specify-sysroot-for-bazel-toolchain

My Slack thread
https://bazelbuild.slack.com/archives/CA31HN1T3/p1706711506150469

Any other information, logs, or outputs that you want to share?

No response

@iancha1992 iancha1992 added the team-Rules-CPP Issues for C++ rules label Jan 31, 2024
@comius comius added P3 We're not considering working on this, but happy to review a PR. (No assignee) and removed untriaged labels Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P3 We're not considering working on this, but happy to review a PR. (No assignee) team-Rules-CPP Issues for C++ rules type: feature request
Projects
None yet
Development

No branches or pull requests

5 participants