Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Palemoon Sound
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Thu Oct 15, 2015 8:36 pm    Post subject: [SOLVED] Palemoon Sound Reply with quote

Hi,

I've installed palemoon from the palemoon overlay:
https://github.com/deuiore/palemoon-overlay

Any idea why would it output the sound to s/pdif 1 (HDMI) instead of my main soundcard?
Or where can i change or control that? it complies with alsa but i didn't find anything in alsa or pusleaudio or palemoon settings to help me change that.


Last edited by Troopo on Mon Nov 16, 2015 9:52 pm; edited 1 time in total
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Sun Oct 18, 2015 7:52 pm    Post subject: Reply with quote

Any ideas on how to change that in palemoon?
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 3148
Location: Illinois, USA

PostPosted: Sun Oct 18, 2015 9:20 pm    Post subject: Reply with quote

alsa-mixer?
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Mon Oct 19, 2015 6:37 am    Post subject: Reply with quote

Tony0945 wrote:
alsa-mixer?


alsa-mixer doesn't allow application control only channels...
kmix only has firefox not palemoon (i don't know why).
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Mon Oct 19, 2015 11:30 am    Post subject: Reply with quote

It sounds like your default soundcard needs to be set in alsa.conf; or you can just not compile the HDMI (kernel) module.

I'm being vague as I haven't had to do this for ages: I just don't build HDMI stuff as it's only on my graphics-card, and I don't use the machine for video output on my television.
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Tue Oct 20, 2015 7:41 pm    Post subject: Reply with quote

steveL wrote:
It sounds like your default soundcard needs to be set in alsa.conf; or you can just not compile the HDMI (kernel) module.

I'm being vague as I haven't had to do this for ages: I just don't build HDMI stuff as it's only on my graphics-card, and I don't use the machine for video output on my television.


Well unfortunately i do have a TV connected to my machine so i can't disable HDMI.
I've tried the other option of setting the default sound card with the following:
http://askubuntu.com/questions/150851/how-do-i-select-a-default-sound-card-with-alsa

Somehow it didn't have any impact so it's either wrong for gentoo or the problem is with palemoon.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 3148
Location: Illinois, USA

PostPosted: Tue Oct 20, 2015 9:40 pm    Post subject: Reply with quote

Troopo wrote:
Somehow it didn't have any impact so it's either wrong for gentoo or the problem is with palemoon.


Try emerging firefox-bin just for a test. If they both do it it's unlikely (but still possible) that it's a palemoon problem. If it works OK on firefox, definitely it's palemoon.
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Tue Oct 20, 2015 9:45 pm    Post subject: Reply with quote

Ok quick addition on this.

I'm using KDE and i want Kmix to recognize Palemoon, then i can control it and defer it to any sound device i want.

I'm only seeing Firefox there:
http://s15.postimg.org/7voedfpxn/snapshot2.png


Tony0945 wrote:
Troopo wrote:
Somehow it didn't have any impact so it's either wrong for gentoo or the problem is with palemoon.


Try emerging firefox-bin just for a test. If they both do it it's unlikely (but still possible) that it's a palemoon problem. If it works OK on firefox, definitely it's palemoon.


Firefox works fine. :)
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 3148
Location: Illinois, USA

PostPosted: Wed Oct 21, 2015 3:42 pm    Post subject: Reply with quote

Troopo wrote:
Firefox works fine. :)


Try using this ebuild that I wrote that downloads from palemoon's binary repository
save it to: /usr/local/portage/www-client/palemoon-bin-25.7.3.ebuild http://dpaste.com/3M4WYKX I coped the license statement on the website to create the palemoon license. You could also null out the the LICENSE= in the ebuild. In either case run "repoman manifest" to regenerate the manifest. The executable is symlinked to /usr/bin/palemoon-bin so that like firefox and firefox-bin you can run both.
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Wed Oct 21, 2015 7:52 pm    Post subject: Reply with quote

Tony0945 wrote:
Troopo wrote:
Firefox works fine. :)


Try using this ebuild that I wrote that downloads from palemoon's binary repository
save it to: /usr/local/portage/www-client/palemoon-bin-25.7.3.ebuild http://dpaste.com/3M4WYKX I coped the license statement on the website to create the palemoon license. You could also null out the the LICENSE= in the ebuild. In either case run "repoman manifest" to regenerate the manifest. The executable is symlinked to /usr/bin/palemoon-bin so that like firefox and firefox-bin you can run both.


Hmmm i've never done custom ebuilds before so when i tried that ebuild path and file were already there, i've tried editing the ebuild to replace it with your content but kept getting an error even with root:
"/usr/local/portage/www-client/palemoon-bin-25.7.3.ebuild" E212: Can't open file for writing

I've also tried the same with palemoon-bin instead of palemoon and it has the same issue...
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 3148
Location: Illinois, USA

PostPosted: Wed Oct 21, 2015 8:27 pm    Post subject: Reply with quote

What are the file permissions? Try changing them with chmod.
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Wed Oct 21, 2015 10:17 pm    Post subject: Reply with quote

Tony0945 wrote:
What are the file permissions? Try changing them with chmod.


Right forgot to mention that didn't work out as well.

Code:
ls: cannot access /usr/local/portage/www-client/: No such file or directory


And it's the same with Root.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Thu Oct 22, 2015 3:48 pm    Post subject: Reply with quote

Sounds like you need info on setting up a local overlay.

You will have to:
Code:
mkdir -p /usr/local/portage/www-client/palemoon-bin
before you can drop anything in there.

You need the extra path specifier for the pkgname, as a directory before you copy palemoon-bin-X.Y.ebuild in there (Tony's path was missing it.)

You'll likely need a files/ subdir, and don't forget to copy metadata.xml over either.

But: do not copy files/* from the portage tree: only the ones you need. Let repoman manifest complain, in preference to bulk-copying.

Not sure if this still works (from writeup of my first ebuild, which might give some insight):

Hint: use the ebuild command while you are developing your own ebuilds, eg:
Code:
ebuild /usr/local/portage/media-gfx/synfig/synfig-231.ebuild qmerge
ebuild /usr/local/portage/media-gfx/synfig/synfig-231.ebuild install

ISTR you need FEATURES=keep-work or something to avoid having to redo phases.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 3148
Location: Illinois, USA

PostPosted: Thu Oct 22, 2015 5:11 pm    Post subject: Reply with quote

steveL wrote:
Sounds like you need info on setting up a local overlay.

I had assumed he knew that. I have been wondering if that was a bad assumption.

steveL wrote:

You will have to:
Code:
mkdir -p /usr/local/portage/www-client/palemoon-bin
before you can drop anything in there.

You need the extra path specifier for the pkgname, as a directory before you copy palemoon-bin-X.Y.ebuild in there (Tony's path was missing it.)

Ooops! You are, of course, correct. Again I also assumed a level of expertise that I shouldn't have.

steveL wrote:
You'll likely need a files/ subdir, and don't forget to copy metadata.xml over either.

No files dir for this one, it just downloads the binarys, puts them in /opt and creates a symlink. I'm probably making the symlink wrong because uninstalling doesn't remove it, but it does work. I'd appreciate your guidance on this.

For completeness, the metadata.xml file goes into the same directory. It's in this pastebin https://bpaste.net/show/7ba791e0c79b
The license file goes into /usr/local/portage/licenses/Palemoon-FL (filename, not directory)and the text is here.[url] https://bpaste.net/show/dd6532a47c1d[/url]

This is strictly unofficial. I am going to try to get approval from Palemoon then I will put it on Sourceforge.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Thu Oct 29, 2015 11:20 am    Post subject: Reply with quote

Tony0945 wrote:
..it just downloads the binarys, puts them in /opt and creates a symlink. I'm probably making the symlink wrong because uninstalling doesn't remove it, but it does work. I'd appreciate your guidance on this.

Just use dosym, eg from puppetlabs-agent-1.4.2 [1] (which needs a for or a function): [2]
Code:
dosym /opt/puppetlabs/bin/facter /usr/bin/facter

In EAPI 5 (and above, when released) it will die for you, as will other "builtins".

That takes care of the relative aspects for you (which means the symlink works under any ROOT prefix.)
Quote:
This is strictly unofficial. I am going to try to get approval from Palemoon then I will put it on Sourceforge.

I'd try to get it into #gentoo-sunrise (New ebuild: "maintainer wanted" bug is the first step) and then push for it to enter main tree via a pull-request on github, since that's where the flock have gathered ;) by the looks of it.

[1] Found with:
Code:
qgrep -qN dosym


[2] Just a sketch, to show what dosym does:
Code:
# symcmd "/opt/$PN/bin" foo [bar baz..]
symcmd() {
   local p i # d
   p=${1%/}; shift
   [[ -n $p ]] || die "no bindir passed to: $FUNCNAME @ $BASH_LINENO"
   [[ -n $* ]] || return
#   d=${ED%/}
   for i; do
      [[ -z $i ]] && continue
   #   ln -s "../../$p/$i" "$d/usr/bin/$i" || die
      dosym "$p/$i" "/usr/bin/$i"
   done
}
As you see, it's a lot easier just to pass it a path from root, as in the common case, and reads much more cleanly.

Take a look in /usr/lib/portage/bin/ebuild-helpers/. (gack ;)

HTH,
steveL

edit: ln: use $p and $i for comparison


Last edited by steveL on Fri Oct 30, 2015 9:22 am; edited 1 time in total
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 3148
Location: Illinois, USA

PostPosted: Thu Oct 29, 2015 3:39 pm    Post subject: Reply with quote

Thanks a bundle! I'd much rather use the portage tools than hack about. BTW, read this after your PM.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Fri Oct 30, 2015 9:22 am    Post subject: Reply with quote

Tony0945 wrote:
BTW, read this after your PM.

Cool, gotcha ;) Came here to check, heh.
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Sun Nov 01, 2015 12:32 am    Post subject: Reply with quote

Hey Guys,

Sorry for not updating i've been a little overloaded.

You were right to assume i've never worked with a local overlay or messed with unofficial ebuilds before so it's kinda a first time for me actually.
Following the instructions i've made some progress and i really want to finish this.

Unfortunately at this point i can't find the place i've saved the original ebuild and the link has expired....
Tony do you mind sharing it again?
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Sun Nov 01, 2015 7:59 pm    Post subject: Reply with quote

steveL wrote:
It sounds like your default soundcard needs to be set in alsa.conf; or you can just not compile the HDMI (kernel) module.

Troopo wrote:
Well unfortunately i do have a TV connected to my machine so i can't disable HDMI.
I've tried the other option of setting the default sound card with the following:
http://askubuntu.com/questions/150851/how-do-i-select-a-default-sound-card-with-alsa

Somehow it didn't have any impact so it's either wrong for gentoo or the problem is with palemoon.

I'd read over the alsa doc on multiple cards, as it explains the asound.conf side, and ofc you're then on the main site for docs.
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Sun Nov 01, 2015 11:00 pm    Post subject: Reply with quote

steveL wrote:
steveL wrote:
It sounds like your default soundcard needs to be set in alsa.conf; or you can just not compile the HDMI (kernel) module.

Troopo wrote:
Well unfortunately i do have a TV connected to my machine so i can't disable HDMI.
I've tried the other option of setting the default sound card with the following:
http://askubuntu.com/questions/150851/how-do-i-select-a-default-sound-card-with-alsa

Somehow it didn't have any impact so it's either wrong for gentoo or the problem is with palemoon.

I'd read over the alsa doc on multiple cards, as it explains the asound.conf side, and ofc you're then on the main site for docs.


Thanks Steve, even tho i'm not sure this is the way to resolve this i took the challenge :)

Spent some time and got around to Ordering multiple cards of the same type since i have only 1 sound card and it uses the same modules.

Code:

admin@PC~ $ cat /proc/asound/cards
 0 [PCH            ]: HDA-Intel - HDA Intel PCH
                      HDA Intel PCH at 0xf7500000 irq 27
 1 [NVidia         ]: HDA-Intel - HDA NVidia
                      HDA NVidia at 0xf7080000 irq 17


Code:

admin@PC ~ $ cat /proc/asound/modules
 0 snd_hda_intel
 1 snd_hda_intel


Unfortunately since it doesn't have a vid and a pid, the only option left is udev.

Code:

admin@PC ~ $ modinfo -p snd_hda_intel
index:Index value for Intel HD audio interface. (array of int)
id:ID string for Intel HD audio interface. (array of charp)
enable:Enable Intel HD audio interface. (array of bool)
model:Use the given board model. (array of charp)
position_fix:DMA pointer read method.(-1 = system default, 0 = auto, 1 = LPIB, 2 = POSBUF, 3 = VIACOMBO, 4 = COMBO). (array of int)
bdl_pos_adj:BDL position adjustment offset. (array of int)
probe_mask:Bitmask to probe codecs (default = -1). (array of int)
probe_only:Only probing and no codec initialization. (array of int)
jackpoll_ms:Ms between polling for jack events (default = 0, using unsol events only) (array of int)
single_cmd:Use single command to communicate with codecs (for debugging only). (bool)
enable_msi:Enable Message Signaled Interrupt (MSI) (bint)
power_save:Automatic power-saving timeout (in second, 0 = disable). (xint)
power_save_controller:Reset controller in power save mode. (bool)
align_buffer_size:Force buffer and period sizes to be multiple of 128 bytes. (bint)
snoop:Enable/disable snooping (bint)


This is where i was out of time since the guide for udev rules to alsa was very long...

Worth mentioning here that i have the following devices:
Code:

admin@PC ~ $ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: ALC889 Analog [ALC889 Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 1: ALC889 Digital [ALC889 Digital]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 7: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 8: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 9: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0


And the PC is connected to hw:0,0 while the TV is hw:1,7 and that has never changed.

So again i'm not sure this is the problem and it also doesn't explain why kmix is unable to show palemoon in the application list.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Mon Nov 02, 2015 5:15 pm    Post subject: Reply with quote

Are you sure they're both meant to use the same kernel-driver?

May well be so, but I've found hda audio to be a real pita; aiui you need to pass module parms in the kernel cmdline, but (finally) I just disabled it, and bought a USB card instead (which is what Griz told me to do at the start of the saga. ;)
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Mon Nov 02, 2015 8:28 pm    Post subject: Reply with quote

steveL wrote:
Are you sure they're both meant to use the same kernel-driver?

May well be so, but I've found hda audio to be a real pita; aiui you need to pass module parms in the kernel cmdline, but (finally) I just disabled it, and bought a USB card instead (which is what Griz told me to do at the start of the saga. ;)


No i'm not but i've given all i know and judging from the modules they seem to use the same one.

I for one am not planning to buy anything because of this especially when the problem only happens with palemoon i'm sure it's either the source or default configuration...
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Tue Nov 03, 2015 11:04 am    Post subject: Reply with quote

Have you tried IRC? #gentoo on chat.freenode.net or: .org

You'll get practically-instant help, and live support, from many people who know this stuff inside and out, and can talk you through the different options much more quickly.

Please don't forget to write up what eventually solves your issue here, so others can find the same fix.
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Fri Nov 06, 2015 7:19 pm    Post subject: Reply with quote

steveL wrote:
Have you tried IRC? #gentoo on chat.freenode.net or: .org

You'll get practically-instant help, and live support, from many people who know this stuff inside and out, and can talk you through the different options much more quickly.

Please don't forget to write up what eventually solves your issue here, so others can find the same fix.


Thank you but i think you are overestimating the quantity and quality of the answers you get from the channel as there are also time differences and other variations to consider.

Anyway i didn't get help here or in the IRC or in palemoon forums so far, still hoping tho and will update once i do.
Back to top
View user's profile Send private message
Troopo
Apprentice
Apprentice


Joined: 14 Jun 2015
Posts: 158

PostPosted: Mon Nov 16, 2015 9:51 pm    Post subject: Reply with quote

Final update:

It seems palemoon doesn't work with pulse-audio by default and kmix actually uses pulse-audio to control each app.
Issue was solved by building palemoon with "--enable-pulseaudio".

Thanks Everyone.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum