-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
objc_import missing data argument #17018
Comments
+1 on the utility of this [As food for thought: Might it just make sense to mostly unify these rules?] |
(objc_import is starlarkified, right? Perhaps that makes this a good time... I started to look into, but wasn't sure how the data attrs were getting gathered up into providers in the cc_import equivalent--perhaps they're traversed with an aspect?--nor what the |
As far as how data is used in apple targets that is from an aspect in rules_apple, so I would try adding the same attr as objc_library (this one
|
Thanks Keith! Gave that a quick whirl, but the data don't get picked up and bundled as they would with objc_library. Any ideas? (Figured I had comparative advantage if it were easy, given a real world test case, and already knowing how to use |
Got it. Looks like resources.collect no-ops gracefully if the attrdoesn't exist--so that change is our first move. Should I be concerned also about, e.g., cc_binaries failing to collect the data? (I was surprised to see these not getting passed up e.g. via some cc provider.) |
Lays the groundwork for bazelbuild/bazel#17018
It does still does seem like objc_import is so very close to being able to just be implemented as a facade around objc_library. objc_library would just need to be able to take .a files, like cc_library. |
@keith, tossing up a quick PR per your suggestion in bazelbuild/bazel#17018 (comment) to lay the groundwork
Prerequisite change merged into rules_apple today. Added the core change in #20716 (have ofc verified that they work together.) |
Description of the feature request:
Hi wonderful Bazel folks,
This is a feature request.
I'd noticed that objc_import--unlike most other cc rules(cc_import, cc_library, objc_library)--doesn't allow you to specify data.
I think objc_import should be equivalent to objc_library. It's so weird that objc_import does not support the data argument.
What underlying problem are you trying to solve with this feature?
I'm using a .a file with some resources. When I specify data to objc_import, bazel told me: no such attribute 'data' in 'objc_import' rule.
Which operating system are you running Bazel on?
macOS 12.6
What is the output of
bazel info release
?release 6.0.0rc4
If
bazel info release
returnsdevelopment 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 master; git rev-parse HEAD
?Have you found anything relevant by searching the web?
Yes.
Just found objc_import missing deps argument.
This issue only mentioned deps arguments, but no mention for data arguments.
Any other information, logs, or outputs that you want to share?
No response
The text was updated successfully, but these errors were encountered: