gotk3 / gotk3

Go bindings for GTK3
ISC License
2.11k stars 230 forks source link

Methods deprecated in glib 2.68 #785

Open firelizzard18 opened 3 years ago

firelizzard18 commented 3 years ago

glib 2.68 deprecated g_binding_get_source and g_binding_get_target. Calls to these should be replaced with their dup versions:

# github.com/gotk3/gotk3/glib
cgo-gcc-prolog: In function ‘_cgo_57bc047156bf_Cfunc_g_binding_get_source’:
cgo-gcc-prolog:71:2: warning: ‘g_binding_get_source’ is deprecated: Use 'g_binding_dup_source' instead [-Wdeprecated-declarations]
In file included from /usr/include/glib-2.0/glib-object.h:22,
                 from /usr/include/glib-2.0/gio/gioenums.h:28,
                 from /usr/include/glib-2.0/gio/giotypes.h:28,
                 from /usr/include/glib-2.0/gio/gio.h:26,
                 from ../../go/pkg/mod/github.com/gotk3/gotk3@v0.5.3-0.20210601054727-c6f993830205/glib/gbinding.go:3:
/usr/include/glib-2.0/gobject/gbinding.h:112:23: note: declared here
  112 | GObject *             g_binding_get_source          (GBinding *binding);
      |                       ^~~~~~~~~~~~~~~~~~~~
cgo-gcc-prolog: In function ‘_cgo_57bc047156bf_Cfunc_g_binding_get_target’:
cgo-gcc-prolog:107:2: warning: ‘g_binding_get_target’ is deprecated: Use 'g_binding_dup_target' instead [-Wdeprecated-declarations]
In file included from /usr/include/glib-2.0/glib-object.h:22,
                 from /usr/include/glib-2.0/gio/gioenums.h:28,
                 from /usr/include/glib-2.0/gio/giotypes.h:28,
                 from /usr/include/glib-2.0/gio/gio.h:26,
                 from ../../go/pkg/mod/github.com/gotk3/gotk3@v0.5.3-0.20210601054727-c6f993830205/glib/gbinding.go:3:
/usr/include/glib-2.0/gobject/gbinding.h:116:23: note: declared here
  116 | GObject *             g_binding_get_target          (GBinding *binding);
      |                       ^~~~~~~~~~~~~~~~~~~~
micwoj92 commented 3 years ago

"duplicate" of #762

MJacred commented 3 years ago

@andre-hub: as @micwoj92 said, this is a duplicate of #762. please close this issue