ostreedev / ostree-go

Golang bindings for httt://github.com/ostreedev/ostree
Other
48 stars 24 forks source link

Build failure on Fedora 29. #28

Closed cedws closed 5 years ago

cedws commented 5 years ago

I'm currently trying to build a project (on Fedora 29) that has ostree-go as a dependency.

This is the version of glib2-devel that I have:

Installed Packages
Name         : glib2-devel
Version      : 2.58.3
Release      : 1.fc29
Arch         : x86_64
Size         : 2.7 M
Source       : glib2-2.58.3-1.fc29.src.rpm
Repo         : @System
From repo    : updates
Summary      : A library of handy utility functions
URL          : http://www.gtk.org
License      : LGPLv2+
Description  : The glib2-devel package includes the header files for the GLib library.

The compilation error:

# github.com/sjoerdsimons/ostree-go/pkg/otbuiltin
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go:16:
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h: In function ‘_g_clear_object’:
/usr/include/glib-2.0/glib/gmem.h:121:18: warning: passing argument 1 of ‘g_object_unref’ discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       (destroy) (_ptr);                                                        \
                  ^~~~
/usr/include/glib-2.0/gobject/gobject.h:672:36: note: in expansion of macro ‘g_clear_pointer’
 #define g_clear_object(object_ptr) g_clear_pointer ((object_ptr), g_object_unref)
                                    ^~~~~~~~~~~~~~~
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h:51:3: note: in expansion of macro ‘g_clear_object’
   g_clear_object(object_ptr);
   ^~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gbinding.h:29,
                 from /usr/include/glib-2.0/glib-object.h:23,
                 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 /usr/include/ostree-1/ostree-types.h:26,
                 from /usr/include/ostree-1/ostree-async-progress.h:24,
                 from /usr/include/ostree-1/ostree.h:24,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go:17:
/usr/include/glib-2.0/gobject/gobject.h:494:64: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘volatile GObject *’ {aka ‘volatile struct _GObject *’}
 void        g_object_unref                    (gpointer        object);
                                                ~~~~~~~~~~~~~~~~^~~~~~
# github.com/sjoerdsimons/ostree-go/pkg/otbuiltin
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/checkout.go:12:
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h: In function ‘_g_clear_object’:
/usr/include/glib-2.0/glib/gmem.h:121:18: warning: passing argument 1 of ‘g_object_unref’ discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       (destroy) (_ptr);                                                        \
                  ^~~~
/usr/include/glib-2.0/gobject/gobject.h:672:36: note: in expansion of macro ‘g_clear_pointer’
 #define g_clear_object(object_ptr) g_clear_pointer ((object_ptr), g_object_unref)
                                    ^~~~~~~~~~~~~~~
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h:51:3: note: in expansion of macro ‘g_clear_object’
   g_clear_object(object_ptr);
   ^~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gbinding.h:29,
                 from /usr/include/glib-2.0/glib-object.h:23,
                 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 /usr/include/ostree-1/ostree-types.h:26,
                 from /usr/include/ostree-1/ostree-async-progress.h:24,
                 from /usr/include/ostree-1/ostree.h:24,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/checkout.go:13:
/usr/include/glib-2.0/gobject/gobject.h:494:64: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘volatile GObject *’ {aka ‘volatile struct _GObject *’}
 void        g_object_unref                    (gpointer        object);
                                                ~~~~~~~~~~~~~~~~^~~~~~
# github.com/sjoerdsimons/ostree-go/pkg/otbuiltin
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/commit.go:16:
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h: In function ‘_g_clear_object’:
/usr/include/glib-2.0/glib/gmem.h:121:18: warning: passing argument 1 of ‘g_object_unref’ discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       (destroy) (_ptr);                                                        \
                  ^~~~
/usr/include/glib-2.0/gobject/gobject.h:672:36: note: in expansion of macro ‘g_clear_pointer’
 #define g_clear_object(object_ptr) g_clear_pointer ((object_ptr), g_object_unref)
                                    ^~~~~~~~~~~~~~~
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h:51:3: note: in expansion of macro ‘g_clear_object’
   g_clear_object(object_ptr);
   ^~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gbinding.h:29,
                 from /usr/include/glib-2.0/glib-object.h:23,
                 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 /usr/include/ostree-1/ostree-types.h:26,
                 from /usr/include/ostree-1/ostree-async-progress.h:24,
                 from /usr/include/ostree-1/ostree.h:24,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/commit.go:17:
/usr/include/glib-2.0/gobject/gobject.h:494:64: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘volatile GObject *’ {aka ‘volatile struct _GObject *’}
 void        g_object_unref                    (gpointer        object);
                                                ~~~~~~~~~~~~~~~~^~~~~~
# github.com/sjoerdsimons/ostree-go/pkg/otbuiltin
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/deployment.go:12:
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h: In function ‘_g_clear_object’:
/usr/include/glib-2.0/glib/gmem.h:121:18: warning: passing argument 1 of ‘g_object_unref’ discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       (destroy) (_ptr);                                                        \
                  ^~~~
/usr/include/glib-2.0/gobject/gobject.h:672:36: note: in expansion of macro ‘g_clear_pointer’
 #define g_clear_object(object_ptr) g_clear_pointer ((object_ptr), g_object_unref)
                                    ^~~~~~~~~~~~~~~
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h:51:3: note: in expansion of macro ‘g_clear_object’
   g_clear_object(object_ptr);
   ^~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gbinding.h:29,
                 from /usr/include/glib-2.0/glib-object.h:23,
                 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 /usr/include/ostree-1/ostree-types.h:26,
                 from /usr/include/ostree-1/ostree-async-progress.h:24,
                 from /usr/include/ostree-1/ostree.h:24,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/deployment.go:13:
/usr/include/glib-2.0/gobject/gobject.h:494:64: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘volatile GObject *’ {aka ‘volatile struct _GObject *’}
 void        g_object_unref                    (gpointer        object);
                                                ~~~~~~~~~~~~~~~~^~~~~~
# github.com/sjoerdsimons/ostree-go/pkg/otbuiltin
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/init.go:13:
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h: In function ‘_g_clear_object’:
/usr/include/glib-2.0/glib/gmem.h:121:18: warning: passing argument 1 of ‘g_object_unref’ discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       (destroy) (_ptr);                                                        \
                  ^~~~
/usr/include/glib-2.0/gobject/gobject.h:672:36: note: in expansion of macro ‘g_clear_pointer’
 #define g_clear_object(object_ptr) g_clear_pointer ((object_ptr), g_object_unref)
                                    ^~~~~~~~~~~~~~~
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h:51:3: note: in expansion of macro ‘g_clear_object’
   g_clear_object(object_ptr);
   ^~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gbinding.h:29,
                 from /usr/include/glib-2.0/glib-object.h:23,
                 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 /usr/include/ostree-1/ostree-types.h:26,
                 from /usr/include/ostree-1/ostree-async-progress.h:24,
                 from /usr/include/ostree-1/ostree.h:24,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/init.go:14:
/usr/include/glib-2.0/gobject/gobject.h:494:64: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘volatile GObject *’ {aka ‘volatile struct _GObject *’}
 void        g_object_unref                    (gpointer        object);
                                                ~~~~~~~~~~~~~~~~^~~~~~
# github.com/sjoerdsimons/ostree-go/pkg/otbuiltin
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/log.go:14:
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h: In function ‘_g_clear_object’:
/usr/include/glib-2.0/glib/gmem.h:121:18: warning: passing argument 1 of ‘g_object_unref’ discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       (destroy) (_ptr);                                                        \
                  ^~~~
/usr/include/glib-2.0/gobject/gobject.h:672:36: note: in expansion of macro ‘g_clear_pointer’
 #define g_clear_object(object_ptr) g_clear_pointer ((object_ptr), g_object_unref)
                                    ^~~~~~~~~~~~~~~
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h:51:3: note: in expansion of macro ‘g_clear_object’
   g_clear_object(object_ptr);
   ^~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gbinding.h:29,
                 from /usr/include/glib-2.0/glib-object.h:23,
                 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 /usr/include/ostree-1/ostree-types.h:26,
                 from /usr/include/ostree-1/ostree-async-progress.h:24,
                 from /usr/include/ostree-1/ostree.h:24,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/log.go:15:
/usr/include/glib-2.0/gobject/gobject.h:494:64: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘volatile GObject *’ {aka ‘volatile struct _GObject *’}
 void        g_object_unref                    (gpointer        object);
                                                ~~~~~~~~~~~~~~~~^~~~~~
# github.com/sjoerdsimons/ostree-go/pkg/otbuiltin
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/prune.go:16:
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h: In function ‘_g_clear_object’:
/usr/include/glib-2.0/glib/gmem.h:121:18: warning: passing argument 1 of ‘g_object_unref’ discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       (destroy) (_ptr);                                                        \
                  ^~~~
/usr/include/glib-2.0/gobject/gobject.h:672:36: note: in expansion of macro ‘g_clear_pointer’
 #define g_clear_object(object_ptr) g_clear_pointer ((object_ptr), g_object_unref)
                                    ^~~~~~~~~~~~~~~
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h:51:3: note: in expansion of macro ‘g_clear_object’
   g_clear_object(object_ptr);
   ^~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gbinding.h:29,
                 from /usr/include/glib-2.0/glib-object.h:23,
                 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 /usr/include/ostree-1/ostree-types.h:26,
                 from /usr/include/ostree-1/ostree-async-progress.h:24,
                 from /usr/include/ostree-1/ostree.h:24,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/prune.go:17:
/usr/include/glib-2.0/gobject/gobject.h:494:64: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘volatile GObject *’ {aka ‘volatile struct _GObject *’}
 void        g_object_unref                    (gpointer        object);
                                                ~~~~~~~~~~~~~~~~^~~~~~
# github.com/sjoerdsimons/ostree-go/pkg/otbuiltin
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/remote.go:15:
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h: In function ‘_g_clear_object’:
/usr/include/glib-2.0/glib/gmem.h:121:18: warning: passing argument 1 of ‘g_object_unref’ discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       (destroy) (_ptr);                                                        \
                  ^~~~
/usr/include/glib-2.0/gobject/gobject.h:672:36: note: in expansion of macro ‘g_clear_pointer’
 #define g_clear_object(object_ptr) g_clear_pointer ((object_ptr), g_object_unref)
                                    ^~~~~~~~~~~~~~~
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h:51:3: note: in expansion of macro ‘g_clear_object’
   g_clear_object(object_ptr);
   ^~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gbinding.h:29,
                 from /usr/include/glib-2.0/glib-object.h:23,
                 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 /usr/include/ostree-1/ostree-types.h:26,
                 from /usr/include/ostree-1/ostree-async-progress.h:24,
                 from /usr/include/ostree-1/ostree.h:24,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/remote.go:16:
/usr/include/glib-2.0/gobject/gobject.h:494:64: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘volatile GObject *’ {aka ‘volatile struct _GObject *’}
 void        g_object_unref                    (gpointer        object);
                                                ~~~~~~~~~~~~~~~~^~~~~~
# github.com/sjoerdsimons/ostree-go/pkg/otbuiltin
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/sysroot.go:14:
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h: In function ‘_g_clear_object’:
/usr/include/glib-2.0/glib/gmem.h:121:18: warning: passing argument 1 of ‘g_object_unref’ discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       (destroy) (_ptr);                                                        \
                  ^~~~
/usr/include/glib-2.0/gobject/gobject.h:672:36: note: in expansion of macro ‘g_clear_pointer’
 #define g_clear_object(object_ptr) g_clear_pointer ((object_ptr), g_object_unref)
                                    ^~~~~~~~~~~~~~~
gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/builtin.go.h:51:3: note: in expansion of macro ‘g_clear_object’
   g_clear_object(object_ptr);
   ^~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gbinding.h:29,
                 from /usr/include/glib-2.0/glib-object.h:23,
                 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 /usr/include/ostree-1/ostree-types.h:26,
                 from /usr/include/ostree-1/ostree-async-progress.h:24,
                 from /usr/include/ostree-1/ostree.h:24,
                 from gocode/src/github.com/sjoerdsimons/ostree-go/pkg/otbuiltin/sysroot.go:15:
/usr/include/glib-2.0/gobject/gobject.h:494:64: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘volatile GObject *’ {aka ‘volatile struct _GObject *’}
 void        g_object_unref                    (gpointer        object);
                                                ~~~~~~~~~~~~~~~~^~~~~~

Thanks.

jlebon commented 5 years ago

Hmm, this is using https://github.com/sjoerdsimons/ostree-go it looks like? Also doesn't seems like there are any actual errors in the above, just warnings right?

cedws commented 5 years ago

You're right, I've filed this in the wrong place. Sorry about that.