How to install ffmpeg on Raspberry Pi 2


15 posts
by bdr9 » Sat Nov 07, 2015 6:53 pm
I need ffmpeg in order to set up a Subsonic audio-streaming server on my Raspberry Pi 2.

When I run sudo apt-get install ffmpeg:

Code: Select all
pi@raspberrypi2 ~ $ sudo apt-get install ffmpeg
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package ffmpeg is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'ffmpeg' has no installation candidate


I also heard that ffmpeg is included in libav-tools. When I try to install that, it installs, but ffmpeg is still not in /usr/bin. Does anyone know how to install ffmpeg on the Raspberry Pi 2?
Posts: 3
Joined: Sat Nov 07, 2015 6:49 pm
by fruitoftheloom » Sat Nov 07, 2015 9:18 pm
https://wiki.debian.org/ffmpeg

fyi Raspbian Wheezy is based of Debian 7 whilst Jessie is based of Debian 8
.
Ex Computer Repair & Service Technician.
RPi 3B, HP Envy 4500 Wireless Printer, Google Chromecast, Android Smart Phone, HD 1080p TV and 3/4G Mobile Internet make ideal companions.
Posts: 13888
Joined: Tue Mar 25, 2014 12:40 pm
Location: Bognor Regis UK
by bdr9 » Sat Nov 07, 2015 9:21 pm
fruitoftheloom wrote:https://wiki.debian.org/ffmpeg

Thanks for the link. On that page, they suggest using apt-get install libav-tools and apt-get install ffmpeg, but I said in my original post that I already tried both of those. libav-tools installed successfully but did not give me ffmpeg. When I tried to install ffmpeg directly, I got the error shown in my post above.

Any help would be appreciated.
Posts: 3
Joined: Sat Nov 07, 2015 6:49 pm
by fruitoftheloom » Sat Nov 07, 2015 9:23 pm
bdr9 wrote:
fruitoftheloom wrote:https://wiki.debian.org/ffmpeg

Thanks for the link. On that page, they suggest using apt-get install libav-tools and apt-get install ffmpeg, but I said in my original post that I already tried both of those. :D libav-tools installed successfully but did not give me ffmpeg. When I tried to install ffmpeg directly, I got the error shown in my post above.

Any help would be appreciated.


Libav is a fork of FFmpeg that we can find in the Debian repositories. If you want to use ffmpeg, you will juste need to change the word "avconv" to "ffmpeg" in the different commands lines, the rest stay the same.

It would help if you had stated you had installed Raspbian Jessie because the RPi 2B is only the hardware :D
.
Ex Computer Repair & Service Technician.
RPi 3B, HP Envy 4500 Wireless Printer, Google Chromecast, Android Smart Phone, HD 1080p TV and 3/4G Mobile Internet make ideal companions.
Posts: 13888
Joined: Tue Mar 25, 2014 12:40 pm
Location: Bognor Regis UK
by bdr9 » Sat Nov 07, 2015 9:28 pm
fruitoftheloom wrote:
bdr9 wrote:
fruitoftheloom wrote:https://wiki.debian.org/ffmpeg

Thanks for the link. On that page, they suggest using apt-get install libav-tools and apt-get install ffmpeg, but I said in my original post that I already tried both of those. :D libav-tools installed successfully but did not give me ffmpeg. When I tried to install ffmpeg directly, I got the error shown in my post above.

Any help would be appreciated.


Libav is a fork of FFmpeg that we can find in the Debian repositories. If you want to use ffmpeg, you will juste need to change the word "avconv" to "ffmpeg" in the different commands lines, the rest stay the same.

It would help if you had stated you had installed Raspbian Jessie because the RPi 2B is only the hardware :D

Actually, I didn't even know that there are two different versions of Raspbian! I just installed the one that the Noobs installer gave me. :lol: That makes sense now. I do have avconv installed. So you are saying that I can use avconv interchangably with ffmpeg? Can I rename the avconv binary to ffmpeg if my server software expects ffmpeg?
Posts: 3
Joined: Sat Nov 07, 2015 6:49 pm
by fruitoftheloom » Sat Nov 07, 2015 9:34 pm
bdr9 wrote:Actually, I didn't even know that there are two different versions of Raspbian! I just installed the one that the Noobs installer gave me. :lol: That makes sense now. I do have avconv installed. So you are saying that I can use avconv interchangably with ffmpeg? Can I rename the avconv binary to ffmpeg if my server software expects ffmpeg?

AFAIAA you just change the name in the actual written commands....


fyi https://www.raspberrypi.org/downloads/raspbian
.
Ex Computer Repair & Service Technician.
RPi 3B, HP Envy 4500 Wireless Printer, Google Chromecast, Android Smart Phone, HD 1080p TV and 3/4G Mobile Internet make ideal companions.
Posts: 13888
Joined: Tue Mar 25, 2014 12:40 pm
Location: Bognor Regis UK
by dtb1987 » Wed Aug 03, 2016 5:24 pm
How do i change the command to ffmpeg?
Posts: 3
Joined: Thu Jun 04, 2015 11:51 am
by Bottersnike » Wed Aug 03, 2016 6:08 pm
dtb1987 wrote:How do i change the command to ffmpeg?

You can create an alias. If you type
Code: Select all
alias ffmpeg=avconv
into a terminal them ffmpeg wil execute avconv. To automate that, edit your
Code: Select all
~/.bashrc
file and just add
Code: Select all
alias ffmpeg=avconv
to the end.
Micro:Pi is an (almost) fully fledged IDE for programming a BBC Micro:Bit using C++. Go check it out at https://bottersnike.github.io/Micro-Pi
User avatar
Posts: 52
Joined: Wed Apr 06, 2016 7:17 am
by dtb1987 » Thu Aug 04, 2016 11:59 am
Thanks
Posts: 3
Joined: Thu Jun 04, 2015 11:51 am
by thierryr » Sat May 20, 2017 8:24 pm
Post digging. Is there any news about ffmpeg.
Thank's
Posts: 13
Joined: Wed Aug 05, 2015 9:50 pm
by mattmiller » Sat May 20, 2017 9:02 pm
No
Posts: 1234
Joined: Thu Feb 05, 2015 11:25 pm
by fruitoftheloom » Sun May 21, 2017 10:12 am
thierryr wrote:Post digging. Is there any news about ffmpeg.
Thank's


It would appear that ffmpeg will be returning in Debian Stretch.

Though as stated above libav = ffmpeg

https://packages.debian.org/stretch/ffmpeg
.
Ex Computer Repair & Service Technician.
RPi 3B, HP Envy 4500 Wireless Printer, Google Chromecast, Android Smart Phone, HD 1080p TV and 3/4G Mobile Internet make ideal companions.
Posts: 13888
Joined: Tue Mar 25, 2014 12:40 pm
Location: Bognor Regis UK
by sanfx » Sun Jun 18, 2017 3:26 pm
trying to install ffpeng gives package not found error

Code: Select all
:~ $ sudo apt-get install ffmpeg
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package ffmpeg is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'ffmpeg' has no installation candidate
how should I fix this ?
Posts: 54
Joined: Thu Sep 08, 2016 5:40 pm
by johndavies » Sun Jun 18, 2017 4:30 pm
Look on the square penguin site (https://squarepenguin.co.uk). Choose "Download".Click on Linux/BSD.
Click on the first site mentioned.You could choose to download Raspbian get_iplayer if you live in the
UK and have a valid TV licence. Scroll to the bottom of the page. Enter the four lines one at a time
changing 64 bit to armhf-32 bit before you press "Enter". If ffmpeg is not loaded, as it was not for me
on the Raspberry Pi 2, repeat the above but begin the lines where it does not come first with "sudo".
Posts: 113
Joined: Fri Dec 20, 2013 1:00 pm
by SurferTim » Sun Jun 18, 2017 10:41 pm
I downloaded and compiled ffmpeg from the source. Download ffmpeg-3.3.2.tar.bz2
https://www.ffmpeg.org/download.html
Unpack it.
tar -xvf ffmpeg-3.3.2.tar.bz2
then change to that directory and:
./configure
make
sudo make install
Posts: 333
Joined: Sat Sep 14, 2013 9:27 am
Location: Miramar Beach, Florida