timetrap
timetrap copied to clipboard
Installation Issue
I'm hoping to get some help if possible. I don't really understand where the problem is. It first asked dor ruby-dev in an error, then for libsqlite3-dev but now for this error I can't make out what the problem is.
I haven't seen this error before.
I actually ported timetrap to rust in case you want to try it out :P it is a binary and bundles sqlite so you don't actually need it in the system.
I haven't seen this error before.
I actually ported timetrap to rust in case you want to try it out :P it is a binary and bundles sqlite so you don't actually need it in the system.
Hey, thank you for mentioning that. I Got and its workint great. Thanks man
I fixed this locally by cloning the gem and bumping the sqlite dependency to the 2.x branch.
I did try @categulario's tiempo - and it's really nice, except for me I couldn't get the note-editing to work at all, and for me I still want that functionality.
@patrickdavey I'd like to take a closer look at your problem, of course this is not the space to discuss it. Do you mind opening an issue mentioning your setup? (OS (and version), Shell (and version))
I created a PR that fixes this issue by loosening the dependency on sqlite3: https://github.com/samg/timetrap/pull/217
I think that I have the same error:
WARNING: You don't have /root/.local/share/gem/ruby/3.0.0/bin in your PATH,
gem executables will not run.
Building native extensions. This could take a while...
ERROR: Error installing timetrap:
ERROR: Failed to build gem native extension.
current directory: /root/.local/share/gem/ruby/3.0.0/gems/sqlite3-1.4.4/ext/sqlite3
/usr/bin/ruby extconf.rb
checking for sqlite3.h... yes
checking for pthread_create() in -lpthread... yes
checking for -ldl... yes
checking for sqlite3_libversion_number() in -lsqlite3... yes
checking for rb_proc_arity()... yes
checking for rb_integer_pack()... yes
checking for sqlite3_initialize()... yes
checking for sqlite3_backup_init()... yes
checking for sqlite3_column_database_name()... yes
checking for sqlite3_enable_load_extension()... yes
checking for sqlite3_load_extension()... yes
checking for sqlite3_open_v2()... yes
checking for sqlite3_prepare_v2()... yes
checking for sqlite3_int64 in sqlite3.h... yes
checking for sqlite3_uint64 in sqlite3.h... yes
creating Makefile
current directory: /root/.local/share/gem/ruby/3.0.0/gems/sqlite3-1.4.4/ext/sqlite3
make DESTDIR\= sitearchdir\=./.gem.20240617-18356-fgimp2 sitelibdir\=./.gem.20240617-18356-fgimp2 clean
current directory: /root/.local/share/gem/ruby/3.0.0/gems/sqlite3-1.4.4/ext/sqlite3
make DESTDIR\= sitearchdir\=./.gem.20240617-18356-fgimp2 sitelibdir\=./.gem.20240617-18356-fgimp2
compiling aggregator.c
compiling backup.c
compiling database.c
database.c: In function ‘exec_batch’:
database.c:748:57: error: passing argument 3 of ‘sqlite3_exec’ from incompatible pointer type [-Wincompatible-pointer-types]
748 | status = sqlite3_exec(ctx->db, StringValuePtr(sql), hash_callback_function, callback_ary, &errMsg);
| ^~~~~~~~~~~~~~~~~~~~~~
| |
| int (*)(VALUE, int, char **, char **) {aka int (*)(long unsigned int, int, char **, char **)}
In file included from ./sqlite3_ruby.h:25,
from database.c:1:
/usr/include/sqlite3.h:430:9: note: expected ‘int (*)(void *, int, char **, char **)’ but argument is of type ‘int (*)(VALUE, int, char **, char **)’ {aka ‘int (*)(long unsigned int, int, char **, char **)’}
430 | int (*callback)(void*,int,char**,char**), /* Callback function */
| ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
database.c:748:81: error: passing argument 4 of ‘sqlite3_exec’ makes pointer from integer without a cast [-Wint-conversion]
748 | status = sqlite3_exec(ctx->db, StringValuePtr(sql), hash_callback_function, callback_ary, &errMsg);
| ^~~~~~~~~~~~
| |
| VALUE {aka long unsigned int}
/usr/include/sqlite3.h:431:3: note: expected ‘void *’ but argument is of type ‘VALUE’ {aka ‘long unsigned int’}
431 | void *, /* 1st argument to callback */
| ^~~~~~
database.c:750:57: error: passing argument 3 of ‘sqlite3_exec’ from incompatible pointer type [-Wincompatible-pointer-types]
750 | status = sqlite3_exec(ctx->db, StringValuePtr(sql), regular_callback_function, callback_ary, &errMsg);
| ^~~~~~~~~~~~~~~~~~~~~~~~~
| |
| int (*)(VALUE, int, char **, char **) {aka int (*)(long unsigned int, int, char **, char **)}
/usr/include/sqlite3.h:430:9: note: expected ‘int (*)(void *, int, char **, char **)’ but argument is of type ‘int (*)(VALUE, int, char **, char **)’ {aka ‘int (*)(long unsigned int, int, char **, char **)’}
430 | int (*callback)(void*,int,char**,char**), /* Callback function */
| ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
database.c:750:84: error: passing argument 4 of ‘sqlite3_exec’ makes pointer from integer without a cast [-Wint-conversion]
750 | status = sqlite3_exec(ctx->db, StringValuePtr(sql), regular_callback_function, callback_ary, &errMsg);
| ^~~~~~~~~~~~
| |
| VALUE {aka long unsigned int}
/usr/include/sqlite3.h:431:3: note: expected ‘void *’ but argument is of type ‘VALUE’ {aka ‘long unsigned int’}
431 | void *, /* 1st argument to callback */
| ^~~~~~
make: *** [Makefile:246: database.o] Error 1
make failed, exit code 2
Gem files will remain installed in /root/.local/share/gem/ruby/3.0.0/gems/sqlite3-1.4.4 for inspection.
Results logged to /root/.local/share/gem/ruby/3.0.0/extensions/x86_64-linux/3.0.0/sqlite3-1.4.4/gem_make.out
Consider that I've already install the dependencies:
- sequel
- sqlite3
I think that I have the same error:
@mrp4sten Have you tried installing from the master branch after #217 was merged?
@mrp4sten I got the same error. Spent more than 30 minutes trying to figure out sqlite-devel and sqlite3 (1.4.2 vs 2.0.4). I give up.