gotk4
gotk4 copied to clipboard
could not determine kind of name for C.g_date_time_new_from_unix_local_usec
OS: Gentoo Linux Kernel: Linux version 6.6.41-gentoo-dist C Compiler: GNU GCC 13.3.1 Go compiler: go version go1.22.6 linux/amd64 glib package info:
dev-libs/glib-2.78.6::gentoo was built with the following:
USE="dbus elf mime static-libs xattr -debug -gtk-doc (-selinux) -sysprof -systemtap -test -utils" ABI_X86="32 (64) (-x32)"
FEATURES="userfetch protect-owned unmerge-logs network-sandbox assume-digests qa-unresolved-soname-deps sfperms xattr usersync news sandbox ipc-sandbox binpkg-docompress fixlafiles preserve-libs splitdebug binpkg-logs merge-wait unknown-features-warn binpkg-dostrip config-protect-if-modified distlocks ebuild-locks userpriv parallel-fetch unmerge-orphans fail-clean multilib-strict pid-sandbox usersandbox pkgdir-index-trusted buildpkg-live strict merge-sync"
gtk4 package info:
gui-libs/gtk-4.14.4-r1::gentoo was built with the following:
USE="X gstreamer introspection wayland (-aqua) -broadway -cloudproviders -colord -cups -examples -sysprof -test (-vulkan)" ABI_X86="(64)" CPU_FLAGS_X86="f16c"
After running go install -v libdb.so/dissent@latest, I got the following output:
github.com/diamondburned/gotk4/pkg/glib/v2
# github.com/diamondburned/gotk4/pkg/glib/v2
go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:15535:10: could not determine kind of name for C.g_date_time_new_from_unix_local_usec
go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:15585:10: could not determine kind of name for C.g_date_time_new_from_unix_utc_usec
go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:17060:10: could not determine kind of name for C.g_date_time_to_unix_usec
go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:48:42: could not determine kind of name for C.g_dir_get_type
go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:17177:4: could not determine kind of name for C.g_dir_unref
go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:50:42: could not determine kind of name for C.g_hmac_get_type
go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:9360:10: could not determine kind of name for C.g_log_writer_syslog
go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:60:42: could not determine kind of name for C.g_rand_get_type
What GLib and GTK versions do you have?
https://github.com/diamondburned/gotk4/pull/145 might've bumped it a bit too high...
Same issue on Gentoo box
Same on OpenSuse Leap 15.6:
go: downloading github.com/diamondburned/gotk4/pkg v0.3.1
go: downloading golang.org/x/sync v0.8.0
go: downloading github.com/KarpelesLab/weak v0.1.1
go: downloading go4.org/unsafe/assume-no-moving-gc v0.0.0-20231121144256-b99613f794b6
# github.com/diamondburned/gotk4/pkg/glib/v2
../../go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:15535:10: could not determine kind of name for C.g_date_time_new_from_unix_local_usec
../../go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:15585:10: could not determine kind of name for C.g_date_time_new_from_unix_utc_usec
../../go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:17060:10: could not determine kind of name for C.g_date_time_to_unix_usec
../../go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:48:42: could not determine kind of name for C.g_dir_get_type
../../go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:17177:4: could not determine kind of name for C.g_dir_unref
../../go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:50:42: could not determine kind of name for C.g_hmac_get_type
../../go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:9360:10: could not determine kind of name for C.g_log_writer_syslog
../../go/pkg/mod/github.com/diamondburned/gotk4/[email protected]/glib/v2/glib.go:60:42: could not determine kind of name for C.g_rand_get_type
Kernel: 6.4.0-150600.23.17-default Go: go version go1.23.1 linux/amd64 GTK: gtk4-devel 4.12.4-150600.3.3.1 GLib: libglib-2_0-0 2.78.6-150600.4.3.1
If this is seriously affecting your application, please consider downgrading gotk4/pkg to pkg/v0.2.2.
If this is seriously affecting your application, please consider downgrading
gotk4/pkgto pkg/v0.2.2.
I think we are all trying to use dissent, which uses gotk4 v0.3.1. Any solutions that are not downgrading dissent?
If this is seriously affecting your application, please consider downgrading
gotk4/pkgto pkg/v0.2.2.I think we are all trying to use dissent, which uses gotk4 v0.3.1. Any solutions that are not downgrading dissent?
can you use the prebuilt?
If this is seriously affecting your application, please consider downgrading
gotk4/pkgto pkg/v0.2.2.
Thanks, this is a working solution for me.
If this is seriously affecting your application, please consider downgrading
gotk4/pkgto pkg/v0.2.2.I think we are all trying to use dissent, which uses gotk4 v0.3.1. Any solutions that are not downgrading dissent?
can you use the prebuilt?
I like having the binaries optimized for my cpu with "-O3" and thin-lto. And ofc I trust source code just more than binaries.
And if it doesn't compile because there are symbols missing, there is always the possibility of the application crashing in runtime. (Thats an assumption, I am not a C dev)
And if it doesn't compile because there are symbols missing, there is always the possibility of the application crashing in runtime. (Thats an assumption, I am not a C dev)
Dissent doesn't use any of these symbols, so you're fine.
And if it doesn't compile because there are symbols missing, there is always the possibility of the application crashing in runtime. (Thats an assumption, I am not a C dev)
Dissent doesn't use any of these symbols, so you're fine.
Why does dissent require such a high glib version then? (to compile)
And if it doesn't compile because there are symbols missing, there is always the possibility of the application crashing in runtime. (Thats an assumption, I am not a C dev)
Dissent doesn't use any of these symbols, so you're fine.
Why does dissent require such a high glib version then? (to compile)
Because gotk4 is generated off the higher GLib version and Dissent requires that version.
You can downgrade gotk4 within Dissent and it'll probably work. I'm hesitant to provide more help if you're not familiar with Go development, but some of that is needed to build Go applications.