Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not compile native assembly file: typemaps.armeabi-v7a.ll #19247

Closed
arvindrajachourasiya opened this issue Dec 6, 2023 · 6 comments
Closed
Labels
partner/android Issues for the Android SDK platform/android 🤖 s/needs-attention Issue has more information and needs another look s/triaged Issue has been reviewed s/try-latest-version Please try to reproduce the potential issue on the latest public version t/bug Something isn't working

Comments

@arvindrajachourasiya
Copy link

arvindrajachourasiya commented Dec 6, 2023

Description

Create .NET MAUI Project. I haven't modified anything. While doing build getting compile time error - Could not compile native assembly file: typemaps.armeabi-v7a.ll.

Sometimes two errors are coming sometimes three and sometimes four. Its random. Below is Visual Studio Information. I am using Windows 11 laptop. Same issue with MAUI, Xamarin.

Before few months I was getting same issue

#14531

Microsoft Visual Studio Professional 2022
Version 17.6.5
VisualStudio.17.Release/17.6.5+33829.357
Microsoft .NET Framework
Version 4.8.04161

Installed Version: Professional

ADL Tools Service Provider 1.0
This package contains services used by Data Lake tool

C# Tools 4.6.0-3.23259.8+c3cc1d0ceeab1a65da0217e403851a1e8a30086a
C# components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.

NuGet Package Manager 6.6.0
NuGet Package Manager in Visual Studio. For more information about NuGet, visit https://docs.nuget.org/

Project System Tools 1.0
Tools for working with C#, VisualBasic, and F# projects.

SQL Server Data Tools 17.6.13.0
Microsoft SQL Server Data Tools

ToolWindowHostedEditor 1.0
Hosting json editor into a tool windo

VisualStudio.Mac 1.0
Mac Extension for Visual Studio

VSPackage Extension 1.0
VSPackage Visual Studio Extension Detailed Info

Xamarin 17.6.0.251 (d17-6@318364c)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin Designer 17.6.6.0 (remotes/origin/d17-6@cb430751d1)
Visual Studio extension to enable Xamarin Designer tools in Visual Studio.

Xamarin Templates 17.6.32 (98c12a2)
Templates for building iOS, Android, and Windows apps with Xamarin and Xamarin.Forms.

Xamarin.Android SDK 13.2.0.6 (d17-5/a200af1)
Xamarin.Android Reference Assemblies and MSBuild support.
Mono: 6dd9def
Java.Interop: xamarin/java.interop/d17-5@149d70fe
SQLite: xamarin/sqlite@68c69d8
Xamarin.Android Tools: xamarin/xamarin-android-tools/d17-5@9f02d77

Xamarin.iOS and Xamarin.Mac SDK 16.4.0.6 (97731c92c)
Xamarin.iOS and Xamarin.Mac Reference Assemblies and MSBuild support.

Create .NET MAUI Project
Build it
Getting compile time error
Expected behavior : Getting an error
Actual behavior : Project should build successfully

Please find below screenshot

image

Steps to Reproduce

Create .NET MAUI Project
Build it
Getting compile time error
Expected behavior : Getting an error
Actual behavior : Project should build successfully

Link to public reproduction project repository

No response

Version with bug

8.0.3

Is this a regression from previous behavior?

Yes, this used to work

Last version that worked well

Unknown/Other

Affected platforms

Android

Affected platform versions

No response

Did you find any workaround?

No response

Relevant log output

1>        Target ComputeProcessXamlFiles:
1>          (Out) ProcessedXamlFiles == bin\Debug\net7.0-windows10.0.19041.0\win10-x64\Platforms\Windows\App.xbf
1>        Target CustomOutputGroupForPackaging:
1>          (Out) Project='MauiApp2' ProcessedXamlFiles == bin\Debug\net7.0-windows10.0.19041.0\win10-x64\Platforms\Windows\App.xbf
1>          (Out) XamlPackagingRootFolder == bin\Debug\net7.0-windows10.0.19041.0\win10-x64\\
1>          (Out) ProcessedXamlFilesFullPath == C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\Platforms\Windows\App.xbf
1>          (Out) Project='MauiApp2' CustomOutputGroupForPackagingOutput == C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\Platforms\Windows\App.xbf
1>        MauiApp2 : MauiApp2.PriFilesOutputGroup : C:\Program Files\dotnet\packs\Microsoft.Maui.Controls.Ref.win\7.0.86\ref\net7.0-windows10.0.19041\Microsoft.Maui.Controls.Compatibility.pri -> Microsoft.Maui.Controls.Compatibility.pri
1>        MauiApp2 : MauiApp2.PriFilesOutputGroup : C:\Program Files\dotnet\packs\Microsoft.Maui.Controls.Ref.win\7.0.86\ref\net7.0-windows10.0.19041\Microsoft.Maui.Controls.pri -> Microsoft.Maui.Controls.pri
1>        MauiApp2 : MauiApp2.PriFilesOutputGroup : C:\Program Files\dotnet\packs\Microsoft.Maui.Core.Ref.win\7.0.86\ref\net7.0-windows10.0.19041\Microsoft.Maui.pri -> Microsoft.Maui.pri
1>        MauiApp2 : MauiApp2.ContentFilesProjectOutputGroup : C:\Users\username\source\repos\MauiApp2\Resources\Raw\AboutAssets.txt -> AboutAssets.txt
1>        MauiApp2 : MauiApp2.EmbedOutputGroupForPackaging : C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\Platforms\Windows\App.xbf -> Platforms\Windows\App.xbf
1>      Target _CopyOutOfDateSourceItemsToOutputDirectory:
1>        Copying file from "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-windows10.0.19041.0\win10-x64\apphost.exe" to "C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\MauiApp2.exe".
1>      Target CopyGeneratedXaml:
1>        Creating directory "bin\Debug\net7.0-windows10.0.19041.0\win10-x64\Platforms\Windows".
1>        Copying file from "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-windows10.0.19041.0\win10-x64\Platforms\Windows\App.xbf" to "C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\Platforms\Windows\App.xbf".
1>      Target CopyFilesToOutputDirectory:
1>        Copying file from "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-windows10.0.19041.0\win10-x64\MauiApp2.dll" to "C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\MauiApp2.dll".
1>        Copying reference assembly from "obj\Debug\net7.0-windows10.0.19041.0\win10-x64\refint\MauiApp2.dll" to "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-windows10.0.19041.0\win10-x64\ref\MauiApp2.dll".
1>        MauiApp2 -> C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\MauiApp2.dll
1>        Copying file from "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-windows10.0.19041.0\win10-x64\MauiApp2.pdb" to "C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\MauiApp2.pdb".
1>      Target _GenerateProjectPriConfigurationFiles:
1>        Creating directory "obj\Debug\net7.0-windows10.0.19041.0\win10-x64\embed\Platforms\Windows".
1>        Copying file from "C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\Platforms\Windows\App.xbf" to "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-windows10.0.19041.0\win10-x64\embed\Platforms\Windows\App.xbf".
1>        MauiApp2 -> obj\Debug\net7.0-windows10.0.19041.0\win10-x64\priconfig.xml
1>        MauiApp2 -> obj\Debug\net7.0-windows10.0.19041.0\win10-x64\unfiltered.layout.resfiles
1>        MauiApp2 -> obj\Debug\net7.0-windows10.0.19041.0\win10-x64\filtered.layout.resfiles
1>        MauiApp2 -> obj\Debug\net7.0-windows10.0.19041.0\win10-x64\excluded.layout.resfiles
1>        MauiApp2 -> obj\Debug\net7.0-windows10.0.19041.0\win10-x64\resources.resfiles
1>        MauiApp2 -> obj\Debug\net7.0-windows10.0.19041.0\win10-x64\pri.resfiles
1>        MauiApp2 ->
1>        MauiApp2 -> obj\Debug\net7.0-windows10.0.19041.0\win10-x64\embed\embed.resfiles
1>      MauiApp2 -> resources.pri
1>    Target GetPackagingOutputs:
1>      Target PrepareForPublish:
1>        Creating directory "bin\Debug\net7.0-windows10.0.19041.0\win10-x64\publish\".
1>      Creating "obj\Debug\net7.0-android\R.cs.flag" because "AlwaysCreate" was specified.
1>    Target GenerateTargetFrameworkMonikerAttribute:
1>      Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
1>    Target CoreGenerateAssemblyInfo:
1>      Skipping target "CoreGenerateAssemblyInfo" because all output files are up-to-date with respect to the input files.
1>    CompilerServer: server - server processed compilation - 00d167ae-955d-47c6-8029-70a854bf3f5f
1>  Target XamlC:
1>    Compiling Xaml, assembly: obj\Debug\net7.0-android\MauiApp2.dll
1>    Creating "obj\Debug\net7.0-android\XamlC.stamp" because "AlwaysCreate" was specified.
1>  Target CopyFilesToOutputDirectory:
1>    Copying file from "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\MauiApp2.dll" to "C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-android\MauiApp2.dll".
1>    MauiApp2 -> C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-android\MauiApp2.dll
1>    Copying file from "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\MauiApp2.pdb" to "C:\Users\username\source\repos\MauiApp2\bin\Debug\net7.0-android\MauiApp2.pdb".
1>  Target _ResolveAssemblies:
1>    Target ProcessFrameworkReferences:
1>      Target ResolvePackageAssets:
1>        Target ResolvePackageAssets:
1>  Target _CreatePackageWorkspace:
1>    Creating directory "obj\Debug\net7.0-android\android\assets\".
1>  Target _GenerateJavaStubs:
1>    Creating "obj\Debug\net7.0-android\stamp\_GenerateJavaStubs.stamp" because "AlwaysCreate" was specified.
1>  Target _ConvertCustomView:
1>    Creating "obj\Debug\net7.0-android\stamp\_ConvertCustomView.stamp" because "AlwaysCreate" was specified.
1>  Target _AddStaticResources:
1>    Creating directory "obj\Debug\net7.0-android\android\bin".
1>    Copying file from "C:\Program Files\dotnet\packs\Microsoft.Android.Ref.33\33.0.46\ref\net7.0\mono.android.jar" to "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\android\bin\mono.android.jar".
1>    Touching "obj\Debug\net7.0-android\android\bin\mono.android.jar".
1>    Creating "obj\Debug\net7.0-android\static.flag" because "AlwaysCreate" was specified.
1>  Target _GeneratePackageManagerJava:
1>    Creating "obj\Debug\net7.0-android\stamp\_GeneratePackageManagerJava.stamp" because "AlwaysCreate" was specified.
1>  Target _FixupCustomViewsForAapt2:
1>    Touching "obj\Debug\net7.0-android\R.cs.flag".
1>  Target _GenerateAndroidAssetsDir:
1>    Creating directory "obj\Debug\net7.0-android\assets\".
1>    Copying file from "C:\Users\username\source\repos\MauiApp2\Resources\Raw\AboutAssets.txt" to "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\assets\AboutAssets.txt".
1>    Copying file from "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\resizetizer\f\OpenSans-Regular.ttf" to "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\assets\OpenSans-Regular.ttf".
1>    Copying file from "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\resizetizer\f\OpenSans-Semibold.ttf" to "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\assets\OpenSans-Semibold.ttf".
1>    Touching "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\assets\AboutAssets.txt".
1>    Touching "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\assets\OpenSans-Regular.ttf".
1>    Touching "C:\Users\username\source\repos\MauiApp2\obj\Debug\net7.0-android\assets\OpenSans-Semibold.ttf".
1>  Target _CreateBaseApk:
1>    Touching "obj\Debug\net7.0-android\android\bin\packaged_resources".
1>  Target _CompileJava:
1>    Note: Some input files use or override a deprecated API.
1>    Note: Recompile with -Xlint:deprecation for details.
1>    Note: Some input files use unchecked or unsafe operations.
1>    Note: Recompile with -Xlint:unchecked for details.
1>    Creating "obj\Debug\net7.0-android\stamp\_CompileJava.stamp" because "AlwaysCreate" was specified.
1>  Target _CompileNativeAssemblySources:
1>    C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\Xamarin.Android.Common.targets(1987,3): error XA3006: Could not compile native assembly file: typemaps.armeabi-v7a.ll
1>    C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\Xamarin.Android.Common.targets(1987,3): error XA3006: 
1>    C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\Xamarin.Android.Common.targets(1987,3): error XA3006: 
1>    C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\Xamarin.Android.Common.targets(1987,3): error XA3006:
1>  Done building target "_CompileNativeAssemblySources" in project "MauiApp2.csproj" -- FAILED.
1>
1>  Done building project "MauiApp2.csproj" -- FAILED.
1>
1>Build FAILED.
1>
1>C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\Xamarin.Android.Common.targets(1987,3): error XA3006: Could not compile native assembly file: typemaps.armeabi-v7a.ll
1>C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\Xamarin.Android.Common.targets(1987,3): error XA3006: 
1>C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\Xamarin.Android.Common.targets(1987,3): error XA3006: 
1>C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\Xamarin.Android.Common.targets(1987,3): error XA3006: 
1>    0 Warning(s)
1>    1 Error(s)
1>
1>Time Elapsed 00:01:42.79
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
========== Rebuild started at 3:27 PM and took 01:47.359 minutes ==========
@arvindrajachourasiya arvindrajachourasiya added the t/bug Something isn't working label Dec 6, 2023
@drasticactions
Copy link
Contributor

Your stacktrace indicates you're using net7.0, did you try using net8.0?

Judging that the original issue was closed inside of xamarin-android and that you said it affects you in MAUI and Xamarin, my guess here is this is all contained within xamarin-android and is unrelated to the MAUI UI project. @grendello @jonpryor @jonathanpeppers what do ya'll think?

@samhouts samhouts added the s/needs-info Issue needs more info from the author label Dec 7, 2023
@ghost
Copy link

ghost commented Dec 7, 2023

Hi @arvindrajachourasiya. We have added the "s/needs-info" label to this issue, which indicates that we have an open question for you before we can take further action. This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.

@samhouts samhouts added the potential-regression This issue described a possible regression on a currently supported version., verification pending label Dec 7, 2023
@arvindrajachourasiya
Copy link
Author

arvindrajachourasiya commented Dec 8, 2023

@drasticactions - This issue comes only in Android project, be it Xamarin.forms or MAUI. I created new MAUI project this error started coming. Then I checked in Xamarin.forms project, there also same error coming. It always comes in Xamarin and MAUI's android project. Targeting .NET7 or .NET8 is not helping.

Last time (with #14531 ) @grendello and @jonpryor they helped me to fix this issue. Now it again started coming. Please fix this issue. I know this is something different which I can't fix and there is no alternate available for this. Last time I thought It would be release in production by you people but I think it didnt happen. In the last issue (14531) @grendello has provided a link to download some files and replace in bin folder (C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Xamarin\Android\binutils\bin). Now the link which @grendello provided is broken. How can I fix this issue now ? We are having client visit. These .NET products are always sick. Please help me to fix asap. Thank you.
@ilamble do you have any idea, you was getting this issue before ?
@jonathanpeppers

@ghost ghost added s/needs-attention Issue has more information and needs another look and removed s/needs-info Issue needs more info from the author labels Dec 8, 2023
@arvindrajachourasiya
Copy link
Author

I found the files given in the previous link. I will check if it works or not
bifile1.zip
binfiles2.zip

@samhouts samhouts added partner/android Issues for the Android SDK and removed potential-regression This issue described a possible regression on a currently supported version., verification pending labels Dec 8, 2023
@RoiChen001
Copy link

Can't repro this issue on the latest 17.10.0 Preview 4(8.0.20).

@RoiChen001 RoiChen001 added s/triaged Issue has been reviewed s/try-latest-version Please try to reproduce the potential issue on the latest public version labels Apr 18, 2024
Copy link
Contributor

Hi @arvindrajachourasiya. We have added the "s/try-latest-version" label to this issue, which indicates that we'd like you to try and reproduce this issue on the latest available public version. This can happen because we think that this issue was fixed in a version that has just been released, or the information provided by you indicates that you might be working with an older version.

You can install the latest version by installing the latest Visual Studio (Preview) with the .NET MAUI workload installed. If the issue still persists, please let us know with any additional details and ideally a reproduction project provided through a GitHub repository.

This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.

@github-actions github-actions bot locked and limited conversation to collaborators May 26, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
partner/android Issues for the Android SDK platform/android 🤖 s/needs-attention Issue has more information and needs another look s/triaged Issue has been reviewed s/try-latest-version Please try to reproduce the potential issue on the latest public version t/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants