请先关注 [低调大师] 公众号 优秀的自媒体个人博客,低调大师,许军

低调大师

您现在的位置是:首页>文章详情

文章详情

xamarin.forms新建项目android编译错误

2016-08-02 44热度

vs2015 update3 新建的xamarin.forms项目中的android项目编译错误。提示缺少android_m2repository_r22.zip,96659D653BDE0FAEDB818170891F2BB0.zip等类似错误。

Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.Design\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.Design\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v4\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v4' available in SDK installer. Java library file C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v4\23.0.1.3\embedded\classes.jar doesn't exist. XamarinFormsExample.Droid  Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v4\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v4' available in SDK installer. Java library file C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v4\23.0.1.3\embedded\libs/internal_impl-23.0.1.jar doesn't exist. XamarinFormsExample.Droid  Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v4\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v4' available in SDK installer. Android resource directory C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v4\23.0.1.3\embedded\./ doesn't exist. XamarinFormsExample.Droid  Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.AppCompat\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v7.AppCompat' available in SDK installer. Java library file C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.AppCompat\23.0.1.3\embedded\classes.jar doesn't exist. XamarinFormsExample.Droid  Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.AppCompat\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v7.AppCompat' available in SDK installer. Android resource directory C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.AppCompat\23.0.1.3\embedded\./ doesn't exist. XamarinFormsExample.Droid  Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.CardView\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v7.CardView' available in SDK installer. Java library file C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.CardView\23.0.1.3\embedded\classes.jar doesn't exist. XamarinFormsExample.Droid  Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.CardView\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v7.CardView' available in SDK installer. Android resource directory C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.CardView\23.0.1.3\embedded\./ doesn't exist. XamarinFormsExample.Droid  Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.MediaRouter\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v7.MediaRouter' available in SDK installer. Java library file C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.MediaRouter\23.0.1.3\embedded\classes.jar doesn't exist. XamarinFormsExample.Droid  Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.MediaRouter\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v7.MediaRouter' available in SDK installer. Java library file C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.MediaRouter\23.0.1.3\embedded\libs/internal_impl-23.0.1.jar doesn't exist. XamarinFormsExample.Droid  Error Download failed. Please download https://dl-ssl.google.com/android/repository/android_m2repository_r22.zip and put it to the C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.MediaRouter\23.0.1.3 directory. XamarinFormsExample.Droid  Error Reason: One or more errors occurred. XamarinFormsExample.Droid Error Please install package: 'Xamarin.Android.Support.v7.MediaRouter' available in SDK installer. Android resource directory C:\Users\warrenbr\AppData\Local\Xamarin\Android.Support.v7.MediaRouter\23.0.1.3\embedded\./ doesn't exist. XamarinFormsExample.Droid
View Code

解决办法

  1. 删除文件夹 C:\Users\your user\AppData\Local\Xamarin
  2. 新建文件夹C:\Users\your user\AppData\Local\Xamarin\zips
  3. 将下载的zip文件copy到zips文件夹,下载地址和文件夹名称关系可参考 http://www.cnblogs.com/qinjin/p/m2repository.html
  4. 清理解决方案,然后重新生成即可

参考

解决Xamarin Android墙的问题

http://stackoverflow.com/questions/36616524/xamarin-support-package-error

http://forums.xamarin.com/discussion/61533/project-wont-build-xamarin-android-support

收藏 (0)

相关文章

    文章评论

    共有0条评论来说两句吧...