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

MAUI: Could not compile native assembly file: environment.arm64-v8a.ll #14531

Closed
arvindrajachourasiya opened this issue Apr 12, 2023 · 133 comments
Closed
Labels
area-setup Installation, setup, requirements, maui-check, workloads, platform support delighter external partner/android Issues for the Android SDK platform/android 🤖 s/needs-attention Issue has more information and needs another look t/bug Something isn't working
Milestone

Comments

@arvindrajachourasiya
Copy link

arvindrajachourasiya commented Apr 12, 2023

Description

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

Same issue I have found here and tried given solution still not working -

https://learn.microsoft.com/en-us/answers/questions/1199060/not-able-to-build-net7-0-android-project-in-vs-for?source=docs

Visual Studio -

Microsoft Visual Studio Professional 2022
Version 17.5.4
VisualStudio.17.Release/17.5.4+33530.505
Microsoft .NET Framework
Version 4.8.04161

Installed Version: Professional

ASP.NET and Web Tools 17.5.318.41597
ASP.NET and Web Tools

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

Extensibility Message Bus 1.4.3 (main@2a4517a)
Provides common messaging-based MEF services for loosely coupled Visual Studio extension components communication and integration.

Microsoft JVM Debugger 1.0
Provides support for connecting the Visual Studio debugger to JDWP compatible Java Virtual Machines

Mono Debugging for Visual Studio 17.5.9 (11975e6)
Support for debugging Mono processes with Visual Studio.

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

Razor (ASP.NET Core) 17.5.2.2316603+9f1b6856460af1e592d387ebef416eadddac453f
Provides languages services for ASP.NET Core Razor.

Visual Studio IntelliCode 2.2
AI-assisted development for Visual Studio.

VisualStudio.DeviceLog 1.0
Information about my package

VisualStudio.Mac 1.0
Mac Extension for Visual Studio

VSPackage Extension 1.0
VSPackage Visual Studio Extension Detailed Info

Xamarin 17.5.0.173 (d17-5@33e727c)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin Designer 17.5.3.46 (remotes/origin/d17-5@e4dd80b2bb)
Visual Studio extension to enable Xamarin Designer tools in Visual Studio.

Xamarin.Android SDK 13.2.0.0 (d17-5/797e2e1)
Xamarin.Android Reference Assemblies and MSBuild support.
Mono: 6dd9def
Java.Interop: xamarin/java.interop/main@149d70fe
SQLite: xamarin/sqlite@fdc1e34
Xamarin.Android Tools: xamarin/xamarin-android-tools/main@9f02d77

Steps to Reproduce

  1. Create .NET MAUI Project
  2. Build it
  3. Getting compile time error

Expected behavior : Getting an error
Actual behavior : Project should build successfully

Link to public reproduction project repository

NA

Version with bug

7.0 (current)

Last version that worked well

Unknown/Other

Affected platforms

Android

Affected platform versions

Android 12

Did you find any workaround?

No

Relevant log output

Build started...
1>------ Build started: Project: MauiApp1, Configuration: Debug Any CPU ------
1>MauiApp1 -> C:\Users\source\repos\MauiApp1\MauiApp1\bin\Debug\net7.0-android\MauiApp1.dll
1>MauiApp1 -> C:\Users\source\repos\MauiApp1\MauiApp1\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\MauiApp1.dll
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: environment.arm64-v8a.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 project "MauiApp1.csproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
========== Build started at 11:38 AM and took 03.857 seconds ==========
@arvindrajachourasiya arvindrajachourasiya added the t/bug Something isn't working label Apr 12, 2023
@jsuarezruiz jsuarezruiz added platform/android 🤖 area-setup Installation, setup, requirements, maui-check, workloads, platform support labels Apr 12, 2023
@jsuarezruiz
Copy link
Contributor

@jonathanpeppers Thoughts?

@jonathanpeppers
Copy link
Member

I think we need a repro or MSBuild diagnostic log.

@jonathanpeppers jonathanpeppers added the s/needs-info Issue needs more info from the author label Apr 12, 2023
@ghost
Copy link

ghost commented Apr 12, 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.

@arvindrajachourasiya
Copy link
Author

@jonathanpeppers @jsuarezruiz Please find attached file with MSBuild diagnostic log Output. Original log txt file was 57MB, it was not being uploaded. I have uploaded same file in zip format. Please check that.
MSBuildDiagnosticLog..zip

Seem other people as well facing same issue. Below find few links

https://learn.microsoft.com/en-us/answers/questions/1199060/not-able-to-build-net7-0-android-project-in-vs-for?source=docs

https://learn.microsoft.com/en-us/answers/questions/1197712/not-able-to-build-xamarin-android-project-with-lat

https://stackoverflow.com/questions/75927750/microsoft-android-build-fails-could-not-compile-native-assembly-file

#14531

dotnet/android#6974

dotnet/android#7939

Please let me know if you need more information.

@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 Apr 13, 2023
@jonathanpeppers
Copy link
Member

jonathanpeppers commented Apr 13, 2023

@arvindrajachourasiya looking at the error message in the log:

1>        [LLVM llc] C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\binutils\bin\llc.EXE -O2 --debugger-tune=lldb --debugify-level=location+variables --fatal-warnings --filetype=obj --relocation-model=pic -o=environment.arm64-v8a.o environment.arm64-v8a.ll
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: environment.arm64-v8a.ll

What are the contents of obj\Debug\net7.0-android33.0\android\environment.arm64-v8a.ll? @grendello any other information that would be useful here?

I don't see a custom @(AndroidEnvironment) file in the log.

@grendello
Copy link

@arvindrajachourasiya could you attach the environment.arm64-v8a.ll file please? You can find it in obj\Debug\net7.0-android33.0\android\environment.arm64-v8a.ll, thanks!

@grendello
Copy link

@jonathanpeppers once I have the file, I can run llc on it locally and see what's the error

@arvindrajachourasiya
Copy link
Author

@jonathanpeppers @grendello - Please find the files below. I have attached 4 files there as I am getting 4 errors.
environment.arm64-v8a.zip

image

Below is the screenshots of errors.

image

When I keep building my project, every time I get different error (out of 4) and sometimes all 4 errors are coming. This time I am getting all the errors. Added screenshots and logs.

Log file for 4 errors
armeabi-v7a.ll__x86_64.ll__arm64-v8a.ll__arm64-v8a.ll__LOG.zip

@grendello
Copy link

@arvindrajachourasiya @jonathanpeppers so it's both good and bad news. The files attached by @arvindrajachourasiya, thank you, compile just fine. That's the good news.

The bad news, there's no actual error in the provided log and I suspect the failure being environmental - something on the machine is causing the process to fail. Shortage of disk space, resource limits imposed by the OS, a filesystem corruption all come to mind but it's impossible to say what it is in the absence of actual errors :(

@arvindrajachourasiya I'm afraid I will need to ask you to build the app from command line, producing a binlog file, hoping it will have more info.

Please build the app as follows from VS developer command prompt (after first removing all the bin and obj directories in the project) until the build fails:

dotnet build -bl

Please attach the failed build's msbuild.binlog file here.

@arvindrajachourasiya
Copy link
Author

@grendello - I have done building app from VS Command Prompt and attached log file. Please find it. I am not sure how to get msbuild.binlog , I have copied all the text from cmd to a text file and attached here. Please let me know where I can find msbuild.binlog if the logfile I have provided and msbuild.binlog file have any difference between them.

VS_cmd_Log.txt

@grendello
Copy link

@arvindrajachourasiya Thanks for the log, it shows a sharing violation error:

C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\Xamarin.Android.EmbeddedResource.targets(36,5): error XARLP7024: System.IO.IOException: The process cannot access the file 'C:\Users\username\Documents\Visual Studio 2022\Projects\MauiApp1\MauiApp1\obj\Debug\net7.0-android33.0\lp\126\jl\res\animator\mtrl_fab_transformation_sheet_expand_spec.xml' because it is being used by another process. [C:\Users\username\Documents\Visual Studio
 2022\Projects\MauiApp1\MauiApp1\MauiApp1.csproj::TargetFramework=net7.0-android33.0]

I wonder if the build errors you've seen earlier are of the same nature.

Regarding msbuild.binlog, it will be found in the same directory in which you ran dotnet build -bl

@arvindrajachourasiya
Copy link
Author

@grendello - I got msbuild.binlog. Thank you. Not sure about build errors. They may be different in vs cmd. Please find attached file. And let me know possible solution. I tired from last week but those are not going away. Please find msbuild.binlog. file.

msbuild.zip

@jonathanpeppers
Copy link
Member

If you try it again, do you still get:

The process cannot access the file 'C:\Users\...\Documents\Visual Studio 2022\Projects\MauiApp1\MauiApp1\obj\Debug\net7.0-android33.0\lp\126\jl\res\animator\mtrl_fab_transformation_sheet_expand_spec.xml' because it is being used by another process.

Do you have any third-party antivirus installed? In the past, we've seen them lock files on Windows and cause builds to fail randomly.

@arvindrajachourasiya
Copy link
Author

arvindrajachourasiya commented Apr 14, 2023

@jonathanpeppers - Please find latest log. In my Windows 11 I have Forcepoint One Endpoint and Digital Guardian Agent. I think there is no other Antivirus.

msbuild.zip

@grendello
Copy link

@arvindrajachourasiya thank you for the log. The first msbuild.zip shows the same sharing violation error you pasted before, the 2nd one is unfortunately broken (truncated).

I think the problem here might be the feuding antiviruses - together with the two you mentioned, there's also MS Defender which is (I think) active by default. They might be interfering with each other and your build process :(

@arvindrajachourasiya
Copy link
Author

@grendello - if MS Defender is the issue (or any other application) please let me know that solution, how can I make it work ? Why all other people are not facing same issue as MS Defender comes by default with Windows OS. Thank you.

@grendello
Copy link

@grendello I'm not saying that MS Defender is the one that's causing problems - it might be interaction between the various antivirus software, including MS Defender, that causes the problem. We've had a share of issues related to file locking due to various antivirus programs. However, in your case it's a guessing game since we don't see the cause of the error, just the effect. To try to determine whether antivirus software is the problem here, turn off all but one of them and see if that fixes the problem. For other causes, check hard disk/ssd health, filesystem health (a simple test would be to copy the application source code to a separate disk disk and see if the problem occurs there)

@arvindrajachourasiya
Copy link
Author

@grendello - For most of apps including MS Defender, I can't change the settings. It is managed by organization. I am checking more on that. Please find MAUI project code in attached file. To check the same code base in other machines/laptop seems bit difficult to me as I do not have other machines with all the environment enabled. Please have a look on my code. Thank you.

MauiApp1.zip

@rachelkang rachelkang added this to the Backlog milestone Apr 18, 2023
@ghost
Copy link

ghost commented Apr 18, 2023

We've added this issue to our backlog, and we will work to address it as time and resources allow. If you have any additional information or questions about this issue, please leave a comment. For additional info about issue management, please read our Triage Process.

@grendello
Copy link

@arvindrajachourasiya thanks for the app sample, however the problem in this issue isn't related to your code (or the one we generate). The app builds fine for me, I get the apk package in the bin folder. The difference is that I built it on three machines which have no software that opens every file and examines it for viruses (I built it on macOS, Linux and without any antivirus software present and on Windows with just MS Defender active), locking the file in the process. If a machine has not one but three such software suites running at the same time, then at one point or another they will either step on each other's toes, or the locking process will take so much time (one A/V locking it first, the next waiting its turn and the third one after that doing the same work) that the build process may be faced with a sharing violation when it tries to assemble your software as quickly as possible.

On my part (code generation) I'm afraid I can't help much here, as everything in that department appears to check out. Perhaps @jonathanpeppers or @dellis1972 can come up with an idea of how to work around the file locking issue.

@dellis1972
Copy link
Contributor

In the past I have had to ask the Corporate IT department to allow exclusions on Developer Machines. This allows developers to exclude certain folders which are used for compiling etc from the virus scanners.

@arvindrajachourasiya
Copy link
Author

@dellis1972 @grendello - I have to write to my IT Department related to this issue.

In the past I have had to ask the Corporate IT department to allow exclusions on Developer Machines. This allows developers to exclude certain folders which are used for compiling etc from the virus scanners.

Could you please let me know what folders/files I might need to mention in my request to exclude them ? I will help me. Thank you.

@arvindrajachourasiya
Copy link
Author

@dellis1972 @grendello - My issue and this issue dotnet/android#7939 isn't same ? Can I assume you are not able to help me on this issue ? or you people are checking this ?

@ilamble
Copy link

ilamble commented Jul 27, 2023

@grendello @dellis1972 I tried the build again and it was successful.

I've done some investigation and the problem was the modified Xamarin.Android.Build.Tasks.dll (which was running the llc.exe processes in sequence rather than parallel). I had swapped back to the original Xamarin.Android.Build.Tasks.dll, but I had not restarted Visual Studio after doing this and it looks like it was still using the modified dll. (I went through the same steps again and I could reproduce the error with the modified dll and having swapped to the original dll without restarting Visual Studio)

So I think this is a fix for the error!

Please note that I am overwriting the existing ld.exe with the lld.exe file provided. If I don't do that I get different build errors.

i.e.
llc.exe from zip -> overwrite llc.exe
lld.exe from zip -> overwrite ld.exe
lld.exe from zip -> also put in bin directory as lld.exe in case it was needed
llvm-mc.exe from zip -> overwrite llvm-mc.exe
llvm-strip.exe from zip -> overwrite llvm-strip.exe

I have also tested this with Xamarin.Forms 5.0.0.2599-pre1, replacing the files in the directory C:\Program Files\Microsoft Visual Studio\2022\Enterprise\MSBuild\Xamarin\Android\binutils\bin. I have been able to build that app successfully too.

@grendello
Copy link

@ilamble excellent news, thanks! :) A PR is underway to switch us to LLVM 16 without UPX, so hopefully it will make into next releases soon.

@arvindrajachourasiya, @ccanbek89 could you please follow the steps described in comment above (ignore the upx commands, they aren't relevant anymore) and replace your existing llc.exe, ld.exe, lld.exe, llvm-mc.exe and llvm-strip.exe with the versions from this archive, making of course copies of the original binaries first. Please take care to shut down Visual Studio before modifying the files in your installation. This should get you going until the fix finds its way to release. Please let us know if the fix worked for you, thanks!

@ilamble
Copy link

ilamble commented Jul 27, 2023

Thank you for all your help @grendello!

@arvindrajachourasiya
Copy link
Author

@grendello - Our Project migration to MAUI is on hold until further notice. I have checked Xamarin.Forms project.

Now I am getting this error in Xamarin.forms project

2>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(2028,3): error XA3006: Could not compile native assembly file: typemaps.armeabi-v7a.ll

After replacing exe files, I got this error.

2>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(2051,3): error XA3007: Could not link native shared library: libxamarin-app.so

image

Steps I followed.

  • Download Windows zip file. Uncompress it. Again uncompress .7z file.
  • I have got 4 exe files - llc.exe, lld.exe, llvm-mc.exe, llvm-strip.exe
  • Got to path C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Xamarin\Android\binutils\bin
  • Close VS and Replace newly got 4 exe files. (I took backup of bin)
  • Start VS -> Build Xamarin.forms project -> got error - > Could not link native shared library: libxamarin-app.so
  • After extracting Windows zip file, I got 4 exe files but ld.exe was missing. There is ld.exe file in my bin folder but that was not there in extracted files. There should be 5 exe file, not sure.

@ilamble
Copy link

ilamble commented Jul 27, 2023

@arvindrajachourasiya I copied the lld.exe file and renamed the copy ld.exe. I then overwrote the existing ld.exe file with the new file. That worked for me.

@arvindrajachourasiya
Copy link
Author

@ilamble - Wow! That worked for me. In a long time, I have seen Build Succeeded. So now can we use our application for production purpose, or will it behave strange as it is kind of manipulated version?

@ilamble
Copy link

ilamble commented Jul 27, 2023

@arvindrajachourasiya My understanding is that we are ok to use this for production purposes, but I will let @grendello confirm.

@grendello
Copy link

Yes, it's fine to use the binaries for production. They are unmodified upstream LLVM 16 (the default stable release) binaries, simply compiled in a fashion that fits our needs (so that they are smaller).

@grendello
Copy link

@arvindrajachourasiya can you test the MAUI app build anyway, please? Replace the binaries in C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\X.Y.Z\tools\binutils\bin\ in the same manner as you did for those in C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Xamarin\Android\binutils\bin and try to build the original app that failed for you. Thanks!

@grendello
Copy link

@ilamble do you still have the older, 15.0.7, UPX-packed binaries perchance? If yes, could you see if this workaround makes the binary work for you after unpacking?

@ilamble
Copy link

ilamble commented Jul 27, 2023

@ilamble do you still have the older, 15.0.7, UPX-packed binaries perchance? If yes, could you see if this workaround makes the binary work for you after unpacking?

@grendello I saw that yesterday and tried it :) UPX still crashes for me with --strip-relocs=0 set (error code -1073741819)

I've just tried it again to confirm. That's with UPX 4.0.2.0

@grendello
Copy link

@ilamble thanks :)

@arvindrajachourasiya
Copy link
Author

@grendello - Original MAUI app also worked. 😀

@grendello
Copy link

@arvindrajachourasiya excellent, thanks!

@AnithaRaniT
Copy link

AnithaRaniT commented Aug 1, 2023

@grendello - Original MAUI app also worked. 😀

Hello @arvindrajachourasiya , @grendello , I'm also facing the same issue with my VS solution. Could you please elaborate what exact changes you have made to resolve this issue. It would be helpful to resolve my blocker.

What I have done:

Created a MAUI app--> have made no changes --> Directly trying to deploy in the android device --> getting the error as Severity Code Description Project File Line Suppression State
Error XA3006 Could not compile native assembly file: compressed_assemblies.arm64-v8a.ll

@ilamble
Copy link

ilamble commented Aug 1, 2023

@AnithaRaniT What you need to do:

Download this zip file https://github.com/xamarin/xamarin-android-binutils/suites/14588951053/artifacts/826817155

Uncompress it. Again uncompress .7z file.

You should then have 4 exe files - llc.exe, lld.exe, llvm-mc.exe, llvm-strip.exe

Copy lld.exe and rename the copy ld.exe

Go to path C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\binutils\bin\

(That path is for MAUI. For Xamarin, the path is C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Xamarin\Android\binutils\bin\ )

Back up the files in that directory.

Close Visual Studio

Copy the five new exe files into that directory.

Start Visual Studio and build your app again.

@AnithaRaniT
Copy link

@ilamble I followed all the steps as mentioned above. But still the issue is not fixed yet. Getting a few more error as below:

Severity Code Description Project File Line Suppression State
Error XA3006 Could not compile native assembly file: typemaps.x86.ll

C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.68\tools\Xamarin.Android.Common.targets 1987
Error XA3006 Could not compile native assembly file: compressed_assemblies.arm64-v8a.ll

C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.68\tools\Xamarin.Android.Common.targets 1987
Severity Code Description Project File Line Suppression State
Error XA3006 Could not compile native assembly file: jni_remap.arm64-v8a.ll

C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.68\tools\Xamarin.Android.Common.targets 1987
Error XA3006 Could not compile native assembly file: typemaps.arm64-v8a.ll

C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.68\tools\Xamarin.Android.Common.targets 1987

Steps I followed.

  • Download Windows zip file. Uncompress it. Again uncompress .7z file.
  • I have got 4 exe files - llc.exe, lld.exe, llvm-mc.exe, llvm-strip.exe
  • Copied lld.exe and renamed as ld.exe
  • Got to path C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.46\tools\binutils\bin
  • Close VS and Replaced the existing 4 files with newly got 5 exe files.
  • Restarted my PC also.
  • Cleaned solution.

My VS version details as below:

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

Installed Version: Professional

Visual C++ 2022 00476-80000-00000-AA633
Microsoft Visual C++ 2022

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

ASA Service Provider 1.0

ASP.NET and Web Tools 17.6.326.62524
ASP.NET and Web Tools

Azure App Service Tools v3.0.0 17.6.326.62524
Azure App Service Tools v3.0.0

Azure Data Lake Tools for Visual Studio 2.6.5000.0
Microsoft Azure Data Lake Tools for Visual Studio

Azure Functions and Web Jobs Tools 17.6.326.62524
Azure Functions and Web Jobs Tools

Azure Stream Analytics Tools for Visual Studio 2.6.5000.0
Microsoft Azure Stream Analytics Tools for Visual Studio

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.

Common Azure Tools 1.10
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

Extensibility Message Bus 1.4.21 (main@8f226a8)
Provides common messaging-based MEF services for loosely coupled Visual Studio extension components communication and integration.

Microsoft Azure Hive Query Language Service 2.6.5000.0
Language service for Hive query

Microsoft Azure Stream Analytics Language Service 2.6.5000.0
Language service for Azure Stream Analytics

Microsoft Azure Tools for Visual Studio 2.9
Support for Azure Cloud Services projects

Microsoft JVM Debugger 1.0
Provides support for connecting the Visual Studio debugger to JDWP compatible Java Virtual Machines

Mono Debugging for Visual Studio 17.6.41 (790a401)
Support for debugging Mono processes with Visual Studio.

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

Razor (ASP.NET Core) 17.6.0.2327201+a6a61fdfa748eaa65aab53dab583276e26af4a3e
Provides languages services for ASP.NET Core Razor.

SQL Server Data Tools 17.6.13.0
Microsoft SQL Server Data Tools

StylerPackage Extension 1.0
StylerPackage Visual Stuido Extension Detailed Info

ToolWindowHostedEditor 1.0
Hosting json editor into a tool window

TypeScript Tools 17.0.20329.2001
TypeScript Tools for Microsoft Visual Studio

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

Visual F# Tools 17.6.0-beta.23174.5+0207bea1afae48d9351ac26fb51afc8260de0a97
Microsoft Visual F# Tools

Visual Studio IntelliCode 2.2
AI-assisted development for Visual Studio.

VisualStudio.DeviceLog 1.0
Information about my package

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.

@ilamble
Copy link

ilamble commented Aug 1, 2023

@AnithaRaniT Can you try doing the same in directory
C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.68\tools\binutils\bin

(I can see from your error messages that you have a later version of MAUI than I have)

@AnithaRaniT
Copy link

Thanks @ilamble. It worked :)

@AnithaRaniT
Copy link

@ilamble, I'm experiencing new errors as follows,

Severity Code Description Project File Line Suppression State
Error APPX1101 Payload contains two or more files with the same destination path 'Microsoft.Azure.Documents.ServiceInterop.dll'. Source files:
C:\Users\thannan.nuget\packages\microsoft.azure.documentdb.core\2.18.0\runtimes\win7-x64\native\Microsoft.Azure.Documents.ServiceInterop.dll
C:\Users\thannan.nuget\packages\microsoft.azure.documentdb\2.13.1\runtimes\win7-x64\native\Microsoft.Azure.Documents.ServiceInterop.dll TCO (TCOApp\TCO) C:\Users\thannan.nuget\packages\microsoft.windowsappsdk\1.2.221209.1\buildTransitive\Microsoft.Build.Msix.Packaging.targets 1504

Error APPX1101 Payload contains two or more files with the same destination path 'Cosmos.CRTCompat.dll'. Source files:
C:\Users\thannan.nuget\packages\microsoft.azure.documentdb\2.13.1\runtimes\win7-x64\native\Cosmos.CRTCompat.dll
C:\Users\thannan.nuget\packages\microsoft.azure.documentdb.core\2.18.0\runtimes\win7-x64\native\Cosmos.CRTCompat.dll
C:\Users\thannan.nuget\packages\microsoft.azure.cosmos\3.20.1\runtimes\win-x64\native\Cosmos.CRTCompat.dll TCO (TCOApp\TCO) C:\Users\thannan.nuget\packages\microsoft.windowsappsdk\1.2.221209.1\buildTransitive\Microsoft.Build.Msix.Packaging.targets 1504

Error XA3006 Could not compile native assembly file: typemaps.x86_64.ll
TCO (TCOApp\TCO) C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.68\tools\Xamarin.Android.Common.targets 1987

@arvindrajachourasiya
Copy link
Author

@grendello - After updating VS to Version 17.7.1, I started getting below errors

3>c:\program files\microsoft visual studio\2022\professional\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(2028,3): error XA3006: Could not compile native assembly file: marshal_methods.x86_64.ll
3>c:\program files\microsoft visual studio\2022\professional\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(2028,3): error XA3006:
3>c:\program files\microsoft visual studio\2022\professional\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(2028,3): error XA3006:
3>c:\program files\microsoft visual studio\2022\professional\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(2028,3): error XA3006:

@dellis1972
Copy link
Contributor

@arvindrajachourasiya the workload packs would have been updated during the upgrade. You will probably need to re-apply the "fix" you did earlier for the previous version. But make sure you put the files in the newer pack folders.

@AnithaRaniT
Copy link

@dellis1972 , In my case, I did the repair, uninstalled and installed freshly with VS version 17.4.3. But still the problem exists.

@AnithaRaniT
Copy link

Any suggestions?

@AnithaRaniT
Copy link

"DEP1700: The recipe file "C:\Projects\MauiApp2\MauiApp2\bin\Debug\net7.0-windows10.0.19041.0\win10-x64\MauiApp2.build.appxrecipe" does not exist. You may need to build your project. MauiApp2

Can someone help me with this error in MAUI windows app

@ghost ghost locked as resolved and limited conversation to collaborators Sep 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-setup Installation, setup, requirements, maui-check, workloads, platform support delighter external partner/android Issues for the Android SDK platform/android 🤖 s/needs-attention Issue has more information and needs another look t/bug Something isn't working
Projects
None yet
Development

No branches or pull requests