-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Support overriding debuggable in AndroidManifest #13801
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
Support overriding debuggable in AndroidManifest #13801
Conversation
|
The way that the final "debuggable" value gets determined currently and with this change was fiddly enough that I made some tables. (I mostly reasoned about this in my head looking through the code, so it might not be perfect.) Current:
With this change:
(X = "don't care") So the first thing is that it seems more difficult to reason about what's going on with this change, because there are more cases to think about. The second is that it might not be trivial to release this change internally at Google, because I'm finding apps that might be affected by this (e.g., they have I think what would be preferable is to add a flag that just takes It would also be possible to make this configurable on the command line: |
|
If there's still any interest in pursuing this, happy to reopen. |
|
@ahumesky Had a chat w Corbin about this actually. bazelbuild/rules_android#238 (comment) Copy pasting the original for convenience.
|
Background
I would like to add
debuggable="false"into theAndroidManifest.xml, but specifying this directly in theAndroidManifest.xmldoes not take affect as--debug-modeis passed intoaapt2which overrides what developers set. refThe only way to get a debuggable apk is to require
--compilation-mode optwhich will invalidate the entire dep graph which is not feasible for large apps.#2575
Changes
debuggable: "false"is specified inmanifestValuesof theandroid_binarytarget do not set--debug-mode trueduring resource processor stepUsage