If you are going to make any changes to preferences, manually or by changing the defaults, please make sure that these changes are going to achieve what you want and not stop anything from working. Changes to Firefox Quantum around version 60.0 have made sound work without needing any changes to preferences, BUT the apulse libraries must be installed and Firefox must be able to find and use them.
_____________________________________________________________________
Official Mozilla packages of Firefox now require pulse audio which is not normally in Puppy.
A fix for this is to use apulse libraries which emulate pulse and feed the audio to Puppy's alsa sound system.
However, there is then an additional problem, because the sandbox feature in Firefox blocks the action of apulse. EDIT - See note above.
The fix for this is to change the preferences settings in Firefox. One easy option is to disable the sandbox. If you prefer not to do this there is the slightly more complicated option of using whitelist settings to allow the sound processes to be ignored by the sandbox.
It is possible to change these settings by navigating Firefox to about:config and changing them manually, but obviously it is better if these settings can be as you want them as soon as Firefox is launched.
To do this, some people use a configuration file named user.js which has to be placed inside the profile (under /root). This is not ideal because the profile is normally only created (and modified) when Firefox runs. Settings defined here appear in about:config as "user set" showing that they have been changed from the default.
A better method is to place a configuration file with your custom settings inside the Firefox system files. This way, the required settings appear in about:config as the default settings from the start and everything is contained inside the main firefox directory.
To do this:-
Download the official Firefox tarball from Mozilla and extract it.
This gives you a directory named firefox which contains everything.
Normally this is installed into either /opt or /usr/lib
Navigate into this directory.
Navigate into the sub-directory named browser
In there, right-click and create a new directory named defaults
Navigate into default, in there, right-click and create a new directory named preferences
Navigate into preferences, in there, right click and create a new blank file named firefox.js
So now you have */firefox/browser/defaults/preferences/firefox.js
(I believe other paths and file names are also accepted if anyone wishes to experiment)
In this file you write your custom settings and they will be there as defaults from first run.
BUT the lines start with "pref" and NOT "user_pref" as was the case when using a user.js file.
Example firefox.js file:-
Code: Select all
// fix firefox sound using apulse
pref("security.sandbox.content.level", 2);
pref("security.sandbox.content.write_path_whitelist", "/dev/snd/");
pref("security.sandbox.content.syscall_whitelist", "54");
pref("security.sandbox.content.read_path_whitelist", "/dev/snd/");
To disable sandbox, set level to 0 and the other lines are not needed.
The number 54 is for 32bit. Try replacing this with 16 for 64bit.
ADDITIONAL NOTE:-
Regarding the 3 apulse libraries, I recommend you extract these and install them into the main firefox directory. Here they can be found by Firefox but will not conflict with any other programs. If you want to make certain that these libraries have priority, use a small wrapper script (rather than a symlink) at /usr/bin/firefox something like:-
Code: Select all
#!/bin/sh
export LD_LIBRARY_PATH=/usr/lib/firefox:$LD_LIBRARY_PATH
/usr/lib/firefox/firefox "$@"
http://smokey01.com/OscarTalks