Thursday, March 29, 2007

Fedora Core 6 on x86 Cinelerra dependencies

I'm preparing to upgrade my Fedora Core 4 system to Fedora Core 6 and have figured out how to install the source dependencies for Cinelerra in Core 6 relatively painlessly in an instance of a VMware virtual machine.

I use yum to install the dependent packages.

I needed to do the installation in a number of separate steps, due to some repository conflicts for ffmpeg-devel sources between the fedora base and livna repos, as well as some trickiness with mjpegtools.

Here are the steps:
1) make sure you have the correct repositories in yum.
2) install the dependencies using the shell script below
- this script includes everything except mjpegtools
3) remove the livna repositories from yum and install mjpegtools (ffmpeg-devel, optional)
4) get the source code
5) compile Cinelerra from source

Step 1: Make sure yum repositories are available
In order to install Cinelerra from source, you will need to have the following repositories in yum:
1) fedora core, extras and updates
2) dries
3) livna

3/31/07 Note: do NOT have the freshrpms repository listed in yum when you do the install.

The Cinelerra CVS source code will not compile against the ffmpeg in Freshrpms. Reference: https://init.linpro.no/pipermail/skolelinux.no/cinelerra/2007-March/010361.html

Here's a nice rpm that installs the livna repositories into yum for you: rpm -ivh http://rpm.livna.org/livna-release-6.rpm

And don't forget the RPM key imports for each repository, such as the dries key: rpm -ivh http://dries.ulyssis.org/rpm/RPM-GPG-KEY.dries.txt

Step 2: Install dependent files
Here is the list of dependencies needed, already in the form of a shell script ready for you to cut-and-paste into your favorite text editor:
yum install \
libquicktime \
gsm-devel \
xvidcore* \
lame \
lame-devel \
libvorbis* \
libogg* \
libtool* \
a52* \
libtheora* \
libpng* \
libjpeg* \
libtiff* \
esound* \
audiofile* \
libraw1394* \
libavc1394* \
freetype* \
fontconfig* \
nasm \
e2fsprogs* \
faad2-dev* \
OpenEXR* \
fftw3* \
libsndfile* \
libiec61883* \
x264 \
x264-d* \
faac* \
libdv*

Don't forget to chmod a+x the file!

Steps 3: Install mjpegtools
Remove the livna repositories from yum and install ffmpeg-devel and mjpegtools:
4/3/07 addition (thanks Roland!)
yum --disablerepo=livna install mjpegtools*

If you wish, you may install ffmpeg-devel. But it is not essential for Cinelerra compilation.

Step 4: Get Cinelerra source code
Getting the source files assumes that you have subversion installed:
yum install subversion

Then checkout the Cinelerra CVS trunk:
svn checkout svn://svn.skolelinux.org/cinelerra/trunk/hvirtual

Step 5: Build from source
Build the source from the hvirtual directory:
./autogen.sh
./configure
make
make install

Here are some scripts that show the different portions of the installation process. You'll see the ffmpeg-libs and -devel conflicts at the bottom of script 1. In script 2, I've removed ffmpeg-devel from the initial install. Script 3 shows the successful install of ffmpeg-devel from the dries and fedora extras repositories. Script 4 shows the successful install of mjpegtools. Script 5/6 show the configure and make/make install processes.

typescript.1
typescript.2no_ffmpeg
typescript.3ffmpeg-devel
typescript.4mjpeg
typescript.5configure
typescript.6makeinstall

enjoy!

ALERT!
ALERT!
Just in case you follow these steps and get the dreaded x264 compile error: 'struct ' has no member named 'b_cbr' error, here are the steps to fix it:
http://crazedmuleproductions.blogspot.com/2007/06/dreaded-compilation-error-x264c139.html

9 comments:

Mace said...

Why not just:

yum -y install cinelerra

It's in Fedora's extras repository, which is configured by default.

Cacasodo said...

Thanks for the comment, Mace.

Yes, you're right. For most users, you can simply do a "yum install cinelerra" and that will work just fine.

However, as development of the Cinelerra CVS code moves very fast, a lot of people who use Cinelerra prefer to compile it from source in order to be able to take advantage of the latest enhancements to the codebase. Also, if you compile from source, you can change the source code at will or optimize it for your particular hardware or software configuration. To do stuff like enable specific compiler flags for performance, that sort of thing.

Cacasodo said...

Mace,
I believe you meant the Freshrpms repository, didn't you? I just checked Fedora Extras and Cinelerra is not there.

gagazote

wildhostile said...

Thank you for your post...
I will try this.
For the steps 2-3/4, instead of "remove" livna repo, one can disable it:
yum --disablerepo=livna install ffmpeg-devel mjpegtools*

Thank you

Cacasodo said...

Thanks Roland,
I did not know you could do this. I will add it to the instructions!
gagazote

Shaunak said...
This comment has been removed by the author.
Shaunak said...

checking for ALSA LDFLAGS... -lasound -lm -ldl -lpthread
checking for libasound headers version >= 1.0.2... not present.
configure: error: Sufficiently new version of libasound not found.


I get that error. How do I get past that?

Shaunak said...

Right never-mind my previous comment, I found the required packages.

Cacasodo said...

Shaunak,
I haven't installed Fedora 11 yet, but Google is your friend.

Dig deep and ye shall find the answer!

the mule