Koozali.org: home of the SME Server

FFMPEG from source

Offline animare

  • *
  • 29
  • +0/-0
FFMPEG from source
« on: February 08, 2012, 06:32:28 PM »
Hi everyone,

I've successfully installed ffmpeg 0.9 on a test server using ATrpms repo, following a variety of tutorials. However there are things I need to install, such as qt-faststart.
I understand installing from source is not recommended however I have no other options.

The following tutorial will allow me to do everything I need. http://ffmpeg.org/trac/ffmpeg/wiki/CentosCompilationGuide
However when following the tutorial I come accross some errors when compiling. I guess all the problems I run into are to do with the different path's sme has.
Has anyone ever attempted this before?
Is there anyone with more experience than me able to run through the above tutorial and tell me how they did it succesfully?
Apologies as I know that is a lot to ask
Thanks!

Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
Re: FFMPEG from source
« Reply #1 on: February 08, 2012, 09:00:34 PM »
The following tutorial will allow me to do everything I need. http://ffmpeg.org/trac/ffmpeg/wiki/CentosCompilationGuide
However when following the tutorial I come accross some errors when compiling. I guess all the problems I run into are to do with the different path's sme has.

It's unlikely to be paths. SME server is not a development server. It has no compilers or development libraries. Install a CentOS build machine and do your compiling there.

The HOWTO you reference refers to CentOS 6. You will need a CentOS4 HOWTO. Perhaps the new ffmpeg code doesn't even compile under CentOS4.

Offline animare

  • *
  • 29
  • +0/-0
Re: FFMPEG from source
« Reply #2 on: February 08, 2012, 11:00:06 PM »
Thanks for the quick reply Charlie
I'm currently using the sme server 8 beta 7. I'll keep playing around on my test server. If I'm successful I'll post back what I did for anyone that will find it useful

Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
Re: FFMPEG from source
« Reply #3 on: February 09, 2012, 12:20:34 AM »
I'm currently using the sme server 8 beta 7.

Then you'll need a CentOS5 build server.

Why do you say that you have "no option" but to build from source? That seems unlikely. What problem are you trying to solve?

Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
Re: FFMPEG from source
« Reply #4 on: February 09, 2012, 12:24:19 AM »

Offline animare

  • *
  • 29
  • +0/-0
Re: FFMPEG from source
« Reply #5 on: February 09, 2012, 11:33:36 AM »
Hi Charlie

I successfully installed qt-faststart using your link. I found that link on my travels before but didn't realise it would work.

I now have installed ffmpeg ffmpeg-devel using atrpms repo. Which is great.

I now have to install vo-aacenc as the audio codec with ffmpeg is poor.
I did install vo-aacenc succesfully.

vo-aacenc

VisualOn AAC audio encoder.

cd ~/ffmpeg-source
wget http://downloads.sourceforge.net/opencore-amr/vo-aacenc-0.1.1.tar.gz
tar xzvf vo-aacenc-0.1.1.tar.gz
cd vo-aacenc-0.1.1
./configure --disable-shared
make
# checkinstall

Now my only issue is telling ffmpeg to --enable-libvo-aacenc
I am going to yum remove ffmpeg
Then modify the spec file on the src.rpm to add the line
 --enable-libvo-aacenc

Then I was going to yum local install this src.rpm file:

http://dl.atrpms.net/all/ffmpeg-0.9-52.src.rpm

There is another rpm from atrpms but I cannot see a spec file:
http://dl.atrpms.net/all/ffmpeg-0.9-52.el5.i386.rpm

I'll tell you how it goes.

Thanks

Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
Re: FFMPEG from source
« Reply #6 on: February 09, 2012, 03:12:19 PM »
Then I was going to yum local install this src.rpm file:

http://dl.atrpms.net/all/ffmpeg-0.9-52.src.rpm

There is another rpm from atrpms but I cannot see a spec file:
http://dl.atrpms.net/all/ffmpeg-0.9-52.el5.i386.rpm

You will find that ffmpeg-0.9-52.el5.i386.rpm is built from ffmpeg-0.9-52.src.rpm. The .el5 is added during the build process (see %{dist} in the spec file).

Offline animare

  • *
  • 29
  • +0/-0
Re: FFMPEG from source
« Reply #7 on: February 09, 2012, 03:34:46 PM »

I tried to compile from the src.rpm using the following tutorial

http://www.sohailriaz.com/how-to-create-rpm-using-source-rpm/#more-99

When I get to the following:

#  cd /usr/src/redhat/SPECS

# rpmbuild -bb ffmpeg.spec

It seems that there are many dependencies needed, I'm assuming that is because I need to mimic the original developers own environment to be then able to compile an rpm.
I have been trying this in my sme server test enivronment on my virtual box.
From what you mentioned before should I create a virtual box with a centos build from http://www.centos.org/
I'm probably hitting the edge of what I know about this stuff.

Thanks


Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
Re: FFMPEG from source
« Reply #8 on: February 09, 2012, 04:03:19 PM »
From what you mentioned before should I create a virtual box with a centos build from http://www.centos.org/

Why do you think I might have not meant what I said earlier?

Offline animare

  • *
  • 29
  • +0/-0
Re: FFMPEG from source
« Reply #9 on: February 09, 2012, 05:32:03 PM »
Wasn't sure you were talking about that.
I think I will leave modifying anything for now.

Thanks for your help