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

Package Broken #159

Closed
abhijithbrindav opened this issue May 10, 2023 · 1 comment
Closed

Package Broken #159

abhijithbrindav opened this issue May 10, 2023 · 1 comment

Comments

@abhijithbrindav
Copy link

abhijithbrindav commented May 10, 2023

import 'package:sqlite3/sqlite3.dart';

void main(){
print(sqlite3.version);
}

output i got:

Unhandled exception:
Invalid argument(s): Failed to load dynamic library 'libsqlite3.so': libsqlite3.so: cannot open shared object file: No such file or directory
#0 _open (dart:ffi-patch/ffi_dynamic_library_patch.dart:11:43)
#1 new DynamicLibrary.open (dart:ffi-patch/ffi_dynamic_library_patch.dart:22:12)
#2 _defaultOpen (package:sqlite3/src/ffi/load_library.dart:52:27)
#3 OpenDynamicLibrary.openSqlite (package:sqlite3/src/ffi/load_library.dart:127:12)
#4 sqlite3 (package:sqlite3/src/ffi/api.dart:15:39)
#5 main (file:///home/abi/IdeaProjects/tutorial/bin/tutorial.dart:6:9)
#6 _delayEntrypointInvocation. (dart:isolate-patch/isolate_patch.dart:297:19)
#7 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:192:26)


please make a guidance for simple crud operation in step by step.

@simolus3
Copy link
Owner

As its readme explains, the sqlite3 Dart package contains Dart bindings to the sqlite3 C library. Making the library available is not possible with a pure-Dart package, so package:sqlite3 does not do that.

If you have a Flutter app, you can depend on sqlite3_flutter_libs to make sure that sqlite3 is available. Outside of a Flutter app, you can install sqlite3 manually or through the package manager of your OS - the readme also describes how to do that.

please make a guidance for simple crud operation in step by step.

There's an example on how to run statements here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants