Building VLC 0.7.2 for Fedora Core 2
from source RPM packages

Gabriel L. Somlo, Jun. 30, 2004

Mainly because I wanted the --enable-pvr flag turned on, but also just to see if I could do it, I decided to build VLC 0.7.2 from source RPMs, including all other packages it depends on.

Now, since the canonical places to get extra rpms for Fedora Core 2 are Fedora.us and Livna.org in that order, I decided to try and use those RPMs instead of the ones provided with VLC, whenever available.

Here's the list of what I needed:

The packages listed so far build without any kind of trouble.
One item of interest might be that there's a faad package in Livna stable (faad2-2.0-0.lvn.0.2.rc1.2.src.rpm), but its -devel subpackage is missing a header file required by faac. Hence, we need the one from Livna unstable...

Here's a list of things that gave me some (minor) trouble:

mplayer (for libpostproc)

There's no source provided on the VLC site for libpostproc, which is part of the mplayer package. When I tried to build mplayer-1.0-0.lvn.0.10.pre4.2.src.rpm from Livna.org's unstable, there were problems. The resulting libpostproc package had an undefined reference to fast_memcpy. To fix this, I had to add --disable-fastmemcpy to the list of configure flags, to make it use glibc's memcpy routine. Apparently, future versions of ffmpeg will contain their own version of libpostproc (it's currently in CVS). This raises the interesting question of whether ffmpeg and mplayer will attempt to supply conflicting versions of libpostproc... Anyway, my goal here was to build vlc using current packages, so I went back to the stable version mplayer-0.92.1-0.lvn.5.2.src.rpm, which builds the libpostproc package correctly.

vcdimager and libcdio

There were no source packages for vcdimager-0.7.20 and libcdio on VLC's download site. Both the vcdimager tarball (vcdimager.org site currently down) and libcdio-0.69.tar.gz had spec files provided with them.
libcdio used to depend on vcdimager, but it no longer does so. I had to patch the spec file in order to avoid tring to overwrite /usr/share/info/dir which in FC2 is owned by the info-4.6-3 package.
vcdimager still depends on libcdio, which is OK. There was a build issue where the vcd_image_sink_write declaration in lib/image_sink.h conflicted with the definition in lib/image.c, a problem with /usr/share/info/dir similar to the one in libcdio, and an issue where the package info file libvcdinfo.pc contained a reference to libvcd, which is a private library and shouldn't be accessed by programs linking against libvcdinfo. I made patches and updated spec files and sent them to the maintainers -- hvr at gnu dot org and manfred dot tremmel at iiv dot de. The versions I currently have are here:libcdio-0.69-1.src.rpm, and vcdimager-0.7.20-3.src.rpm.
I'm also told that libcdio and vcdimager-0.7.20 packages are imminent in fedora.us and livna.org, respectively.

speex

Fedora Core 2 comes with its own version of speex (1.0.3-2.1). However, vlc insists on a version greater than 1.1.*, so I had to fetch the version available on the VLC download site: speex-1.1.5-1.src.rpm.

vlc itself

Finally, the vlc package itself. Both the VLC download site and Livna.org (stable) ship one (the Livna one is named videolan-client-0.7.2-0.lvn.4.2.src.rpm). The specfile as shipped by both causes the mozilla plugin to be installed in /usr/lib/mozilla-1.6/plugins. I'd rather have it go into /usr/lib/mozilla/plugins, where it would survive an upgrade of Mozilla to a new version.
Also, the build kept failing due to linking errors against libpostproc. I had to add a patch that explicitly added --lpostproc to the linker command line.
I like the Livna package better, since it splits things out into separate sub-packages (i.e., not just vlc vs. vlc-devel, but -mozilla for the plugin, -kde for the KDE-specific user inteface bits, etc). However, the Livna SRPM includes its own ffmpeg package from CVS to work around the libpostproc problem I mention above. I changed it so it will build against and use both libpostproc and ffmpeg from Livna.org stable.
One last thing: I made sure my modified version only requires generic mozilla, not specifically 1.6-8. After the upgrade to 1.7.2-0.2.0, the VLC plugin still worked fine; so, from this sample of one, I think it's no longer needed to tie the plugin to the specific Mozilla version... :)
The modified source RPM for VLC 0.7.2 is here: videolan-client-0.7.2-1gls.src.rpm.

in conclusion...

After using stock fedora.us and livna.org packages first, and videolan.org packages as a last resort, I got away with most of it, except that I had to tweak the following packages:


Last Modified Aug. 06, 2004; Send corrections and comments to somlo [at] acns dot colostate dot edu