I’m currently trying to build a MAUI app (the successor to Xamarin) and the Windows variant does work as it should. It’s when I’m trying to build for Android (haven’t looked at iOS yet) that I run into the title’s error.
What I’ve done so far:
- Included the packages
Couchbase.Lite 3.0.2
andCouchbase.Lite.Support.Android 3.0.2
under the dependencies fornet7.0-Android
. - Edited
Platforms/Android/MainActivity.cs
to include the following code:
public class MainActivity : MauiAppCompatActivity
{
protected override void OnCreate(Bundle savedInstanceState)
{
base.OnCreate(savedInstanceState);
Couchbase.Lite.Support.Droid.Activate(this);
}
}
And then tried to run the application. These are the last lines from Output
:
Loaded assembly: Anonymously Hosted DynamicMethods Assembly [External]
[monodroid-assembly] Shared library 'LiteCore' not loaded, p/invoke 'c4log_enableFatalExceptionBacktrace' may fail
[monodroid-assembly] Shared library 'LiteCore' not loaded, p/invoke 'c4log_setBinaryFileLevel' may fail
[monodroid-assembly] Shared library 'LiteCore' not loaded, p/invoke 'c4log_getDomain' may fail
[monodroid-assembly] Shared library 'LiteCore' not loaded, p/invoke 'c4log_setLevel' may fail
[monodroid-assembly] Shared library 'LiteCore' not loaded, p/invoke 'c4log_getDomain' may fail
**System.DllNotFoundException:** 'LiteCore'
So, uh, did I overlook something?