设置android:installLocation ="preferExternal"时出错

Fug*_*ugo 9 installation android adb

当我像这样设置Manifest.xml文件时

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
  package="com.fugo.Rocket"
  android:versionCode="1"
  android:versionName="1.0"
  android:installLocation="preferExternal">
Run Code Online (Sandbox Code Playgroud)

android安装会出错

[2011-03-24十八点18分47秒 - 火箭项目]安装错误:INSTALL_FAILED_CONTAINER_ERROR [2011-03-24十八点18分47秒 - 火箭项目]请检查logcat的输出获取更多信息.[2011-03-24 18:18:47 - 火箭项目]发射取消!

但是当我设置android:intallLocation ="auto"

安装成功.这是为什么?

logcat错误

03-24 18:48:38.784:ERROR/PackageHelper(1284):无法创建安全容器smdl2tmp1 03-24 18:48:38.784:ERROR/DefContainer(1284):未能创建容器smdl2tmp1 03-24 18时48分: 38.784:ERROR/Vold(86):ASEC文件'/mnt/secure/asec/smdl2tmp1.asec'目前存在 - 首先销毁它!(地址已在使用中)

Ana*_*ath 6

检查你的minSDKversion设置为什么.此功能仅适用于FROYO.(SDK VERSION 8以后).

你还需要编译它并在Android2.2 sdk上运行

  • 值得注意的是,尽管该功能仅在SDK级别8之后可用,但它仍然可以在较低版本上运行,而只是忽略XML. (4认同)