Guides: August 2007 Archives

It's been quite a while since I wrote a post about getting flash working under firefox in FreeBSD. It's gotten fairly popular, but I've also gotten a lot of emails and comments telling me that it was out of date. I hadn't set up flash on my computer at home yet, so I just went through the steps and revised them a little.

linuxpluginwrapper will prompt you with a config menu for multimedia/linux-realplayer and print/acroread7 support. I suggest not enabling acroread - as of mid 2006, linuxpluginwrapper was having some issues with unresolved symbols. It appears this is still the case.

# cd /usr/ports/www/linuxpluginwrapper
# make install clean

If you try to compile linuxpluginwrapper with acroread support, you'll get something like this when you try to use it later:

LoadPlugin: failed to initialize shared library /usr/local/Adobe/Acrobat7.0/ENU/Browser/intellinux/nppdf.so [/usr/local/Adobe/Acrobat7.0/ENU/Browser/ intellinux/nppdf.so: Undefined symbol "__ctype_b_loc"]

rltd has to be patched if we want any chance of getting flash7 to work properly.

# cd /usr/src
# fetch -o - http://people.freebsd.org/~nork/rtld_dlsym_hack.diff | patch
# cd libexec/rtld-elf
# make clean && make && make install

Install www/linux-flashplayer7. Do not use flashplugin-mozilla.

# cd /usr/ports/www/linux-flashplayer7
# make install clean

Although linuxpluginwrapper does supply an example libmap.conf, it's old. I mean, just look at the version number. 2005? I'm going to assume that you actually bother to run somewhat updated software, so here's a libmap.conf that will work with the prefix change for X.Org when we bumped major versions.

# My sample /etc/libmap.conf
# Flash 7 with Mozilla/Firefox
[/usr/local/lib/npapi/linux-flashplugin/libflashplayer.so]
libpthread.so.0 libpthread.so.2
libdl.so.2 pluginwrapper/flash7.so
libz.so.1 libz.so.3
libm.so.6 libm.so.4
libc.so.6 pluginwrapper/flash7.so
# Helix RealPlayer
[/usr/local/lib/linux-mozilla/plugins/nphelix.so]
libstdc++.so.5 libstdc++.so.5
libc.so.6 pluginwrapper/realplayer.so
libm.so.6 libm.so.4
libgcc_s.so.1 pluginwrapper/realplayer.so

We're almost done. Create a symlink for the flash player.

# ln -s /usr/local/lib/npapi/linux-flashplugin/libflashplayer.so /usr/local/lib/browser_linux_plugins/

Run firefox and go to about:plugins to verify plugin installation. It should look something like this. If you see it listed, you can test to see if it's working by coming to freebsdgirl.com and seeing if my meebo app loads.

I've heard rumors of proper flash 9 support soon, so keep your fingers crossed.