Wednesday, December 3, 2008

Openbox on Pclos part 2

My quest to tweak Pclinuxos continues.

Today I decided to tackle the mplayer/smplayer update. As I mentioned in part one, these are very out of date, and I prefer to run the svn version of both mplayer and smplayer. Which also meant a rebuild of the svn versions of x264 and ffmpeg. Not a huge deal as these are fairly easy to compile with mplayer. For reference I used the following script and created the packages with checkinstall.

if [ "$UID" != "0" ]; then
echo The mplayer installation requires root privileges.
echo Please login as root, and run:
echo again
echo Press ENTER to continue...
read dummy
exit 0
# Use checkinstall to create uninstallable rpm's for your system
apt-get install checkinstall git-core
# move to build directory
cd /usr/src
mkdir mplayer
chmod 777 mplayer
cd mplayer
# update mplayer source
svn checkout svn:// mplayer

# update ffmpeg source
svn checkout svn:// ffmpeg

# update x264 source
git clone git://

#configure ffmpeg
cd ffmpeg
cd ffmpeg
cd ..

# configure x264
cd x264
./configure --enable-pthread
cd x264
cd ..

#configure mplayer
cd mplayer
./configure --prefix=/usr/local --confdir=/etc/mplayer --disable-gui --enable-largefiles --enable-menu --with-extraincdir=/usr/src/linux/include:/usr/src/mplayer/x264 --with-extralibdir=/usr/src/mplayer/x264
cd /usr/src/mplayer/mplayer
# note the location that checkinstall moves your rpm's to as you will have to manually install with rpm
This all compiled nicely and I was able to install with rpm.

Next up was smplayer.... which was not nearly as nice. The svn version of smplayer requires qt4 and specifically qmake for qt4. I installed everything qt4 from synaptic (from the testing repo) and did not find qmake anywhere on my system. I thought it would be installed from "libqt4-devel" but it was not. So I figured what the heck... may as well install it from source!

So I grabbed the tarball from here , unpacked the tarball. Ran ./configure make and make install and, after a 45 minute compile, I was good to go! As an aside here, I've done this before so I know that uninstalling using make uninstall works great, which is why I didn't bother rpm'ing this.

It iustalled to /usr/local/Trolltech/Qt-4.4.3/ and since /usr/local was already in my path any apps I wanted to install would find the executables! a quick "which qmake" confirmed this and I was then able to compile smplayer. Checkinstall choked on the rpm creation, but SMPlayer also plays nicely with make uninstall, so I wasn't too worried about not having an rpm for this either. So long as I was careful not to delete these directories, I'd be fine.

Everything is working great and I have no complaints at this point. It's entirely possible that I did something screwy with the rpm's downloaded using synaptic and qmake with qt4 is in fact somewhere on them. Or possibly the mirror I was synced to just hadn't updated properly or recently. Who knows. It doesn't really matter as qt-4.4.3 is running fantastic.

Note that on the mplayer portion of the script at the ./configure section... it's one line and ends with x264. So if you're copy and pasting be sure to edit that portion!

No comments: