nixpkgs/pkgs/applications/networking/browsers/firefox-wrapper/builder.sh
Eelco Dolstra 4fbb44e598 * Enable the Java applet plugin (through Blackdown) in Firefox.
svn path=/nixpkgs/trunk/; revision=1567
2004-10-17 14:30:11 +00:00

28 lines
597 B
Bash

. $stdenv/setup
shopt -s nullglob
mkdir -p $out/bin
pluginPath=
extraLibPath=
for i in $plugins; do
for p in $i/lib/mozilla/plugins $i/jre/plugin/*/mozilla; do
if test -e $p; then
pluginPath=$pluginPath${pluginPath:+:}$p
if test -e $p/extra-library-path; then
extraLibPath=$extraLibPath${extraLibPath:+:}$(cat $p/extra-library-path)
fi
fi
done
done
cat > $out/bin/firefox <<EOF
#! $SHELL
export LD_LIBRARY_PATH=$extraLibPath
export MOZ_PLUGIN_PATH=$pluginPath
exec $firefox/bin/firefox
EOF
chmod +x $out/bin/firefox