from all_media_player/main.cc:8: ../gstreamer/gstreamermm/register.h: In function ‘GType Gst::register_mm_type(const gchar*)’: /usr/include/glib-2.0/glib/gatomic.h:117:19: error: argument 2 of ‘__atomic_load’ must not be a pointer to a ‘volatile’ type 117 | __atomic_load (gapg_temp_atomic, &gapg_temp_newval, __ATOMIC_SEQ_CST); \ | ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/glib-2.0/glib/gthread.h:260:7: note: in expansion of macro ‘g_atomic_pointer_get’ 260 | (!g_atomic_pointer_get (location) && \ ------------------------------------------------------------------- This is an unstable amd64 chroot image at a tinderbox (==build bot) name: 17.1_desktop_plasma_systemd-20210421-084009 ------------------------------------------------------------------- gcc-config -l: [1] x86_64-pc-linux-gnu-8.3.1 [2] x86_64-pc-linux-gnu-10.3.0 [3] x86_64-pc-linux-gnu-11.1.0 * clang version 12.0.0 Target: x86_64-pc-linux-gnu Thread model: posix InstalledDir: /usr/lib/llvm/12/bin /usr/lib/llvm/12 12.0.0 Python 3.8.9 Available Ruby profiles: [1] ruby26 (with Rubygems) [2] ruby30 (with Rubygems) * Available Rust versions: [1] rust-bin-1.51.0 * The following VMs are available for generation-2: *) AdoptOpenJDK 8.292_p10 [openjdk-bin-8] Available Java Virtual Machines: [1] openjdk-bin-8 system-vm The Glorious Glasgow Haskell Compilation System, version 8.10.4 timestamp(s) of HEAD at this tinderbox image: /var/db/repos/gentoo Wed Apr 28 08:35:16 UTC 2021 emerge -qpvO dev-cpp/gstreamermm [ebuild N ] dev-cpp/gstreamermm-1.10.0 USE="-doc -examples -test"
Created attachment 703218 [details] emerge-info.txt
Created attachment 703221 [details] dev-cpp:gstreamermm-1.10.0:20210428-085130.log
Created attachment 703224 [details] emerge-history.txt
Created attachment 703227 [details] environment
Created attachment 703230 [details] etc.portage.tar.bz2
Created attachment 703233 [details] logs.tar.bz2
Created attachment 703236 [details] temp.tar.bz2
Looks like there are two issues here: 1. Examples fail to build 2. Examples are always (attempted to) build, even with USE="-examples". The second issue is addressed in the bug 791958 and proposed patch allows to build gstreamermm without examples as a workaround of current problem.
While gstreamermm can be built without examples, it is still broken: $ cat gstreamermm-test.c #include <gstreamermm.h> int main() { return 0; } $ g++ $(pkg-config --cflags gstreamermm-1.0) -c gstreamermm-test.c In file included from /usr/include/glib-2.0/glib/gthread.h:32, from /usr/include/glib-2.0/glib/gasyncqueue.h:32, from /usr/include/glib-2.0/glib.h:32, from /usr/include/glibmm-2.4/glibmm/threads.h:30, from /usr/include/gstreamermm-1.0/gstreamermm/check.h:11, from /usr/include/gstreamermm-1.0/gstreamermm.h:63, from gstreamermm-test.c:1: /usr/include/gstreamermm-1.0/gstreamermm/register.h: In function ‘GType Gst::register_mm_type(const gchar*)’: /usr/include/glib-2.0/glib/gatomic.h:117:19: error: argument 2 of ‘__atomic_load’ must not be a pointer to a ‘volatile’ type 117 | __atomic_load (gapg_temp_atomic, &gapg_temp_newval, __ATOMIC_SEQ_CST); \ | ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/glib-2.0/glib/gthread.h:260:7: note: in expansion of macro ‘g_atomic_pointer_get’ 260 | (!g_atomic_pointer_get (location) && \ | ^~~~~~~~~~~~~~~~~~~~ /usr/include/gstreamermm-1.0/gstreamermm/register.h:114:9: note: in expansion of macro ‘g_once_init_enter’ 114 | if (g_once_init_enter (&gonce_data)) { | ^~~~~~~~~~~~~~~~~ $ pkg-config --cflags gstreamermm-1.0 -pthread -I/usr/include/gstreamermm-1.0 -I/usr/lib/gstreamermm-1.0/include -I/usr/include/giomm-2.4 -I/usr/lib/giomm-2.4/include -I/usr/include/glibmm-2.4 -I/usr/lib/glibmm-2.4/include -I/usr/include/sigc++-2.0 -I/usr/lib/sigc++-2.0/include -I/usr/include/gstreamer-1.0 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/gstreamer-1.0 -I/usr/include/orc-0.4 -I/usr/include/gstreamer-1.0 -I/usr/lib/libffi/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include So, the whole gstreamermm seems to be broken…
Created attachment 711162 [details, diff] gstreamermm-1.10.0-no-volatile.patch There is indeed an error in the /usr/include/gstreamermm-1.0/gstreamermm/register.h: it declares gsize gonce_data as volatile, while it should not: https://developer.gnome.org/glib/stable/glib-Threads.html#g-once-init-enter "While location has a volatile qualifier, this is a historical artifact and the pointer passed to it should not be volatile." Now both examples and test above builds fine. Gnome team, are you OK with this patch? Please also see bug 791958.
(In reply to Andrew Savchenko from comment #10) > Created attachment 711162 [details, diff] [details, diff] > gstreamermm-1.10.0-no-volatile.patch > > There is indeed an error in the > /usr/include/gstreamermm-1.0/gstreamermm/register.h: it declares gsize > gonce_data as volatile, while it should not: > https://developer.gnome.org/glib/stable/glib-Threads.html#g-once-init-enter > > "While location has a volatile qualifier, this is a historical > artifact and the pointer passed to it should not be volatile." > > Now both examples and test above builds fine. > > Gnome team, are you OK with this patch? > Please also see bug 791958. Could you open a merge request upstream at https://gitlab.gnome.org/GNOME/gstreamermm ? I see another merge request that fixes a double free() that seems like it should be accepted. Perhaps leio has the permissions to merge and make a release for us.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=139cd7a38152835009c149085aad04e53ddc4e1c commit 139cd7a38152835009c149085aad04e53ddc4e1c Author: Matt Turner <mattst88@gentoo.org> AuthorDate: 2021-08-04 22:25:36 +0000 Commit: Matt Turner <mattst88@gentoo.org> CommitDate: 2021-08-04 22:28:09 +0000 dev-cpp/gstreamermm: Add patch to build with gcc-11 Closes: https://bugs.gentoo.org/786444 Signed-off-by: Matt Turner <mattst88@gentoo.org> .../files/gstreamermm-1.10.0-no-volatile.patch | 17 +++++++++++++++++ dev-cpp/gstreamermm/gstreamermm-1.10.0.ebuild | 4 ++++ 2 files changed, 21 insertions(+)
(In reply to Matt Turner from comment #11) > (In reply to Andrew Savchenko from comment #10) > > Created attachment 711162 [details, diff] [details, diff] [details, diff] > > gstreamermm-1.10.0-no-volatile.patch > > > > There is indeed an error in the > > /usr/include/gstreamermm-1.0/gstreamermm/register.h: it declares gsize > > gonce_data as volatile, while it should not: > > https://developer.gnome.org/glib/stable/glib-Threads.html#g-once-init-enter > > > > "While location has a volatile qualifier, this is a historical > > artifact and the pointer passed to it should not be volatile." > > > > Now both examples and test above builds fine. > > > > Gnome team, are you OK with this patch? > > Please also see bug 791958. > > Could you open a merge request upstream at > https://gitlab.gnome.org/GNOME/gstreamermm ? > > I see another merge request that fixes a double free() that seems like it > should be accepted. Perhaps leio has the permissions to merge and make a > release for us. I've pushed this patch because it's less work for me than giving the package last rites. If you care about this package, please work upstream, or the next time I get a bug about it I will give it last-rites.