Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 167229 - media-sound/lastfmplayer-1.1.3 not detecting soundcard
Summary: media-sound/lastfmplayer-1.1.3 not detecting soundcard
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: Stefan Schweizer (RETIRED)
URL:
Whiteboard:
Keywords:
: 171573 (view as bug list)
Depends on:
Blocks:
 
Reported: 2007-02-16 16:55 UTC by Den_M
Modified: 2007-03-20 21:50 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
lastfmplayer-1.1.3-OSS.patch (lastfmplayer-1.1.3-OSS.patch,659 bytes, patch)
2007-03-11 00:28 UTC, David Grant
Details | Diff
lastfmplayer-1.1.3-r1.ebuild (lastfmplayer-1.1.3-r1.ebuild,1.85 KB, text/plain)
2007-03-11 00:29 UTC, David Grant
Details
lastfmplayer-1.1.3-r2.ebuild (lastfmplayer-1.1.3-r2.ebuild,1.88 KB, text/plain)
2007-03-19 04:14 UTC, David Grant
Details
13_alsa-r1.diff (13_alsa-r1.diff,71.66 KB, patch)
2007-03-19 04:16 UTC, David Grant
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Den_M 2007-02-16 16:55:41 UTC
media-sound/lastfmplayer-1.1.3 not detecting soundcard.

I have configured alsa soundcard hda-intel. Audacious, Psi, MPlayer, GNOME playing sounds very well, but when I push button "Play" in LastFMplayer it shows error "No soundcard detected".
Also as in bug #149618 there is no any soundcard in "Tools->Options->Radio-Soundcard" and one system "alsa".

I tried this application with alsa-driver and alsa kernel modules, result be the same.


Reproducible: Always




Portage 2.1.2-r9 (default-linux/amd64/2006.1, gcc-4.1.2, glibc-2.5-r0, 2.6.20-gentoo.nicevt.den_m x86_64)
=================================================================
System uname: 2.6.20-gentoo.nicevt.den_m x86_64 Intel(R) Pentium(R) D CPU 3.00GHz
Gentoo Base System version 1.12.9
Timestamp of tree: Fri, 16 Feb 2007 09:58:01 +0000
dev-java/java-config: 1.3.7, 2.0.31-r3
dev-lang/python:     2.4.4
dev-python/pycrypto: 2.0.1-r5
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.17
sys-devel/gcc-config: 1.3.14
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.20
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=nocona -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-march=nocona -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--quiet"
FEATURES="autoconfig distlocks metadata-transfer parallel-fetch sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LANG="ru_RU.UTF-8"
LC_ALL="en_US.UTF-8"
LINGUAS="en ru"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/usr/src"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac aalib acl acpi alsa amd64 ao audiofile bash-completion berkdb bidi bindist bitmap-fonts bonobo bzip2 cairo cddb cdparanoia cdr clamav cli cracklib crypt cups curl curlwrappers dbus dga dio directfb dlloader dri dts dv dvb dvd dvdr dvdread encode esd exif expat fbcon ffmpeg fftw firefox flac fortran gd gdbm gif gnome gpm graphviz gstreamer gtk gtk2 hal iconv imagemagick imlib ipv6 isdnlog jabber jack javascript jbig jpeg jpeg2k lcms libcaca libg++ libnotify libsamplerate lm_sensors mad matroska midi mikmod mime mng mp3 mpeg mplayer musepack ncurses nls nptl nptlonly offensive ogg openal opengl oss pam pcre pdf perl plotutils png portaudio posix ppds pppd python quicktime rdesktop readline reflection samba sdl session shorten sndfile sockets sound sox speex spell spl ssl startup-notification svg sysfs tcpd theora threads tiff truetype truetype-fonts type1-fonts unicode usb v4l v4l2 vcd vorbis wmf x264 xcomposite xine xinerama xml xorg xosd xpm xprint xscreensaver xv xvid zlib" ALSA_CARDS="hda-intel" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en ru" USERLAND="GNU" VIDEO_CARDS="fbdev i810 nv nvidia vga"
Unset:  CTARGET, INSTALL_MASK, LDFLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Comment 1 David Grant 2007-02-20 22:32:36 UTC
I've got the same problem.
Comment 2 Fabio Bonfante 2007-02-23 01:16:03 UTC
even after starting with an empty configuration by root, no soundcard
I have an hda-intel
-----
Portage 2.1.2-r9 (default-linux/amd64/2006.1/desktop, gcc-4.1.1, glibc-2.5-r0, 2.6.19-gentoo-r5 x86_64)
=================================================================
System uname: 2.6.19-gentoo-r5 x86_64 AMD Athlon(tm) 64 Processor 3200+
Gentoo Base System release 1.12.9
Timestamp of tree: Thu, 22 Feb 2007 05:30:01 +0000
distcc[17254] (dcc_mkdir) ERROR: mkdir /var/tmp/portage/.distcc/state failed: No such file or directory [disabled]
dev-java/java-config: 1.3.7, 2.0.31
dev-lang/python:     2.4.3-r4
dev-python/pycrypto: 2.0.1-r5
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.14
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r1
ACCEPT_KEYWORDS="amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=k8 -O2 -mmmx -msse -msse2 -m3dnow -pipe -fomit-frame-pointer -ftracer -maccumulate-outgoing-args"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /opt/wildfire/resources/security/ /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/splash /etc/terminfo"
CXXFLAGS="-march=k8 -O2 -mmmx -msse -msse2 -m3dnow -pipe -fomit-frame-pointer -ftracer -maccumulate-outgoing-args"
DISTDIR="/var/tmp/distfiles"
FEATURES="autoconfig distlocks metadata-transfer sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LANG="it_IT.UTF-8"
LC_ALL="it_IT.UTF-8"
LDFLAGS="-Wl,-O4"
LINGUAS="it"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/home/portage/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage /usr/local/overlays/sunrise /usr/local/overlays/enlightenment"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="7zip X a52 aac acpi alsa amd64 amuled apache2 asf audacious avi bash-completion beagle berkdb bitmap-fonts browserplugin bzip2 cairo cddb cdparanoia cdr chm cli cracklib crypt cups curl dbus directfb dri dv dvd dvdr dvdread eds emboss encode esd ethereal exif expat fam fbcon fbsplash ffmpeg firefox flac gcj gd gdbm gif glut gnome gphoto2 gpm gstreamer gtk gtk2 gtkhtml hal iconv idn ieee1394 imagemagick innodb ipod ipv6 isdnlog java jpeg jpeg2k lcms ldap libg++ lirc lzo mad matroska midi mikmod mng mod modplug mono mozsvg mp3 mpeg musepack mysql mythtv ncurses nfs nls nptl nptlonly nsplugin nvidia objc odbc ogg oggvorbis openal openexr opengl pam pcre pdf perl png postgres ppds pppd python qt qt3 qt4 quicktime readline reflection samba scanner sdl seamonkey session skins sndfile speex spell spl sqlite sse3 ssl startup-notification stream streamout svg tcpd tga theora threads tiff truetype truetype-fonts type1-fonts unicode usb userlocales v4l vcd vorbis webservices wmf wxwindows xine xinerama xml xml2 xorg xosd xpm xv xvid xvmc zlib" ALSA_CARDS="hda-intel" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="it" USERLAND="GNU" VIDEO_CARDS="nvidia"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, MAKEOPTS, PORTAGE_RSYNC_EXTRA_OPTS

Comment 3 Bill Skellenger 2007-03-08 02:53:02 UTC
I've got the same problem guys, and found that some people on the Last.FM forum are using OSS.  Here's why I love Gentoo:

ebuild /path/to/media-sound/lastfmplayer/lastfmplayer-1.1.3.ebuild fetch
ebuild /path/to/media-sound/lastfmplayer/lastfmplayer-1.1.3.ebuild unpack

Now move to:
/var/tmp/portage/lastfmplayer-1.1.3/work/last.fm-1.1.3/src/rtaudioplayback

And edit the file rtaudioplayback.cpp, at line 206:

        #ifdef Q_WS_X11
        //api = RtAudio::LINUX_ALSA;
        api = RtAudio::LINUX_OSS;
        #endif

Then:
ebuild /path/to/media-sound/lastfmplayer/lastfmplayer-1.1.3.ebuild compile
ebuild /path/to/media-sound/lastfmplayer/lastfmplayer-1.1.3.ebuild qmerge

I'm listening to the Last.fm player right now.  :)
Comment 4 Bill Skellenger 2007-03-10 20:25:47 UTC
Oops, don't forgot the "install" step:

  ebuild /path/to/media-sound/lastfmplayer/lastfmplayer-1.1.3.ebuild compile
+ ebuild /path/to/media-sound/lastfmplayer/lastfmplayer-1.1.3.ebuild install
  ebuild /path/to/media-sound/lastfmplayer/lastfmplayer-1.1.3.ebuild qmerge

Comment 5 David Grant 2007-03-11 00:28:18 UTC
Created attachment 112874 [details, diff]
lastfmplayer-1.1.3-OSS.patch

Patch to modify the source as Bill mentioned.
Comment 6 David Grant 2007-03-11 00:29:49 UTC
Created attachment 112875 [details]
lastfmplayer-1.1.3-r1.ebuild

updated ebuild to apply the OSS patch.

Works, but wasn't much help for me as I wasn't able to start lastfm and have it work, unless I shut down all other sound-card-using programs first. It would be nice if it worked with ALSA.
Comment 7 Bill Skellenger 2007-03-11 19:29:03 UTC
> Works, but wasn't much help for me as I wasn't able to start lastfm and have it
> work, unless I shut down all other sound-card-using programs first. It would be
> nice if it worked with ALSA.

Agreed, this is the sentiment on the Last.fm forum as well.  A couple more points:

1.  When you close the lastfm player (after it was compiled to use OSS), make sure to also kill the tray icon that it creates.  You may find that it seems to still have some sort of lock on the audio device.  I did:

wskellenger@gladstone ~ $ ps -ae | grep last
 6359 ?        00:00:00 last.fm
 6361 ?        00:03:04 last.fm.app

And had to kill these processes manually, then I got control of the card back.

2.  Back to the ALSA issue: lastfm does a little bit of logging in /opt/lastfm, but you'll either have to change permissions for that directory or run lastfm from the console as root to see what's going on.

Check the playback.log file and see what kind of error message you get when compiled with ALSA support.  This is what I'm getting:

070308 01:05:02 - 3072001712 - L1
  Initialising RtAudio failed. RtAudio error type: 7 Message: RtApi: unable to open specified device(s) with given stream parameters: 
    RtApiAlsa: error setting sample rate (44100) on device (hw:AudioPCI,0): Invalid argument.



Comment 8 David Li 2007-03-12 10:31:40 UTC
Hmm, that's weird. A lot of apps should not work or play correctly if your sound card doesn't support 44.1 KHz: Audios CD's and generally a lot of music files are 44.1 KHz. If that's the case, you should probably look into using the samplerate converter in alsa-plugins (USE=libsamplerate).
Comment 9 Fabio Bonfante 2007-03-19 01:01:48 UTC
maybe can be useful to solve alsa issues... i'm going to bed now, it's quite late here... somebody want make the first try? (take care, the alsa diff patch it's very invasive...)

night

http://mehercule.net/staticpages/index.php/lastfm
Comment 10 David Grant 2007-03-19 04:01:38 UTC
Here goes, I got the patch to apply and it is compiling right now. Just in case anyone else was starting on this...
Comment 11 David Grant 2007-03-19 04:12:06 UTC
Patch applied and works great. I tested it and ran it at the same time as amarok. Definitely using alsa and dmix. I would disagree that this patch is invasive. It only changes a few lines of code and adds the alsa stuff in a directory. Thanks fabio.

Here's the description of the alsa patch from mehercule.net: "Linux only: Use a new alsaaudio plugin based on xmms. It supports ALSA's default device, plays nicely with dmix, does format, rate, and channel conversion, is easier to debug, and probably fixes the following bugs: #354405, #366977, #373239, #388064. It also makes a great espresso." (those are debian bugs by the way). The original patch failed because it assumed a translation patch had been applied first.

Too bad these patches aren't in upstream. Also too bad that there are so many patches. It's a bitch to maintain them. Better to use branches in svn. If people really want a lot of these patches in lastfm, then maybe I'll maintain a branch and track the vendor sources and then provide a master patch.
Comment 12 David Grant 2007-03-19 04:14:54 UTC
Created attachment 113753 [details]
lastfmplayer-1.1.3-r2.ebuild
Comment 13 David Grant 2007-03-19 04:16:05 UTC
Created attachment 113754 [details, diff]
13_alsa-r1.diff

Sorry for the bad name. I wanted to stay true to the original name so it's clear which patch it is but I added the -r1 to show that it was modified a bit.
Comment 14 Fabio Bonfante 2007-03-19 15:22:56 UTC
(In reply to comment #11)
> Patch applied and works great. I tested it and ran it at the same time as
> amarok. Definitely using alsa and dmix. I would disagree that this patch is
> invasive. It only changes a few lines of code and adds the alsa stuff in a
> directory. Thanks fabio.
> 
Thanks to you for testing it!
It's really amazing wake up in the "morning" and see issues solved. Looking the patch now i'm awake i agree with you about it's invasiveness. 
Really "I LOVE THIS GAME!".

> Too bad these patches aren't in upstream. Also too bad that there are so many
> patches. It's a bitch to maintain them. Better to use branches in svn. If
> people really want a lot of these patches in lastfm, then maybe I'll maintain a
> branch and track the vendor sources and then provide a master patch.
> 

I posted a comment on the official announce about merging the patch upstream (where is it?) ...keep hoping!

http://www.lastfm.fr/user/muesli/journal/2007/01/26/326678/
Comment 15 Stefan Schweizer (RETIRED) gentoo-dev 2007-03-20 21:46:33 UTC
*** Bug 171573 has been marked as a duplicate of this bug. ***
Comment 16 Stefan Schweizer (RETIRED) gentoo-dev 2007-03-20 21:50:41 UTC
thank you committed!