我怎样才能为Android蚂蚁调试版本指定调试密钥库的位置? [英] How can I specify location of debug keystore for Android ant debug builds?

查看:227
本文介绍了我怎样才能为Android蚂蚁调试版本指定调试密钥库的位置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有可能创建调试时指定一个自创建的调试密钥库的位置 .apk文件的(<项目名称> - debug.apk )使用蚂蚁调试?我只看到了可能性,以指定的发布密钥库的位置。

Is it possible to specify the location of a self created debug keystore when creating debug .apk's (<project-name>-debug.apk) with ant debug? I only see the possibility to specify the location of the release keystore.

我想没有将它们复制过的一个被放置在.android目录共享调试密钥存储在多台PC机。调试密钥库例如可以驻留在源$ C ​​$ C存储库中。但是,我需要一种方法来告诉Ant哪里可以找到调试密钥库。

I would like to share the debug keystore over multiple PC's without copying them over the the one that is placed in the '.android' directory. The debug keystore could for example reside within the source code repository. But I need a way to tell ant where to find the debug keystore.

推荐答案

您应该能够说明这些属性以使用密钥库

You should be able to specify the keystore to use with these properties

key.store=/path/to/key.keystore
key.alias=alias
key.store.password=pass
key.alias.password=pass

就在通过性能蚂蚁。

Just pass the properties in to Ant.

从文档的 http://developer.android.com/guide/publishing /app-signing.html#setup

在Android编译工具提供了调试签名模式,使您更容易开发和调试应用程序,同时还能满足Android系统的要求签署您的apk文件。当使用调试模式来构建应用程序,SDK工具调用keytool来自动创建一个调试密钥库和密钥。此调试键,然后用自动签名.apk文件,因此你不需要用自己的密钥签名的包。

The Android build tools provide a debug signing mode that makes it easier for you to develop and debug your application, while still meeting the Android system requirement for signing your .apk. When using debug mode to build your app, the SDK tools invoke Keytool to automatically create a debug keystore and key. This debug key is then used to automatically sign the .apk, so you do not need to sign the package with your own key.

SDK工具创建调试密钥库/密钥predetermined名/密码:

The SDK tools create the debug keystore/key with predetermined names/passwords:

  • 密钥库的名字:debug.keystore
  • 密钥库的密码:机器人
  • 密钥别名:androiddebugkey
  • 键密码:机器人
  • CN:CN = Android的调试,O =的Andr​​oid,C = US

如果需要,您可以更改调试密钥库/密钥的位置/名称或提供自定义的调试密钥库/键使用。然而,任何自定义的调试密钥库/密钥必须使用相同的密钥库/密钥名和密码作为默认的调试密钥(如上所述)。 (这样做在Eclipse / ADT,到Windows> preferences>安卓>生成。)

If necessary, you can change the location/name of the debug keystore/key or supply a custom debug keystore/key to use. However, any custom debug keystore/key must use the same keystore/key names and passwords as the default debug key (as described above). (To do so in Eclipse/ADT, go to Windows > Preferences > Android > Build.)

这篇关于我怎样才能为Android蚂蚁调试版本指定调试密钥库的位置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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