-
Notifications
You must be signed in to change notification settings - Fork 4k
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
java_library: Support manifest manipulation #4197
Comments
How would you do this prior to Bazel 0.8?
Why did you need to manipulate the manifest file? Can you describe how would this help you? Thanks! |
I'm on 0.8. For now I'm simply using a
It's certainly not a big deal. Coming from other build tools I was surprised that it's not possible with
Sure. The option would have to be named differently.
For deployment of an Eclipse plugin I need to add the necessary manifest information. I first tried to simply include the manifest with the input files. But Bazel either seems to override or not include the custom MANIFEST.MF file. I'm pretty sure I will need this feature in other projects as well.
Direct support would save me from using additional code and overhead unless I'm missing something. Thanks. |
Thanks for the information!
Yes, Bazel will just ignore your manifest. Bazel considers only I still don't understand why you need to add manifest information to the output jars of |
Thanks for the clarification. I was not aware of that distinction. Given the documentation for I've now tried
It's just a standard Eclipse plugin archive. It's for internal use only and will be dropped into the dropins folder of Eclipse. Just a bunch of .class files, the plugin.xml descriptor in the root directory and the META-INF/MANIFEST.MF with the required additions. |
Yes, the idea is to control only what goes into the
Why wouldn't you want the dependencies embedded? I'm not sure if there is a way not to include them. Maybe if you mark your java_library dependencies as |
That's why I initially thought
Thanks for the pointer. I think this will work. Thanks very much for your support! |
I'm new to Bazel and I was quite surprised that (as of Bazel 0.8) manipulating the
MANIFEST.MF
does not seem to be supported out-of-the-box with thejava_library
rule.With
java_binary
, we havedeploy_manifest_lines
. A similar option should be available forjava_library
as well.It's not a big deal once your are experienced, but as a total beginner it took some time to come up with a solution. But the added convenience would be nice anyway.
The text was updated successfully, but these errors were encountered: