dprotti / infinity-plugin

music visualization plugin
GNU General Public License v2.0
11 stars 7 forks source link

Crash after initialization #1

Closed count0-krsk closed 8 years ago

count0-krsk commented 9 years ago

Good morning! I build your plugin in Lubuntu 14.04.2, kernel 3.19.0-28-lowlatency. When install and copied .so's into valid audacious directory (/usr/lib/i386-linux-gnu/audacious/Visualization), and after selecting plugin in Audacious options I have audacious[28872]: segfault at c193876c ip b6e24508 sp 79272540 error 5 in libc-2.19.so[b6db1000+1a8000]. But I can see window of plugin and some animation for 1 second or less. So, I think this happens where second portion of data sent from Audacious to your plugin. Please build plugin for Ubuntu and check, where problem was. G-Force for WinAmp was really amazing and many users want replacement for Linux.

dprotti commented 9 years ago

Thanks for your feedback. I'm in travel now. I'll take care of this as soon as I get access to an Ubuntu box.

Regards.

count0-krsk commented 8 years ago

Hello. How runs your journey? ;-) I test fork of your plugin from Cbke. It starts fine, but show black window. In console I see: \ (audacious:10017): WARNING **: Could not be opened file for loading effects I copy by hands file infinite_states in directory (not existed in my system, so I create it) /usr/local/share/audacious and all worked! But number of effects are so small (( They changes fast and repeated. And plays even if song paused, so I think they not depended on song data (( This so sad... How can I add more effects?

dprotti commented 8 years ago

Hi, thanks for your interest!

In order to reproduce the issue, I tried installing Lubuntu 14.04.3 on a Virtual Box, with no success. Installation aborted at the same point in my two attempts (causes the VM to crash).

Looking at https://github.com/CBke/infinity-plugin/commit/e81affc4b854719f24e9fd767e19215458a1fa88 I guess the crash on my current master comes from the usage of a deprecated Audacious API (audaciousremote*). @CBke could you please submit a PR of your https://github.com/CBke/infinity-plugin/commit/e81affc4b854719f24e9fd767e19215458a1fa88 into my repo? I would appreciate to have your changes.

On another hand I'll try to remove the hard-coded path in effects.c so as to avoid the installation issue of infinite_states.

Number of effects do not depend on song data. Displaying of current effect does. Song data feeds current effect and its sound spectrum gets intermixed with it.

For adding new effects:

This last key 'm' is missing on Readme. I'll take care of adding it.

Regards.

dprotti commented 8 years ago

Issue should be fixed after commit https://github.com/dprotti/infinity-plugin/commit/530666d24bd438ef2b9f9f37db4286b964d9e4e4 . I tested on Xubuntu 15.10 + Audacious 3.5. Can you please check if it works for you?

dprotti commented 8 years ago

@count0-krsk the time between effects was in the past configured through the Preferences dialog of the plugin. This dialog is currently not working (needs to be updated to new Audacious preferences API).

Meanwhile as a workaround you can manually edit ~/.audacious/infinity/infinity.ini ('teff' key).

count0-krsk commented 8 years ago

I will test it on the next week, if have enough time.

dprotti commented 8 years ago

Thanks!

count0-krsk commented 8 years ago

Hmm. For testing I need Audacious >= 3.5. I install 3.7, but when building plugin, it requires audclient library. I cannot find it in any repository, and read somewhere, what in new versions of audacious it is deprecated. Where did you find it?

dprotti commented 8 years ago

Thanks for checking this! In Xubuntu the packages are libaudclient2 and libaudclient-dev . Sources: last tarball and current repo.

Audacious < 3.5 included audclient. Audacious >= 3.5 not anymore, was splitted as a separate package. Hence the plugins using audclient (as infinity does through <prefix>/audacious/audctrl.h ) must require it separately.

count0-krsk commented 8 years ago

Ufff.... There was some difficulties. Building libaudclient from source failed with:

Entering directory src.
Entering directory libaudclient.
Successfully generated dependencies.
/usr/lib/gcc/i686-linux-gnu/4.8/../../../i386-linux-gnu/libdbus-1.a(libdbus_1_la-dbus-sysdeps-pthread.o): In function `_dbus_platform_rmutex_new':
(.text+0x7c): undefined reference to `pthread_mutexattr_init'
/usr/lib/gcc/i686-linux-gnu/4.8/../../../i386-linux-gnu/libdbus-1.a(libdbus_1_la-dbus-sysdeps-pthread.o): In function `_dbus_platform_rmutex_new':
(.text+0x8c): undefined reference to `pthread_mutexattr_settype'
/usr/lib/gcc/i686-linux-gnu/4.8/../../../i386-linux-gnu/libdbus-1.a(libdbus_1_la-dbus-sysdeps-pthread.o): In function `_dbus_platform_rmutex_new':
(.text+0xa5): undefined reference to `pthread_mutexattr_destroy'
/usr/lib/gcc/i686-linux-gnu/4.8/../../../i386-linux-gnu/libdbus-1.a(libdbus_1_la-dbus-sysdeps-pthread.o): In function `_dbus_platform_condvar_new':
(.text+0x1dc): undefined reference to `pthread_condattr_setclock'
collect2: error: ld returned 1 exit status
Failed to link libaudclient.so!

So, I found libaudclient2_3.5~rc2-dmo2_i386.deb package, and it step-by-step require install these files as "tree" dependence:

libcgmanager0_0.36-2ubuntu5_i386.deb
dbus_1.9.20-1ubuntu1_i386.deb              
libdbus-1-3_1.9.20-1ubuntu1_i386.deb
libgcrypt20_1.6.3-2ubuntu1.1_i386.deb
initramfs-tools_0.103ubuntu8_all.deb       
libgpg-error0_1.19-2_i386.deb
initramfs-tools-bin_0.103ubuntu8_i386.deb  libsystemd0_225-1ubuntu9.1_i386.deb
init-system-helpers_1.22ubuntu6_all.deb    lsb-base_4.1+Debian11ubuntu8_all.deb
libanyevent-perl_7.070-2build1_i386.deb    
perl-base_5.20.1-3_i386.deb
libapparmor1_2.9.2-0ubuntu2_i386.deb       upstart_1.13.2-0ubuntu13_i386.deb

After it, libaudclient installs. Thank, God! )) But... still not found by configure of infinity plugin. Because not have .pc file with him. I create audclient.pc:

prefix=/usr/lib/i386-linux-gnu
exec_prefix=${prefix}
data_dir=/usr/share/doc/libaudclient2
version=3.5-rc2
audacious_include_dir=/usr/include/audacious
lib_dir=${exec_prefix}/lib
Name: Audacious Client Library
Description: Remote control library for Audacious
Version: 3.5-rc2
Libs: -L${lib_dir} -laudclient
Cflags: -I${audacious_include_dir}

And copy it

sudo cp audclient.pc /usr/lib/i386-linux-gnu/
export 'PKG_CONFIG_PATH'="/usr/lib/i386-linux-gnu/"
./configure

config was OK! But... Make shows:

main.c:24:30: fatal error: audacious/plugin.h: No such file or directory
 #include <audacious/plugin.h>
                              ^
compilation terminated.

Ok, I install audacious-dev package. Restart make - same error. Copy *.h of audacious from installed path to created directory audacious in plugin build directory. Make restarted and....

In file included from ../audacious/plugin.h:24:0,
                 from main.c:24:
/usr/include/i386-linux-gnu/libaudcore/audio.h:129:61: error: unknown type name 'StereoVolume'
 void audio_amplify (float * data, int channels, int frames, StereoVolume volume);
                                                             ^
In file included from /usr/include/libaudcore/index.h:23:0,
                 from /usr/include/libaudcore/plugins.h:23,
                 from ../audacious/plugin.h:25,
                 from main.c:24:
/usr/include/libaudcore/templates.h:23:15: fatal error: new: No such file or directory
 #include <new>
               ^
compilation terminated.

Version of audacious-dev is 3.7.1-1~webupd8~trusty0_i386 Audacious has 3.7.1. I think, for debugging I need Lubuntu/Ubuntu not least 15.10 (I download dependency packages from it), but make error don't like audacious-dev is 3.7.1-1. Can you try to compile plugin for this version? If Lubuntu does not installs on VirtualBox, you can use LiveCD. And there is no difference between Lubuntu and Ubuntu, just in DE installed by default (LXDE vs Unity). Repositories and kernel are same.

dprotti commented 8 years ago

Thank a lot for your feedback. I'll work on this after May 20.

dprotti commented 8 years ago

@count0-krsk I read you installed deb package libaudclient2_3.5~rc2 (production package). Did you install also the development package libaudclient-dev_3.5~rc2 ?

dprotti commented 8 years ago

This thread talks about different issues. To summarize:

Then I'm closing this since the original reported issue was fixed. If you find any other issue please open a new issue report.

count0-krsk commented 8 years ago

I don't remember. Probably yes.  Thanks for fixing bugs. 

"That's one small step for man, one giant leap for mankind." 


Best regards ;-)

Суббота, 21 мая 2016, 8:41 +07:00 от Duilio Protti notifications@github.com:

I read you installed deb package libaudclient2_3.5~rc2 (production package). Did you installed also the development package libaudclient-dev_3.5~rc2 ? — You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub