buzztrax icon indicating copy to clipboard operation
buzztrax copied to clipboard

Buzztrax fails build due to Segmentation fault

Open plater opened this issue 2 years ago • 1 comments

Hi, I'm stumped as to what is failing here: gtkdoc-scan --module=buzztrax-gst --ignore-headers="gstdirectcontrolbinding.h gstbmlorc.h gstbmlorc-dist.h ../../../src/gst/sidsyn/envelope.h extfilt.h filter.h pot.h siddefs.h sidemu.h spline.h voice.h wave.h " ${_source_dir} --rebuild-types if grep -l '^..$' buzztrax-gst.types > /dev/null 2>&1 ; then
scanobj_options="";
gtkdoc-scangobj 2>&1 --help | grep >/dev/null "--verbose";
if test "$?" = "0"; then
if test "x" = "x1"; then
scanobj_options="--verbose";
fi;
fi;
CC="/usr/bin/bash ../../../libtool --tag=CC --mode=compile gcc -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -O2 -Wall -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -Wno-error=deprecated-declarations -Wno-error=format-truncation= -Wno-error=format-overflow= -Wno-error=incompatible-pointer-types -Wno-error=restrict" LD="/usr/bin/bash ../../../libtool --tag=CC --mode=link gcc -lgobject-2.0 -lglib-2.0 -O2 -Wall -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -Wno-error=deprecated-declarations -Wno-error=format-truncation= -Wno-error=format-overflow= -Wno-error=incompatible-pointer-types -Wno-error=restrict -flto=auto" RUN="/usr/bin/bash ../../../libtool --mode=execute" CFLAGS="-I../../../src/lib -I../../.. -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/libxml2 -I/usr/include/gstreamer-1.0 -I/usr/include/orc-0.4 -pthread -I/usr/include/gudev-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/libgsf-1 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/libxml2 -mmmx -msse -O0 -Wall -Werror -g -DGLIB_DISABLE_DEPRECATION_WARNINGS -DGDK_DISABLE_DEPRECATION_WARNINGS -DCLUTTER_DISABLE_DEPRECATION_WARNINGS -O2 -Wall -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -Wno-error=deprecated-declarations -Wno-error=format-truncation= -Wno-error=format-overflow= -Wno-error=incompatible-pointer-types -Wno-error=restrict" LDFLAGS="../../../libbuzztrax-gst.la ../../../libbuzztraxaudio.la ../../../libbuzztraxdec.la ../../../libgstbml.la ../../../libgstfluidsynth.la ../../../libgstsidsyn.la -lgthread-2.0 -Wl,--export-dynamic -lgmodule-2.0 -pthread -lglib-2.0 -lgio-2.0 -lxml2 -lgstcontroller-1.0 -lgstaudio-1.0 -lgstbase-1.0 -lgstfft-1.0 -lgstreamer-1.0 -lgobject-2.0 -lglib-2.0 -lasound -lgudev-1.0 -lgobject-2.0 -lglib-2.0 -lgsf-1 -lgobject-2.0 -lglib-2.0 -lxml2 -flto=auto"
gtkdoc-scangobj --type-init-func="extern void gst_init(gint ,gchar
*);gst_init(&argc,&argv)" $scanobj_options --module=buzztrax-gst;
else
for i in buzztrax-gst.actions buzztrax-gst.args buzztrax-gst.hierarchy buzztrax-gst.interfaces buzztrax-gst.prerequisites buzztrax-gst.signals ; do
test -f $i || touch $i ;
done
fi grep: warning: stray \ before - ../../../libtool: line 4732: warning: setlocale: LC_COLLATE: cannot change locale (en_ZA.UTF-8): No such file or directory

(buzztrax-gst-scan:3800): GLib-GObject-CRITICAL **: 09:18:51.764: g_param_spec_internal: assertion 'g_param_spec_is_valid_name (name)' failed 2022-10-23 09:18:51,765:scangobj.py:execute_command:1289:WARNING:Running scanner failed: -11, command: /usr/bin/bash ../../../libtool --mode=execute ./buzztrax-gst-scan make[3]: *** [Makefile:1180: scan-build.stamp] Error 245 make[3]: Leaving directory '/home/abuild/rpmbuild/BUILD/buzztrax-1f57d1b6ff55dd3d574f92039bb06a768d613d67/docs/reference/bt-gst' make[2]: *** [Makefile:9580: docs-bt-gst] Error 2 make[2]: Leaving directory '/home/abuild/rpmbuild/BUILD/buzztrax-1f57d1b6ff55dd3d574f92039bb06a768d613d67' make[1]: *** [Makefile:7775: all-recursive] Error 1 make[1]: Leaving directory '/home/abuild/rpmbuild/BUILD/buzztrax-1f57d1b6ff55dd3d574f92039bb06a768d613d67' make: *** [Makefile:3262: all] Error 2

plater avatar Oct 23 '22 09:10 plater

What appears to cause the build fail is: (buzztrax-gst-scan:391): GLib-GObject-CRITICAL **: 15:15:09.814: g_param_spec_internal: assertion 'g_param_spec_is_valid_name (name)' failed

Program received signal SIGSEGV, Segmentation fault. 0x00007ffff7616b28 in g_param_spec_string () from /usr/lib64/libgobject-2.0.so.0

Adding the built libraries to $LD_LIBRARY_PATH and running gdb gives: (gdb) bt #0 0x00007ffff7616b28 in g_param_spec_string () at /usr/lib64/libgobject-2.0.so.0 #1 0x00007ffff7e0ba06 in settings_foreach_func (data=0x7fffffffd370, name=0x74f880 "audio.alsa.device", type=) at src/gst/fluidsynth/fluidsynth.c:282 #2 0x00007ffff7d52198 in () at /usr/lib64/libfluidsynth.so.3 #3 0x00007ffff7e0bd3a in gstbt_fluid_synth_class_init (klass=0x736000) at src/gst/fluidsynth/fluidsynth.c:852 #4 gstbt_fluid_synth_class_intern_init (klass=0x736000) at src/gst/fluidsynth/fluidsynth.c:130 #5 0x00007ffff762681b in g_type_class_ref () at /usr/lib64/libgobject-2.0.so.0 #6 0x00000000004037a4 in get_object_types () at buzztrax-gst-scan.c:102 #7 main (argc=, argv=) at buzztrax-gst-scan.c:159

plater avatar Oct 23 '22 13:10 plater

gtk-doc tries to instantiate code to introspect them. Since I have not touch neither project, I'Ve tried to rebuild, but get trapped by -Werror and deprecated gtk+ api that has no replacement :/

ensonic avatar Oct 25 '22 20:10 ensonic

gtk-doc tries to instantiate code to introspect them. Since I have not touch neither project, I'Ve tried to rebuild, but get trapped by -Werror and deprecated gtk+ api that has no replacement :/

I use many "-Wno-error=" flags to build buzztrax, they increase in number with every gcc update. Buzztrax has made it into the next stable distribution but if it can't build it will be dropped from Tumbleweed.

plater avatar Oct 26 '22 07:10 plater

 ./autogen.sh --enable-deprecated --disable-debug --enable-gtk-doc

and it build here. I'll take a closer look on the weekend to see if I can do some more cleanups.

ensonic avatar Oct 27 '22 18:10 ensonic

it doesn't build for Tumbleweed with gcc-7, gcc-11 and gcc-12 so the problem lays with some other library that changed abi or something

plater avatar Oct 28 '22 13:10 plater

Hello all, I can see that the stack trace shows an exception somewhere in fluid synth; I wonder if this is due to my recent changes to the code in that area, perhaps in combination with some difference in configuration on Daves machine. Maybe an extra midi device present, or something.

ในวันที่ ส. 29 ต.ค. 2022 00:44 น. Dave Plater @.***> เขียนว่า:

it doesn't build for Tumbleweed with gcc-7, gcc-11 and gcc-12 so the problem lays with some other library that changed abi or something

— Reply to this email directly, view it on GitHub https://github.com/Buzztrax/buzztrax/issues/113#issuecomment-1295019372, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAG5TKBUBTATO6LU6BDHPGDWFPKFVANCNFSM6AAAAAARMGZEHM . You are receiving this because you are subscribed to this thread.Message ID: @.***>

dlbeswick avatar Oct 28 '22 14:10 dlbeswick

It has to be due to some updated dependency, it builds ok for the conservative Leap:15.4

plater avatar Oct 28 '22 16:10 plater

I am actually on Tumbleweed, use gcc-12 and everything builds:

gcc --version
gcc (SUSE Linux) 12.2.1 20220830 [revision e927d1cf141f221c5a32574bde0913307e140984]

Here is the full autogen output: https://gist.github.com/ensonic/ab5d4d75ab3d9f990c779b9a477d3ebf

ensonic avatar Oct 29 '22 14:10 ensonic

@ensonic when did you last update your Tumbleweed? I've tried on two systems, one up to date the other unfortunately didn't have most of the dependencies installed so most of them are the latest also. your build doesn't have "Check based unit tests : no" yours says yes Comparing the configure outputs you have this: checking for msgmerge... (cached) /usr/bin/msgmerge checking for ld used by GCC... /usr/x86_64-suse-linux/bin/ld -m elf_x86_64 checking if the linker (/usr/x86_64-suse-linux/bin/ld -m elf_x86_64) is GNU ld... yes checking for shared library run path origin... done

and I have this: checking for msgmerge... (cached) /usr/bin/msgmerge checking for ld used by GCC... /usr/x86_64-suse-linux/bin/ld -m elf_x86_64 checking if the linker (/usr/x86_64-suse-linux/bin/ld -m elf_x86_64) is GNU ld... egrep: warning: egrep is obsolescent; using grep -E yes checking for shared library run path origin... egrep: warning: egrep is obsolescent; using grep -E done

Which revision are you building, I'm building "c206774ce4510793d03860c2c2ffbcc7e264254a"

plater avatar Oct 30 '22 16:10 plater

> cat /etc/os-release 
NAME="openSUSE Tumbleweed"
# VERSION="20221027"
ID="opensuse-tumbleweed"
ID_LIKE="opensuse suse"
VERSION_ID="20221027"
PRETTY_NAME="openSUSE Tumbleweed"
ANSI_COLOR="0;32"
CPE_NAME="cpe:/o:opensuse:tumbleweed:20221027"
BUG_REPORT_URL="https://bugs.opensuse.org"
HOME_URL="https://www.opensuse.org/"
DOCUMENTATION_URL="https://en.opensuse.org/Portal:Tumbleweed"
LOGO="distributor-logo-Tumbleweed"
> git describe 
RELEASE_0_10-555-g833287c6
> git log --oneline | head -n5
833287c6 Crude custom machine graphics
c206774c Song title stays unset unless explicitly set by user
640877a4 Make sure any patterns beyond the song "end" are saved and restored.
6a5de1a4 Revert "song-io: use non deprecated functions"
ee997b34 song-io: use non deprecated functions

ensonic avatar Oct 30 '22 17:10 ensonic

I've tried but no success in getting past the "(buzztrax-gst-scan:7496): GLib-GObject-CRITICAL **: 11:21:30.310: g_param_spec_internal: assertion 'g_param_spec_is_valid_name (name)' failed 2023-02-07 11:21:30,311:scangobj.py:execute_command:1289:WARNING:Running scanner failed: -11, command: /bin/sh ../../../libtool --mode=execute ./buzztrax-gst-scan" error. Now there's https://bugzilla.opensuse.org/show_bug.cgi?id=1207939 as a result of the build failure. I'm going to have to delete the package if it can't be fixed. I've used the same configure options as in your comment: --enable-deprecated --disable-debug --enable-gtk-doc have to use autogen --noconfigure and the %configure but it fails if plain autogen is used anyway. see https://build.opensuse.org/package/show/home:plater/buzztrax

plater avatar Feb 07 '23 14:02 plater

David, thanks for your help. As sad as it is, this is probably the way of time then. There has never been enough interest from developers side to keep up with the moving parts of the dependencies :/

ensonic avatar Mar 05 '23 15:03 ensonic

It will still be in multimedia:apps, Leap:15.4 still builds

plater avatar Mar 06 '23 13:03 plater

Builds for the next Leap:15.5 as well

plater avatar Mar 06 '23 15:03 plater