This question already has answers here:
Undefined symbols for architecture armv7
(40 answers)
Closed 6 years ago.
I have created an new application with a simple test which works fine every time with iOSSimulator, but doesnt work when i try to run on my iPad. On my application, i only have the SQLite.NET-PCL 3.1.1 installed by nuget and my controller only makes a call to create a database.
When a try on iPad, the console give me the following error:
MTOUCH: error MT3001: Could not AOT the assembly '/Users/delogic/Projects/iosSingleView/iosSingleView/obj/iPhone/Debug/build-ipad3.1-9.3.2/mtouch-cache/Build/SQLite.Net.Platform.XamarinIOS.Unified.dll'
The following lines on the log caught my attention:
Undefined symbols for architecture armv7:
"_sqlite3_busy_timeout", referenced from:
wrapper_managed_to_native_SQLite_Net_Platform_XamarinIOS_SQLiteApiIOSInternal_sqlite3_busy_timeout_intptr_int in SQLite-5f40c7.o
"_sqlite3_close", referenced from:
wrapper_managed_to_native_SQLite_Net_Platform_XamarinIOS_SQLiteApiIOSInternal_sqlite3_close_intptr in SQLite-5f40c7.o
"_sqlite3_errmsg16", referenced from:
wrapper_managed_to_native_SQLite_Net_Platform_XamarinIOS_SQLiteApiIOSInternal_sqlite3_errmsg16_intptr in SQLite-5f40c7.o
"_sqlite3_finalize", referenced from:
wrapper_managed_to_native_SQLite_Net_Platform_XamarinIOS_SQLiteApiIOSInternal_sqlite3_finalize_intptr in SQLite-5f40c7.o
"_sqlite3_open_v2", referenced from:
wrapper_managed_to_native_SQLite_Net_Platform_XamarinIOS_SQLiteApiIOSInternal_sqlite3_open_v2_byte___intptr__int_intptr in SQLite-5f40c7.o
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I guess which for some reason, my file is missing some methods.Does anyone have the same problem? i will upload the project sample and the full log.
link for log and project download
i got this resolved. Its was a bug on xamarin studio which got fixed when i choosed the update channel to alpha
Related
I am building a simple app in order to test deployment of a console application.
When a try mkbundle according to the explanation of Microsoft I receive the next error:
ERROR: Unable to load assembly Xamarin.Mac' referenced by /Users/User/Projects/TestForDeploy/TestForDeploy/bin/Debug/TestForDeploy.exe'
I can deploy the app normally if I quit the reference to `Xamarin.Mac' from the app.
the next is the code of mkbundle that I used:
mkbundle -o /Users/User/desktop/TestFordeploy --simple /Users/User/Projects/TestForDeploy/TestForDeploy/bin/Debug/TestForDeploy.exe --library libxammac.dylib,/Users/User/Projects/TestFordeploy/TestFordeploy/bin/Debug/libxammac.dylib --config /Library/Frameworks/Mono.framework/Versions/Current/etc/mono/config --config /Library/Frameworks/Xamarin.Mac.framework/Versions/8.8.0.3/lib/64bits/full/Xamarin.Mac.dll --machine-config /Library/Frameworks/Mono.framework/Versions/Current/etc/mono/4.5/machine.config
I can deploy the app without the reference of Xamarin at this point and work with but it is important to me resolve this issue for future apps.
Thank you all.
Today I try to download from nuget package manager MarcTron to use Ads in my app and when I try to run the project in debug mode I receive this error:
Error MT5210: Native linking failed, undefined symbol: _GULIsLoggableLevel. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. (MT5210) (WeatherLocationInfo.iOS)
Another error is:
APMMeasurement networkUploadCompletionHandlerWithResponse: Error: ] in GoogleAppMeasurement(APMMeasurement_7b399ffe8f030717675febfa49640b5b.o) (WeatherLocationInfo.iOS)
When I delete the library everything is ok.
The same error I receive when I try to download Xamarin.Google.iOS.MobileAds.
How can I fix this issues ?
I am attempting to use AddictedCS SoundFingerprinting (https://github.com/AddictedCS/soundfingerprinting).
When I download any recent version and build with Visual Studio 2019 I get the expected output with no errors or warnings (SoundFingerprinting.dll).
The issue is that when I attempt to call functionality from the DLL in a .net console application I get errors relating to netstandard referencing.
I've attempted to add a new reference manually as the error message suggests, but get no further - same error occurs.
Here is my code, taken straight from the SoundFingerprinting example:
var hashedFingerprints = await FingerprintCommandBuilder.Instance
.BuildFingerprintCommand()
.From("C:/Users/Asher/Desktop/testSound.wav")
.UsingServices(audioService)
.Hash();
Here is the error log I am getting when compiling my console app with either mcs or csc:
C:\Users\Asher\Desktop\Raw_0.1>mcs TestProg.cs
-r:SoundFingerprinting.dll -r:protobuf-net.dll TestProg.cs(46,40): error CS0012: The type System.Object' is defined in an assembly that
is not referenced. Consider adding a reference to assembly
netstandard, Version=2.0.0.0, Culture=neutral,
PublicKeyToken=cc7b13ffcd2ddd51'
C:\Users\Asher\Desktop\Raw_0.1\SoundFingerprinting.dll (Location of
the symbol related to previous error) Compilation failed: 1 error(s),
0 warnings
I attempted this on my desktop PC running Windows 10, and on my Surface Pro 6 running Windows 10. I also attempted this using VS2017. The result was the same each time.
Also tried to use the library in Unity3D which caused a crash with no prompt or stacktrace output.
To Reproduce
Use: Windows 10, Visual Studio 2019
Steps to reproduce the behavior:
Download latest release (v7.2.0-beta3)
Build libraries
Attempt to call functionality from SoundFingerprinting.dll via a console application
I encountered exactly the same problem today. What fixed it for me was simply downloading the latest version of protobuf-net from nuget:
Install-Package protobuf-net -Version 3.0.101
Also, please don't paste pictures of code but the code itself next time.
I'm trying to build an, only iOS, app but I get two errors:
linker command failed with exit code 1 (use -v to see invocation)
Native linking failed for '/Users/{name}/Desktop/{application name}/{application name}/obj/iPhone/Debug/device-builds/iphone8.1-11.1.2/mtouch-cache/arm64/libSomething.dll.dylib'. Please file a bug report at http://bugzilla.xamarin.com
I get these errors with a dll generated from a binding of a (native obj-c) static library with XCode 9.2
I'm using Visual Studio 7.2 with Xamarin.iOS 11.6.1.2
I fixed it.
The error was in the Static Library, was missing two classes.
I've added these two in XCode and then works.
I have an UWP app written in C# which builds (VS 14.0.25425.01 Update 3 on Windows 10.0.14393, target version of the project is build 14393) and runs in Debug mode, but fails to build in Release mode with the following error:
Microsoft.NetNative.targets(640,5): error : MCG0004:InternalAssert Assert Failed: field not found during [UNKNOWN]
There are no further details, except for two warnings before, which I am not sure whether they are related to the problem:
Resources.System.Linq.Expressions.rd.xml(35): warning : ILTransform : warning ILT0027: Method 'CreateLambda' within 'System.Linq.Expressions.Expression' could not be found.
Resources.System.Linq.Expressions.rd.xml(91): warning : ILTransform : warning ILT0027: Method 'ParameterIsAssignable' within 'System.Linq.Expressions.Expression' could not be found.
Any suggestions what the issue could be related to?
This error will occur if you're using the Beta package for .NET UWP tools with VS 2015. The Beta package is only supported on 2017 as there are changes to how deployment/debugging work that we rely on. You should be able to avoid the issue by downgrading from "Microsoft.NETCore.UniversalWindowsPlatform": "5.3.0-beta2" to "Microsoft.NETCore.UniversalWindowsPlatform": "5.2.2"
edit: 5.3.0 has been published and works with VS2017 RC3+. More information here: https://blogs.msdn.microsoft.com/dotnet/2017/01/30/announcing-net-core-net-native-and-nuget-updates-in-vs-2017-rc/
Disclaimer: I work on the .NET Native compiler+runtime team.