-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
bazel: add target_compatible_with to envoy_cc_library #22273
bazel: add target_compatible_with to envoy_cc_library #22273
Conversation
This would require pulling in grailbio/bazel-compilation-database#100 to actually solve #22217 |
This pull request has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in 7 days if no further activity occurs. Please feel free to give a status update now, ping for review, or re-open when it's ready. Thank you for your contributions! |
This attribute allows us to specify what constraints a library is compatible with, such as only usable on linux, or not windows etc. It is viral in that any targets that explicitly depend on it up the tree will respect those constraints, and not be built, unless they're specified explicitly on the command line, in which case bazel will fail instead. This helps us a fix a problem with the compilation database script where it virtually does `bazel build //...`, but some libraries don't build at all on some platforms. Theoretically we could also solve this case by marking those libraries as `manual`, but that would have other side effects in that they wouldn't be built on the platforms that they support either (unless they were somehow otherwise part of the dependency tree, since unlike this attribute, the `manual` tag is not viral). Signed-off-by: Keith Smiley <keithbsmiley@gmail.com>
4456707
to
1e72e3f
Compare
I think with the newest rolling release this should work without the change linked above |
This pull request has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in 7 days if no further activity occurs. Please feel free to give a status update now, ping for review, or re-open when it's ready. Thank you for your contributions! |
This pull request has been automatically closed because it has not had activity in the last 37 days. Please feel free to give a status update now, ping for review, or re-open when it's ready. Thank you for your contributions! |
This attribute allows us to specify what constraints a library is
compatible with, such as only usable on linux, or not windows etc. It
is viral in that any targets that explicitly depend on it up the tree
will respect those constraints, and not be built, unless they're
specified explicitly on the command line, in which case bazel will fail
instead. This helps us a fix a problem with the compilation database
script where it virtually does
bazel build //...
, but some librariesdon't build at all on some platforms. Theoretically we could also solve
this case by marking those libraries as
manual
, but that would haveother side effects in that they wouldn't be built on the platforms that
they support either (unless they were somehow otherwise part of the
dependency tree, since unlike this attribute, the
manual
tag is notviral).
Signed-off-by: Keith Smiley keithbsmiley@gmail.com