android: build issue typemaps.x86_64.ll: error: Could not open input file: no such file or directory
Android application type
.NET Android (net7.0-android, net8.0-android, etc.)
Affected platform version
VS 2022 17.10 Preview 7
Description
When trying to debug my app, I sometimes get an issue like typemaps.x86_64.ll: error: Could not open input file: no such file or directory.
Another error I got was typemaps.armeabi-v7a.ll: error: Could not open input file: no such file or directory
This happens both in Visual Studio and on the command line using MSBuild.
The build error code is XA3006.
Steps to Reproduce
Not sure, but it is related to debugging on different devices having different processor architectures.
It happens e.g. when I try to deploy to my x86_64 emulator on my development machine after debugging via USB on a physical phone (which has an ARM processor).
Did you find any workaround?
No
Relevant log output
Please see the relevant tail of the logs below. The part before this (building the app) is common to all target devices and is working fine.
Skipping target "_LinkAssembliesNoShrink" because all output files are up-to-date with respect to the input files.
Skipping target "_GenerateJavaStubs" because all output files are up-to-date with respect to the input files.
Skipping target "_ManifestMerger" because all output files are up-to-date with respect to the input files.
Skipping target "_ConvertCustomView" because all output files are up-to-date with respect to the input files.
Skipping target "_AddStaticResources" because all output files are up-to-date with respect to the input files.
Skipping target "_GenerateEmptyAndroidRemapNativeCode" because all output files are up-to-date with respect to the input files.
Touching "obj\Debug
et8.0-android\stamp\_GeneratePackageManagerJava.stamp".
Skipping target "_GenerateAndroidAssetsDir" because all output files are up-to-date with respect to the input files.
Skipping target "_PrepareCreateBaseApk" because all output files are up-to-date with respect to the input files.
Skipping target "_CreateBaseApk" because all output files are up-to-date with respect to the input files.
Skipping target "_CompileJava" because all output files are up-to-date with respect to the input files.
[llc.EXE stderr] C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\34.0.95\tools\binutils\bin\llc.exe: error: C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\34.0.95\tools\binutils\bin\llc.exe: typemaps.x86_64.ll: error: Could not open input file: no such file or directory
XA3006: Could not compile native assembly file: typemaps.x86_64.ll
stderr | C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\34.0.95\tools\binutils\bin\llc.exe: error: C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\34.0.95\tools\binutils\bin\llc.exe: typemaps.x86_64.ll: error: Could not open input file: no such file or directory
Done building project "Anonymized.App.csproj" -- FAILED.
Build FAILED.
2>Deployment failed to Small_Phone_API_34.
2>Deploy failed
========== Build: 1 succeeded, 0 failed, 5 up-to-date, 0 skipped ==========
========== Build completed at 13:32 and took 11,768 seconds ==========
========== Deploy: 0 succeeded, 1 failed, 0 skipped ==========
========== Deploy completed at 13:32 and took 11,768 seconds ==========
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 26 (6 by maintainers)
Commits related to this issue
- Make sure `_GenerateJavaStubs` always generates native assembly Fixes: https://github.com/xamarin/xamarin-android/issues/8967 For some reason, sometimes the `typemap*.ll` files are sometimes removed... — committed to dotnet/android by grendello 2 years ago
- Make sure `_GenerateJavaStubs` always generates native assembly Fixes: https://github.com/xamarin/xamarin-android/issues/8967 For some reason, sometimes the `typemap*.ll` files are sometimes removed... — committed to dotnet/android by grendello 2 years ago
- Make sure `_GenerateJavaStubs` always generates native assembly Fixes: https://github.com/xamarin/xamarin-android/issues/8967 For some reason, sometimes the `typemap*.ll` files are sometimes removed... — committed to dotnet/android by grendello 2 years ago
- Make sure `_GenerateJavaStubs` always generates native assembly Fixes: https://github.com/xamarin/xamarin-android/issues/8967 For some reason, sometimes the `typemap*.ll` files are sometimes removed... — committed to dotnet/android by grendello 2 years ago
- [Xamarin.Android.Build.Tasks] fix `Inputs` for `_Generate*Java*` targets Fixes: https://github.com/dotnet/android/issues/8967 Context: https://github.com/dotnet/android/pull/9001 You can cause a bui... — committed to jonathanpeppers/xamarin-android by jonathanpeppers 2 years ago
- [Xamarin.Android.Build.Tasks] fix `Inputs` for `_Generate*Java*` targets (#9174) Fixes: https://github.com/dotnet/android/issues/8967 Context: https://github.com/dotnet/android/pull/9001 You can ... — committed to dotnet/android by jonathanpeppers 2 years ago
- [Xamarin.Android.Build.Tasks] fix `Inputs` for `_Generate*Java*` targets (#9174) Fixes: https://github.com/dotnet/android/issues/8967 Context: https://github.com/dotnet/android/pull/9001 You can ... — committed to dotnet/android by jonathanpeppers 2 years ago
@hansmbakker can you modify the
C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\34.0.95\tools\Xamarin.Android.Common.targetsfile and apply the following diff:And see if that fixes the issue?
@dellis1972 I have installed project-system-tools as requested. I have to be away until after the holiday so I will try to reproduce and send you the logs with my details as soon as I am able. Although it does work now, I am curious if building one of the other platforms has anything to do with this issue.
thank you… this solved the issue
gracias @grendello, también me funciono a mi esa solución
Thanks @grendello. It helped to me too.
@grendello I tried the change as well and it worked for me. I did not have to restart Visual Studio.
I’m off until Monday and will reply when I have a chance to do it