9 ms·
PulseAudio requirement breaks Firefox on ALSA-only systems
- imode 10y agoon arch here. haven't seen the problem yet, and I'm on 52.0. why am I not affected? I don't have pulseaudio installed (only some client libraries. lib32-libpulse, to be precise). this doesn't look good. thanks for the post.
- steanne 10y agoarch is compiling it with alsa support, but only for a couple more versions. https://bugs.archlinux.org/task/53195 https://bugs.archlinux.org/task/53195
- imode 10y agothanks. this is pretty scary. guess I'll be using Chromium when that day comes, as I'd rather not run PulseAudio.
- kuschku 10y agoYou could volunteer to rewrite Firefox’s entire ALSA backend to add multiprocess support. That’s what caused this, because Mozilla doesn’t have the manpower to rewrite two backends, and so had to choose one (with the pulse backend being preferred, as the pulse maintainers help mozilla and fix bugs on their side, while mozilla reports getting no assistance or anything from the ALSA maintainers).
- imode 10y agoI wish I could. but I don't have the knowledge or the time.
- AstralStorm 10y agoI would but they'd have to hire me full time. (Yes, I'd be happy to work on other parts of the browser as well.) Sad reality is that they are trying to not hire competent people while having features implemented well. Mozilla is vastly understaffed for the magnitude of the project.
- tedmielczarek 10y agoWhile I would agree that we are vastly understaffed, we just don't have the resources to pay people to fix everything. We hire lots of extremely talented developers, but like all software projects everything is a tradeoff. We could pay someone to maintain ALSA support, but that would mean other things would not get fixed. Linux users are already a small fraction of the Firefox userbase (despite most Firefox developers using Linux as their main development environment), so how do we justify spending the resources to maintain an alternate audio backend that's only used by a small fraction of our Linux users? It's not very compelling.
- AstralStorm 10y agoIf it is such a problem, why not hide the backend behind a nice library instead of a sound server? Say, off the top of my head, libao (after getting Xiph to fix the license), PortAudio, libsoundio, OpenAL and OpenSL come to mind. There are probably more.
- deleted 10y ago[deleted]
- armistace 10y agoyou should be fine as arch are compiling their binary with alsa enabled https://git.archlinux.org/svntogit/packages.git/tree/trunk/PKGBUILD?h=packages/firefox https://git.archlinux.org/svntogit/packages.git/tree/trunk/P... line 97 for reference
- beedogs 10y agoI gave up on Firefox at the end of last year, and I don't miss it at all. If I hadn't already done it, though, this would've sent me over the edge. (I do not and will never run Pulse on any of my systems.) Currently using a stripped-down version of Chrome, and web browsing has never been better. Edit: the downvoting on this site is goddamned baffling sometimes. What about my comment has you guys offended today?
- corey_moncure 10y agoWhat's your specific beef with Pulseaudio?
- chao- 10y agoWhat is the stripped-down version of Chrome you use? Is it something prepackaged or something you've crafted by stripping yourself?
- adamnemecek 10y agoMaybe Chromium? https://www.chromium.org/Home https://www.chromium.org/Home It's prepackaged but I kind of lost track how it's different. It used to be that it didn't support flash but that might have changed.
- lallysingh 10y agoIt doesn't have some plugins or Google login (for bookmark/history sync).
- j_koreth 10y agoIt has Google sync the different is mostly in branding and in some codec support
- beedogs 10y agoCurrently, Iron browser. https://www.srware.net/en/software_srware_iron.php https://www.srware.net/en/software_srware_iron.php It's gone from "broken on most sites" to "pretty much totally usable" since about October.
- passive 10y agoI had a brief panic at just reading ALSA. I haven't used the linux desktop in years, but audio was always such a pain. I hope things have improved.
- widdma 10y agoPulseAudio is pretty good these days and typically works out of the box for most need. Per app volume is an amazing feature and switching sinks is a breeze. I often play music on my stereo (mobo sound card) and game audio on some headphones (audio over hdmi through monitor). Being able to switch them around live is great. However, like systemd, PulseAudio large and opinionated so it's not everyone's cup-of-tea.
- kuschku 10y agoSadly, pulse is also still quite fragile and has a massive latency. It’d be preferable if for Linux there was an audio server closer to what JACK is (although both JACK and JACK2 aren’t ideal either). (That said, I mix hardware mixing and pulse for my purposes)
- beedogs 10y agoI gave up long ago and simply use audio cards that do hardware mixing. There's no need for anything other than ALSA if you do it that way.
- kuschku 10y agoUnless you want to do filters or additional in/out channels, and more than the card supports. In my case, I use 3 audio cards, an internal one for speakers, a Behringer Xenxy Q502 for headphones and microphone, and a backend streaming to my phone (in case I wanna walk around the house listening to music via headphones). Mixing audio into streams for recording, live stream, headphones, etc isn’t easy even with hardware cards unless you spend a LOT of money.
- m45t3r 10y ago
- kuschku 10y agoWell, what did anyone expect? Mozilla has complained for quite a while that their ALSA backend hasn’t been supported or updated in years, and they don’t have the manpower to do so. (Especially with their marketshare falling below 8%). So, after calls for people to support it, this is the end result. It’d be delusional to expect them to support two audio backends, and completely rewrite both of them for multiprocess support, when ALSA is used by less than 1% of users (as seen by the Mozilla hardware survey results), and the work can be used better for the other 99% of users.
- awalton 10y agoUnfortunately, logic and sanity fall apart when you talk to hardcore Linux users and they get on their tirade about FREEDOM!!!! Check out absolutely any systemd thread for more evidence. Freedom has a high cost - attention, maintenance, and constant vigilance. This is something we are learning all too well in this current political climate in the US. It's something Open Source maintainers are learning as they climb in years and experience and their time becomes more and more precious. We used to tell people like these folk "Patches welcome," but then we learned that they give us those patches... and literally never maintain any aspect of them, so now we're stuck supporting their useless, broken, out of date features for years on end. Worse, some of them come with baked in security vulnerabilities, and still get left on by default because next to nobody knows what it actually does. But we sure as hell get yelled at when we try to remove those broken features - it becomes an uphill battle, every time. We've seen it for Linux device drivers for super obscure hardware, we've seen it for features in desktop applications and entire desktop environments, we're seeing it again in web browsers. If you aren't using PulseAudio, you have fully accepted that you are willing to be on the fringe <0.01% of Linux installs[1], and so you get to keep all of the pieces of your special configuration. Feel free to maintain your patches out of tree, and stop robbing the vast majority of users progress and the maintainer's time. It's your freedom to have the code and do what you want with it - they don't have to merge it into their code and support you for free. Forks welcome. Mozilla made the right call. Freedom has a price. [1]: by measure of software that I maintain on Linux - last I checked less than 100 installs reporting usage information use the non-Pulse backend, albeit I accept those same folk are likely the folk that would disable usage reporting, so we can never know with absolute certainty. I can't imagine Mozilla's numbers are greatly different than what I'm seeing.
- ars 10y agoI'm in the same boat, Firefox 52 broke ALSA, and Plugins. I need both. So I'm permanently on 51. Mozilla: You are making a mistake, revert both of these decisions! For example see: http://www.kongregate.com/forums/1-kongregate/topics/716510-announcement-official-npapi-unity-java-support-ending-in-firefox-on-march-7-2017 http://www.kongregate.com/forums/1-kongregate/topics/716510-...
- dublinben 10y agoIf you refuse to update, you should at least be on their ESR branch, which is 45. Don't run an insecure, out of date version just because of a single feature.
- djsumdog 10y agoFirefox is cross platform. It has to support Win32/64 sound, Linux (alsa/pulse), whatever the hell FreeBSD and MacOS use .. Back in 2013 I had a lot of issues with Steam games not running correctly with PulseAudio (lots of static instead of sound half the time I tried to start a game). Sometimes doing a killall on the pulseaudio server would help, sometimes it would not. On that machine, I added a -pulseaudio USE flag in Gentoo and removed it entirely. On my current machines, I do use Bluetooth audio and find PA easier to deal with. I also no longer play games on my Linux boxes. I'm also old enough to remember the horrors of ESound and the KDE one (whatever it was called) and how audio would constantly be out of sync. Pulse is a lot better and seems to do well today. Still Pulse has some huge limitations. Run two X servers and use either consolekit or systemd? Good luck trying to get audio to continue playing on both X servers at the same time. It won't. Want to run MPD as a system daemon? You'll need to figure out how to enable TCP in Pulseaudio. I don't run SystemD, but I do run Pulseaudio. Those are my choices. Gentoo still gives me that choice, which is why I use it as my home and work distro. Void is another great Linux distribution that gives you such choice as well. Like I started with, Firefox has to support a ton of audio backends for various operating systems. We're not talking about maintaining OSS support. Pulse still depends on ALSA in the Linux kernel for it to work, so ALSA isn't going away any time soon. There's no reason for Firefox to need to depend on that intermediary layer and remove direct access when that already exists.
- RSZC 10y agoI do run MPD as a system daemon, can't recall having to do anything crazy with Pulseaudio...
- djsumdog 10y agoMaybe your distro has it configured by default. I had to modify config (you can change the one in your home directory or the system on in /etc/pulseaudio/default) to include something like module-native-protocol-tcp auth-ip-acl=127.0.0.1 You could also use auth-anonymous=1 but if you're not careful with that, people can play stuff on your speakers. We use to mess with each other at work doing that. :-P
- 10y ago
- shmerl 10y agoWithout going into the whole "to use or not to use PulseAudio" debate, the problem seems to be the fact, that backend which Firefox uses for audio doesn't have anyone who maintains pure ALSA case. So either they need drop pure ALSA support, to find a maintainer or to change the backend. The last two are clearly harder.
- thehardsphere 10y agoWhy is it hard to find a maintainer? I mean, is it just a reflection of Firefox's declining popularity or is there some additional difficulty?
- shmerl 10y agoNo idea. Is it their own project, or some external one? If the later, the question would be for its developers.
- digi_owl 10y agoWelcome to the concept of CADT. Everyone is off chasing the latest shiny so they can pad their resume (and maybe do a bit of virtue signaling on the side). Its the same crap that has been going on in the Linux GUI world since the formation of Gnome.
- stefantalpalaru 10y ago> So either they need drop pure ALSA support, to find a maintainer or to change the backend. The best solution is to use a wrapper library like PortAudio: http://www.portaudio.com/ http://www.portaudio.com/
- thehardsphere 10y agoQuestion for people who are successfully avoiding having to use PulseAudio: is there any particular distro that you are using that you trust not to go down this road? I haven't used Linux as my daily driver for years but I've been looking at switching back recently. It seems a lot harder to avoid PA than it used to be.
- beedogs 10y agoIt's pretty simple to remove it from SuSE.
- thehardsphere 10y agoThat's a relief, I've always liked SuSE.
- badsock 10y agoIt's not for everyone, but try a BSD. When PulseAudio first started showing up everywhere, I thought it was an anomaly, but it was really a harbinger. Since then Linux has been getting more like Windows every year (unpredictable behaviour, resource-hungry, lots of churn, tons of complexity for little benefit). The FreeBSD audio driver is in the kernel, it's tiny, and I never think about because it's never once caused me problems (and I'm quick to notice latency, etc. issues). As someone mentioned elsewhere in the thread, by being an ALSA user you're already in a tiny minority of the Linux world. You might as well be using an OS where your values in are the majority - it's nice to not have to fight against the defaults.
- thehardsphere 10y agoI've been thinking about BSDs. I used to run a FreeBSD server a long time ago and I tend to like copies of the ports system that I've used on other OSes. How hard is it to upgrade major versions? I seem to remember that this was a pain at some point, but this was so long ago that my memory is fuzzy. Also, have you had any problems with hardware support? The machine I'm thinking of putting this on doesn't exist yet, so if there is a way I can avoid stupid hardware problems up front it would be useful to know about.
- bjt2n3904 10y agoWhy does everything Lennart Poettering makes have to break existing things?
- PotterWare 10y agoPulseAudio is a over-complicated piece of bloated shit, like every single project developed by Lennart Poettering. If this man had never entered software development, I would probably not had gone completely insane.
- coconut_crab 10y agoCan you please elaborate further? I think PulseAudio's timer based scheduling is a big improvement over interrupt driven one. Bluetooth audio just works, per application volume control, audio streaming and switching audio sink is painless, you can even configure your resampling algorithm. Even if you use pure ALSA you still have to use a sound mixing server (dmix) since most sound cards these days lack hw mixing. Okay, I understand that it breaks systems with badly written audio drivers, but can we really blame Pulseaudio for that?
- AstralStorm 10y agoIt breaks on systems with asynchronous drivers. (E.g. recording timed differently from playback) Those are allowed by ALSA APIs and are present in quite a few high profile embedded Linux devices.
- nomel 10y ago> recording timed differently from playback I'm not familiar with this, and google isn't helping. Do you mean the time between samples, during recording, isn't fixed?
- jcranmer 10y agoHonestly, as a developer, these sorts of vitriolic comments only make me want to fix these kinds of bugs less. There is real cost to supporting features, and very often, the decision basically amounts to having to choose which feature scarce resources is used for. So you have to be prepared to defend having to divert resources for pet features--keeping in mind that sometimes the other feature is "making sure it builds tomorrow." From what I can tell, the ALSA backend has been poorly maintained for some time. When the present state of affairs is deficient, and probably retarding code quality in other areas. If it's in a poor state for a long time, it's hard to argue that it is necessary to maintain support--or even that desupporting it will make a huge impact. If you want to convince me to support something, offering help would be a great start. It could be as little as offering to test and QA a feature, or as much as providing an implementation patch and offering to maintain it for the foreseeable future. Insulting my intelligence and issuing threats for noncompliance are just going to result in me ignoring you, perhaps after laughing at you for a bit. And remember, if you're not familiar with the relevant code, you're not really qualified to say how hard it is to actually do something. Code architectures may not be implemented the way you expect them to be, so what seems like it should be an obvious minor feature may turn out to require thousands of lines of changes (that was exactly how my first open source contribution turned out--what I thought should have been a five-line patch or so was really 1000 or so lines of changes).
- problems 10y agoIn this case it's just behind a use flag, but regardless it seems to me like this could be fixed with a relatively simple wrapping library. SDL for example supports outputting to OSS, ALSA, PulseAudio, ESD and with a patch, JACK. What you want to output to can be easily configured at runtime. You as a developer write the least code possible and only have to do the job once, your users get the benefit of picking any output system they please. I believe Gstreamer offers a similar system too which Mozilla already uses for video decoding on Linux. Additionally the same code can be used across other platforms entirely, not just Linux.
- dkbrk 10y agoMy system had been ALSA-only for many years, until this change forced me to install PulseAudio. About once a week the audio starts crackling and hissing, and I have to restart the Pulse server. Regardless of how old and unmaintained the ALSA backend was in firefox, it worked, and worked well; I never had a single problem with it.
- Laforet 10y agoOne major factor is security, everything that isn't being actively maintained is passively accumulating exploits. For example, debian switched from ffmpeg to libav and eventually back to ffmpeg again because the libav maintainers have consistently slow to act on bugs and security holes whereas ffmpeg was anything but despite having a much smaller team looking after it. Debian's own security team called the switch because it is not worth the manpower to maintain both codecs.
- AstralStorm 10y agoALSA itself is better maintained than PulseAudio actually. If they cannot find a developer to maintain ALSA backend, they must really be out of money and skill. Yes, pure ALSA is harder, but not that much harder.
- kuschku 10y ago> they must really be out of money and skill A browser dropping below 8% (except for Germany, which is the only country where Firefox is still leading at 43%) surely has different problems than catering to the 1% pure ALSA users of their Linux users, when the Linux users are already 1% of their overall user share. Especially when funding is dependent on market share...
- journey2 10y agoOn top of the ideological issues I see with things like PulseAudio, it has always given me headaches in practice. I've never had issues with ALSA, but now I need to install an audio server so it can talk to ALSA? These are strange, unfortunate times. I feel linux will eventually succeed at becoming Windows and it makes me sad.
- rexicus 10y ago> I've never had issues with ALSA You haven't been acquainted with asoundrc/dmix/alsamixer. ALSA is to Pulse as XFree86 is to Xorg, I feel no nostalgia for it at all.
- kasabali 10y ago> ALSA is to Pulse as XFree86 is to Xorg, I feel no nostalgia for it at all. No it is not. X.org is a fork of XFree86. Pulseaudio is a sound daemon built on top of ALSA.
- digi_owl 10y agoAnd there are times i wish i could roll back the clock to the XFree86 days. At least then you didn't need to herd a stampede of sub-projects to get a working X11 compiled.
- CaptSpify 10y agoHonestly, I get it. Alsa is not the future, unless someone steps up and maintains it. And it looks like that's not going to happen. I firmly believe that we should move on. But part of moving on requires that we look at PA's problems. Everytime a PA thread comes up, people disregard and yell at everyone who has a problem with PA. PA has a bad reputation for a reason, and it's not just Pottering hate (though that's likely part of it). It's that PA is not good software. It needs to be fixed. And until it is, you'll have people wanting to go back to software that "just worked".
- AstralStorm 10y agoWrong. ALSA is the main Linux audio backend. PulseAudio cannot output to sound devices without it. (only to network) So not supporting it is akin to not supporting audio output on Linux. Dropping PulseAudio is fine if they want to reduce maintenance load, as it is optional, unlike ALSA.
- majewsky 10y agoHave you looked at the actual APIs? After last week's announcement, I talked to a friend who has, and apparently the PulseAudio API is much more straight-forward than the ALSA one. He voiced understanding for Firefox supporting PulseAudio instead of ALSA. EDIT: Also, arguing that Firefox needs to support ALSA instead of PulseAudio because "PulseAudio cannot output to sound devices to ALSA" is similar to saying Firefox should be able to issue SATA commands directly because filesystems would not work without that.
- AstralStorm 10y agoNo, VFS is a valid kernel interface, as is ALSA. Your analogy is wrong and pointless. This is more similar to removing all support for files and requiring everyone to install MySQL.
- majewsky 10y agoMy argument still stands. There is no law against using user-level interfaces and abstractions that wrap those provided by the kernel.
- tedmielczarek 10y agoThe comments on the bug are exemplary of the kind of crap we deal with when supporting Linux users, and really go a long way towards making people not want to spend any time on these issues. If you actually read the details you'd note that the code to support ALSA wasn't removed, it was simply put behind a configure option (--enable-alsa). Most of the people complaining in the bug are running builds from a distro that provides Firefox builds, doesn't ship PulseAudio, but didn't bother building Firefox with that option. Their distro shipped them a broken build so of course they come to complain in Bugzilla.
- digi_owl 10y agoSo the guy that has been in office barely 3 years throws his arms up and goes for the latest shiny. More and more i see where JWZ is coming from, though i can't say i share his fondness for Apple products.