-
Notifications
You must be signed in to change notification settings - Fork 244
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
cmake_external target can be included as data
of go_test
, but not sh_binary
#619
Comments
You pushed a branch to twitter? 😅 |
At first glance, it seems like we're doing all the right things in gathering runfiles I can look closer if I see your branch. But I also suspect this might be a bug in |
Sorry, I am a fool 💀 The branch is here: https://github.com/rickystewart/cockroach/tree/fulllint |
I can also try to get a smaller repro for you if necessary. |
Yeah, if you have time to put together a small repro that'd be helpful. I found bazelbuild/bazel#12348 but need more time to dig deeper and having something straight forward to test would make this easier 😄 |
Oh, it seems like cocroachdb is using a fork of Which might not handle runfiles correctly based on some notes here: |
Ah, that does seem to be the case. We might be able to bump to an actual |
I tried that, but unfortunately even the latest
|
Could you try this? diff --git a/BUILD b/BUILD
index ac395ef..c17da83 100644
--- a/BUILD
+++ b/BUILD
@@ -15,7 +15,7 @@ cmake_external(
"cp -r $EXT_BUILD_ROOT/external/libroach/include libroach",
],
static_libraries = ["libroach.a"],
- tools_deps = [
+ data = [
"@libroach//:all",
],
visibility = ["//visibility:public"], |
That results in the
|
Gentle ping on this -- even a workaround would be great :) |
Ah -- looks like funneling the dependency through a no-op intermediary filegroup does the trick as a workaround :p
|
This issue has been automatically marked as stale because it has not had any activity for 180 days. It will be closed if no further activity occurs in 30 days. Collaborators can add an assignee to keep this open indefinitely. Thanks for your contributions to rules_foreign_cc! |
This issue was automatically closed because it went 30 days without a reply since it was labeled "Can Close?" |
I've pushed a branch demonstrating this behavior here.
The target
//c-deps:libgeos
is acmake_external
library that we are able to successfully depend on in thedata
attribute of ago_test
rule:... and indeed,
libgeos
is there in therunfiles
for the test:... but a
sh_binary
(target//build/bazelutil:lint
) depending on the same target doesn't also capture the library in itsrunfiles
:The text was updated successfully, but these errors were encountered: