欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  科技

解决Mono For Android不能编译问题:Could not create the Android package

程序员文章站 2023-11-24 14:08:52
解决Mono For Android不能编译问题:Could not create the Android package...
最近一直在用xamarin mono for android,因为国内的资料太少,所以很多问题都需要自己动手去弄清除。前几天,很多群友反映了不能打包(或debug)apk文件的问题,提示是这样的,错误:could not create the android package. see the output (build) window for more details.

mono for android !错误:could not create the android package. see the output (build) window for more details.

吾乐吧软件站提醒大家,解决方法:

可能性1:可能是你的vs创建的项目路径含有中文或其他杂乱数据,建议直接创建在 d:\ 试试!!

2014年9月9日补充说明:

可能性2:错误详情里面有这么一句话:找不到d:\program files\android\android-sdk\tools\\zipalign.exe
直接去这个目录 d:\program files\android\android-sdk\build-tools\20.0.0\zipalign.exe
ps:上面路径中的20.0.0,换成你本地相应的路径,反正有zipalign.exe就可以
拷贝zipalign.exe到d:\program files\android\android-sdk\tools\zipalign.exe,然后重启vs,接着重新编译就可以了

2013年4月20日补充说明:

deployment failed because of an internal error: failure [install_failed_invalid_uri]

如果大家发现,路径没有中文目录、特殊字符,但还是不能打包编译,可能是因为你的apk文件已经生成了,但是被其他程序占用(例如:你用腾讯手机管家正在使用你的apk文件),请结束其他的程序,确定没有被占用,这样就可以顺利打包编译了。