不能设置可调试标志在AndroidManifest.xml中 [英] Can not set debuggable flag in AndroidManifest.xml

查看:2534
本文介绍了不能设置可调试标志在AndroidManifest.xml中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尽量做到本教程了解调试NDK的应用程序,但是当我设置机器人:可调试=真正的在AndroidManifest.xml文件中出现以下错误:

I try to accomplish this tutorial to learn debugging NDK apps, but when I set android:debuggable="true" in AndroidManifest.xml file the following error occurs:

避免硬编码调试模式;离开它允许调试和   发布版本自动分配一个

Avoid hardcoding the debug mode; leaving it out allows debug and release builds to automatically assign one

如何解决它能够调试紫砂壶的应用程序?

How to solve it to be able to debug Teapot app?

推荐答案

SDK工具的官方文档< /一>,修订8(2010年12月)

See official doc for SDK Tools, Revision 8 (December 2010)

支持真正的调试版本。开发人员不再需要添加   的android:可调试属性添加到&lt;应用&gt;在清单标签    - 构建工具会自动添加属性。在的Eclipse / ADT ,所有   增量构建被认为是调试版本,所以工具插入   机器人:可调试=真正的。当导出一个签名的发布版本中,   工具不会增加属性。在蚂蚁,蚂蚁一调试命令   自动插入机器人:可调试=真正的属性,而   蚂蚁版本不。如果机器人:可调试=真正的手动设置,   那么蚂蚁释放将实际做调试版本,而不是发行   构建。

Support for a true debug build. Developers no longer need to add the android:debuggable attribute to the <application> tag in the manifest — the build tools add the attribute automatically. In Eclipse/ADT, all incremental builds are assumed to be debug builds, so the tools insert android:debuggable="true". When exporting a signed release build, the tools do not add the attribute. In Ant, a ant debug command automatically inserts the android:debuggable="true" attribute, while ant release does not. If android:debuggable="true" is manually set, then ant release will actually do a debug build, rather than a release build.

更新

如果你真的想禁用检查调试的标志,在Eclipse中,你下一步应该做的:

If you really want to disable checking for debuggable flag in Eclipse you should do next:

  1. 转到项目preferences
  2. 选择 Android的皮棉preferences
  3. 找到的硬codedDebugMode 标识在安全部分,然后选择它
  4. 更改严重性警告作为例子。
  5. 价值
  6. 应用确定
  1. Go to the Project Preferences:
  2. Select Android Lint Preferences
  3. Find HardcodedDebugMode Id in Security section and select it
  4. Change the value of Severity to Warning for example.
  5. Apply and Ok.

屏幕的详细信息:

Screen for details:

这篇关于不能设置可调试标志在AndroidManifest.xml中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆