Dependencie fail via kotlin compilation - android

I need to add this react-native-screens dependence into my app and when I run android build this dependence fails
> Task :react-native-screens:compileDebugKotlin FAILED
I am implementing a react-native app (as a module) into an existing native app. And this app is completely in Kotlin. I follow the official doc and all looks fine but this lib has some problem
this is the error that I have in the android studio:
e: /Users/lk/Docu....reens/RNScreensPackage.kt: (9, 1):
Class 'RNScreensPackage' is not abstract and does not implement abstract member public
abstract fun createJSModules(): (Mutable)List<Class<out JavaScriptModule!>!>!
defined in com.facebook.react.ReactPackage
and this is what i have when i run react-native run-android
> Task :react-native-screens:compileDebugKotlin FAILED
Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.
You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
See https://docs.gradle.org/7.3.3/userguide/command_line_interface.html#sec:command_line_warnings
50 actionable tasks: 16 executed, 34 up-to-date
e: /pathtoproject/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/RNScreensPackage.kt: (9, 1): Class 'RNScreensPackage' is not abstract and does not implement abstract member public abstract fun createJSModules(): (Mutable)List<Class<out JavaScriptModule!>!>! defined in com.facebook.react.ReactPackage
e: /pathtoproject/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/Screen.kt: (11, 34): Unresolved reference: GuardedRunnable
e: /pathtoproject/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/Screen.kt: (77, 13): Type mismatch: inferred type is <no name provided> but Runnable! was expected
e: /pathtoproject/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/Screen.kt: (77, 22): Unresolved reference: GuardedRunnable
e: /pathtoprojectnode_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/Screen.kt: (78, 17): 'runGuarded' overrides nothing
e: /Upathtoproject/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/Screen.kt: (81, 27): Unresolved reference: updateNodeSize
e: /pathtoproject/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenContainer.kt: (15, 40): Unresolved reference: ChoreographerCompat
...and more

Related

android studio unresolved reference

I try to run my app and get this errors
e: /Users/idanfadlon/Desktop/Law-Tech-App/app/src/main/java/com/example/law_tech_app/fragments/BaseFragment.kt: (11, 24): Unresolved reference: synthetic
2.e: /Users/idanfadlon/Desktop/Law-Tech-App/app/src/main/java/com/example/law_tech_app/fragments/BaseFragment.kt: (19, 25): Unresolved reference: tv_progress_text
3.e: /Users/idanfadlon/Desktop/Law-Tech-App/app/src/main/java/com/example/law_tech_app/fragments/BaseFragment.kt: (19, 42): Variable expected
the problem is in base activity file and I dont touch him
I try to pull project again from my repository

Android gradle build fails on ubuntu agents on ADO but compiles on Windows, macos

For a few days now I've been scratching my head at this.
I have a azure-pipeline yaml build using a gradle task in java 11, it's running on a macos MS hosted agent and build perfectly, however for performance and cost reasons we want to switch to ubuntu agents. When switching the build fails with the following error :
> Task :app:compileStagingDebugKotlin FAILED
e: /home/vsts/work/1/s/app/src/main/java/org/xxx/xxxxx/profile/contactInfo/xxxxFragment.kt: (305, 59): Unresolved reference: xxxxxxFragmentMenu
xxxxFragmentmenu being a reference to a navigation menu (androidx.navigation) (sorry i'm not an android developer).
The thing is that it is working if i use a windows agent as well as a macos one. The only notable difference i can see between the MS hosted agent capabilities is that the jdk version on ubuntu is a little behind for the v11
ubuntu : 11.0.14.1+1 (default)Eclipse Temurin JAVA_HOME_11_X64
macos & windows 2019 : 11.0.14+101 Eclipse Temurin JAVA_HOME_11_X64
I've also created a vm on ubuntu 20.0.4, installed android studio and was able to successfully compile the variant AssembleStagingDebug.
This variant is indeed being compiled on Windows and MacOs, below an example of successful compilation with macos.
> Task :app:compileStagingDebugKotlin
w: Flag is not supported by this version of the compiler: -Xallow-jvm-ir-dependencies
w: ATTENTION!
This build uses unsafe internal compiler arguments:
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/profile/documents/documentation/DocumentationViewModel.kt: (196, 25): Unchecked cast: Any? to List<TrustCategory>
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/profile/documents/documentation/DocumentationViewModel.kt: (265, 25): Unchecked cast: Any? to List<TrustDocumentInfo>
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/profile/documents/documentation/DocumentationViewModel.kt: (390, 25): Unchecked cast: Any? to List<TrustDocumentShared>
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/profile/documents/proofOfIdentity/ProofOfIdentityViewModel.kt: (65, 25): Unchecked cast: Any? to List<TrustPvid>
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/splash/FragmentSplash.kt: (67, 13): The expression is unused
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/LocaleUtil.kt: (22, 19): 'updateConfiguration(Configuration!, DisplayMetrics!): Unit' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/UriUtils.kt: (31, 34): Variable 'selection' initializer is redundant
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/UriUtils.kt: (32, 45): Variable 'selectionArgs' initializer is redundant
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/UriUtils.kt: (73, 60): 'getExternalStorageDirectory(): File!' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/UriUtils.kt: (220, 36): 'getExternalStorageDirectory(): File!' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/UriUtils.kt: (225, 20): Unsafe use of a nullable receiver of type String?
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/UriUtils.kt: (229, 20): Unsafe use of a nullable receiver of type String?
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/UriUtils.kt: (243, 17): Variable 'size' is never used
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/UriUtils.kt: (258, 28): Variable 'read' initializer is redundant
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtil.kt: (9, 24): 'CursorLoader' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtil.kt: (31, 52): 'DATA: String' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtil.kt: (34, 28): 'constructor CursorLoader(Context!, Uri!, Array<(out) String!>!, String!, Array<(out) String!>!, String!)' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtil.kt: (34, 28): 'CursorLoader' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtil.kt: (35, 35): 'loadInBackground(): Cursor!' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtil.kt: (38, 84): 'DATA: String' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtil.kt: (69, 40): 'getExternalStorageDirectory(): File!' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtil.kt: (77, 44): 'getExternalStorageDirectory(): File!' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtilExts.kt: (54, 73): 'DATA: String' is deprecated. Deprecated in Java
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/RealPathUtilExts.kt: (73, 71): Type mismatch: inferred type is String? but String was expected
w: /Users/runner/work/1/s/app/src/main/java/org/xxx/xxx/util/file/test/URIPathHelper.kt: (27, 40): 'getExternalStorageDirectory(): File!' is deprecated. Deprecated in Java
> Task :app:compileStagingDebugJavaWithJavac
To try to debug further and excluding the possibility that this was coming for the gradle task, i've also tried to compile through a bash script calling ./gradlew clean AssembleStagingDebug --scan which works locally but not on the ubuntu agent.
The android sdk is installed and available, we are using the 30.0.3, everything else seems the same.
What can cause this? We really want to get on Ubuntu agents.. Thanks in advance.
Edit:
I took a look at the generated files from the navigation graph xml file and in Azure DevOps ubuntu agent unlike when using macOs one navigation action node is not being generated...
I also tried to be the closest from the agent dev environment by using the same jdk and sdk as the ubuntu agent on Azure DevOps:
openjdk version "11.0.14.1" 2022-02-08
OpenJDK Runtime Environment Temurin-11.0.14.1+1 (build 11.0.14.1+1)
OpenJDK 64-Bit Server VM Temurin-11.0.14.1+1 (build 11.0.14.1+1, mixed mode)
javac 11.0.14.1
But still couldn't reproduce the same behavior locally.
Anyone with an idea on how to approach this now?
Edit 2:
I found the problem, it was due to the issue of duplicated fragments (same ids) with different definitions. on Windows and Ubuntu, contrary to macOs it seems that the generated files are not processed in the same order resulting on overwitten files that doesn't contain some of the actions. We've made a temporary fix to include the same definitions for all fragments sharing the same IDs. Now it works on all platforms.
I found the problem, it was due to the issue of duplicated fragments (same ids) with different definitions. on Windows and Ubuntu, contrary to macOs it seems that the generated files are not processed in the same order resulting on overwitten files that doesn't contain some of the actions. We've made a temporary fix to include the same definitions for all fragments sharing the same IDs. Now it works on all platforms.

Cannot build Flutter App (Android) after install wechat_assets_picker

I recently installed wechat_assets_picker, however when trying to build for android I get the following error, nothing in thier docs about it and no issues on thier issue list either.
e: /Users/remelehane/.pub-cache/hosted/pub.dartlang.org/photo_manager-0.6.0/android/src/main/kotlin/top/kikt/imagescanner/core/PhotoManagerDeleteManager.kt: (116, 36): Unresolved reference: R
e: /Users/remelehane/.pub-cache/hosted/pub.dartlang.org/photo_manager-0.6.0/android/src/main/kotlin/top/kikt/imagescanner/core/PhotoManagerDeleteManager.kt: (119, 36): Unresolved reference: createTrashRequest
e: /Users/remelehane/.pub-cache/hosted/pub.dartlang.org/photo_manager-0.6.0/android/src/main/kotlin/top/kikt/imagescanner/core/PhotoManagerPlugin.kt: (341, 84): Unresolved reference: R
e: /Users/remelehane/.pub-cache/hosted/pub.dartlang.org/photo_manager-0.6.0/android/src/main/kotlin/top/kikt/imagescanner/core/utils/Android30DbUtils.kt: (34, 34): Unresolved reference: R
e: /Users/remelehane/.pub-cache/hosted/pub.dartlang.org/photo_manager-0.6.0/android/src/main/kotlin/top/kikt/imagescanner/core/utils/IDBUtils.kt: (27, 67): Unresolved reference: R
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':photo_manager:compileReleaseKotlin'.
> Compilation error. See log for more details
The erroring line is #RequiresApi(Build.VERSION_CODES.R) which from what I understand means this function on runs in version R of the android SDK, which is OS11, so should not be affecting the build?
I checked with the example project which is running SDK min 21 and compiled of 29.
Mine is running 19 and 21, however changign to 21 did not get around the build error so there must be more to is than that?
TIA
The issue is as a result of the compiledSdkVersion being set to 29, it needs to be set to 30
Each time you upgrade your pubspecs, or run a pub upgrade, you need to run flutter clean. And it should solved. Specific to the photo_manager.

Android project in koltin fails when execute ./gradlew build in terminal but works when run from menu

I'm trying to work with Travis CI, and previously I have try to build my project in the Android Studio's terminal with ./gradlew build or with ./gradlew clean build but both throws "Execution failed for task ':presentation:compileReleaseKotlin'." however when I build my project from the Android Studio's toolbar it works perfectly.
You can see the whole stacktrace and all the information here gradle stacktrace
Thanks in advance,
Javi
Check your Constants class for errors.
e: /Users/jcamarero/AndroidStudioProjects/boton/presentation/src/main/java/com/b4motion/boton/utils/Constants.kt: (48, 31): Const 'val' initializer should be a constant value
e: /Users/jcamarero/AndroidStudioProjects/boton/presentation/src/main/java/com/b4motion/boton/utils/Constants.kt: (48, 46): Unresolved reference: URL_WEB_VIEW
e: /Users/jcamarero/AndroidStudioProjects/boton/presentation/src/main/java/com/b4motion/boton/utils/Constants.kt: (49, 29): Const 'val' initializer should be a constant value
e: /Users/jcamarero/AndroidStudioProjects/boton/presentation/src/main/java/com/b4motion/boton/utils/Constants.kt: (49, 44): Unresolved reference: URL_WEB_VIEW
This error says that you have a const val in your Constants class defined but it is not constant at compile time. Also, it cannot find reference to URL_WEB_VIEW.

Xamarin Forms Android Problems, package android.support.design.* does not exist

I have a Xamarin.Forms Project in which i can not get Android to build, as a matter of fact even a brand new project i have the same problems Android fails out with tons and tons of errors. I have installed and reinstalled Android SDK, Java, and made sure all thats in the Android SDK is installed, still no go.
Severity Code Description Project File Line Suppression State
Error error: package android.support.design.widget.TabLayout does not exist
android.support.design.widget.TabLayout.OnTabSelectedListener, MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\md5270abb39e60627f0f200893b490a1ade\TabbedPageRenderer.java 8
Error error: package android.support.design.widget.TabLayout does not exist
public void onTabReselected (android.support.design.widget.TabLayout.Tab p0) MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\md5270abb39e60627f0f200893b490a1ade\TabbedPageRenderer.java 76
Error error: package android.support.design.widget.TabLayout does not exist
private native void n_onTabReselected (android.support.design.widget.TabLayout.Tab p0); MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\md5270abb39e60627f0f200893b490a1ade\TabbedPageRenderer.java 81
Error error: package android.support.design.widget.TabLayout does not exist
public void onTabSelected (android.support.design.widget.TabLayout.Tab p0) MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\md5270abb39e60627f0f200893b490a1ade\TabbedPageRenderer.java 84
Error error: package android.support.design.widget.TabLayout does not exist
private native void n_onTabSelected (android.support.design.widget.TabLayout.Tab p0); MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\md5270abb39e60627f0f200893b490a1ade\TabbedPageRenderer.java 89
Error error: package android.support.design.widget.TabLayout does not exist
public void onTabUnselected (android.support.design.widget.TabLayout.Tab p0) MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\md5270abb39e60627f0f200893b490a1ade\TabbedPageRenderer.java 92
Error error: package android.support.design.widget.TabLayout does not exist
private native void n_onTabUnselected (android.support.design.widget.TabLayout.Tab p0); MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\md5270abb39e60627f0f200893b490a1ade\TabbedPageRenderer.java 97
Error error: package android.support.design.widget.AppBarLayout does not exist
android.support.design.widget.AppBarLayout.OnOffsetChangedListener MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\AppBarLayout_OnOffsetChangedListenerImplementor.java 8
Error error: cannot find symbol
public void onOffsetChanged (android.support.design.widget.AppBarLayout p0, int p1)
symbol: class AppBarLayout
location: package android.support.design.widget MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\AppBarLayout_OnOffsetChangedListenerImplementor.java 27
Error error: cannot find symbol
private native void n_onOffsetChanged (android.support.design.widget.AppBarLayout p0, int p1);
symbol: class AppBarLayout
location: package android.support.design.widget MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\AppBarLayout_OnOffsetChangedListenerImplementor.java 32
Error error: package android.support.design.widget.NavigationView does not exist
android.support.design.widget.NavigationView.OnNavigationItemSelectedListener MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\NavigationView_OnNavigationItemSelectedListenerImplementor.java 8
Error error: package android.support.design.widget.SwipeDismissBehavior does not exist
android.support.design.widget.SwipeDismissBehavior.OnDismissListener MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\SwipeDismissBehavior_OnDismissListenerImplementor.java 8
Error error: package android.support.design.widget.TabLayout does not exist
android.support.design.widget.TabLayout.OnTabSelectedListener MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\TabLayout_OnTabSelectedListenerImplementor.java 8
Error error: package android.support.design.widget.TabLayout does not exist
public void onTabReselected (android.support.design.widget.TabLayout.Tab p0) MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\TabLayout_OnTabSelectedListenerImplementor.java 29
Error error: package android.support.design.widget.TabLayout does not exist
private native void n_onTabReselected (android.support.design.widget.TabLayout.Tab p0); MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\TabLayout_OnTabSelectedListenerImplementor.java 34
Error error: package android.support.design.widget.TabLayout does not exist
public void onTabSelected (android.support.design.widget.TabLayout.Tab p0) MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\TabLayout_OnTabSelectedListenerImplementor.java 37
Error error: package android.support.design.widget.TabLayout does not exist
private native void n_onTabSelected (android.support.design.widget.TabLayout.Tab p0); MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\TabLayout_OnTabSelectedListenerImplementor.java 42
Error error: package android.support.design.widget.TabLayout does not exist
public void onTabUnselected (android.support.design.widget.TabLayout.Tab p0) MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\TabLayout_OnTabSelectedListenerImplementor.java 45
Error error: package android.support.design.widget.TabLayout does not exist
private native void n_onTabUnselected (android.support.design.widget.TabLayout.Tab p0); MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp.Droid\obj\Debug\android\src\mono\android\support\design\widget\TabLayout_OnTabSelectedListenerImplementor.java 50
Warning CS0108 'App.Current' hides inherited member 'Application.Current'. Use the new keyword if hiding was intended. MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\App.cs 9
Warning CS0108 'LoginPage.IsBusy' hides inherited member 'Page.IsBusy'. Use the new keyword if hiding was intended. MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\LoginPage.xaml.cs 53
Warning CS4014 Because this call is not awaited, execution of the current method continues before the call is completed. Consider applying the 'await' operator to the result of the call. MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\LoginPage.xaml.cs 105
Warning CS4014 Because this call is not awaited, execution of the current method continues before the call is completed. Consider applying the 'await' operator to the result of the call. MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\LoginPage.xaml.cs 112
Warning CS0649 Field 'LoginServerResponseModel.Login' is never assigned to, and will always have its default value null MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\Models\LoginServerResponseModel.cs 8
Warning CS0649 Field 'RegistrationServerResponseModel.registration' is never assigned to, and will always have its default value null MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\Models\RegistrationServerResponseModel.cs 8
Warning CS4014 Because this call is not awaited, execution of the current method continues before the call is completed. Consider applying the 'await' operator to the result of the call. MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\SignupPage.xaml.cs 99
Warning CS4014 Because this call is not awaited, execution of the current method continues before the call is completed. Consider applying the 'await' operator to the result of the call. MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\SignupPage.xaml.cs 150
Warning CS4014 Because this call is not awaited, execution of the current method continues before the call is completed. Consider applying the 'await' operator to the result of the call. MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\SignupPage.xaml.cs 157
Warning CS0414 The field 'UploadImagePage.imgcount' is assigned but its value is never used MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\UploadImagePage.xaml.cs 10
Warning CS0414 The field 'UploadImagePage.userfolder' is assigned but its value is never used MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\UploadImagePage.xaml.cs 11
Warning CS4014 Because this call is not awaited, execution of the current method continues before the call is completed. Consider applying the 'await' operator to the result of the call. MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\UploadImagePage.xaml.cs 56
Warning #(Content) build action is not supported MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\Images\background.png
Warning #(Content) build action is not supported MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\Images\check_active.png
Warning #(Content) build action is not supported MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\Images\check_inactive.png
Warning #(Content) build action is not supported MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\Images\icon_easyrest.png
Warning #(Content) build action is not supported MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\Images\ic_launcher.png
Warning #(Content) build action is not supported MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\Images\logout.png
Warning #(Content) build action is not supported MyApp.Droid P:\VisualStudioProjects\MyApp\MyApp\MyApp\Images\pdf_icon.png
Try backing up and removing anything under C:\Users\UserName\AppData\Local\Xamarin\Android.Support.Design\23.0.1.3 (or similar version number), then building the project. Check the output window and you should see a link to a zip file and where to unzip it.
You may have to do this for other folders too, such as Android.Support.v7.AppCompat
the way I fixed this error was deleting the obj and bin folders from the app project folder and rebuilding it again. Worked for me.
After a lot of tinkering around I finally got this fixed and heres what I did, I updated Xamarin to the newest version while simultaneously Updating VS 2015 to update 2, after all that was done and before starting VS I deleted all the User/username/AppData/Xamarin/Android.Support.* folders and then opened VS 2015 and created a brand new Xamarin Forms Shared Project Solution and viola it copied over all the needed files and Android compiles.
First check that the component android.support.design.Library it's installed
In my case I I already had it installed, after, I removed de Component of android.support.design.Library and I installed again and fix it
Mac Users
Open Terminal and type the following command:
open ~/.local/share/Xamarin/
Create a 'just in case' folder on your desktop and move all of the content out of the ~/.local/share/Xamarin/ folder.
Rebuild your application.
You'll see a message like this printed to the console:
/Users/{username}/Documents/Development/{path to .Droid project}: Error XA5209: Unzipping failed. Please
download
https://dl-ssl.google.com/android/repository/android_m2repository_r29.zip
and extract it to the
/Users/{username}/.local/share/Xamarin/Xamarin.Android.Support.v4/23.3.0.0/content
directory. (XA5209)
Download the new .zip file and extract it to:
open ~/.local/share/Xamarin/Xamarin.Android.Support.v4/23.3.0.0/content
You may need to repeat this for other folders.
If you are on PC check out Nigel's answer.

Categories

Resources