Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Install full ffmpeg in debian wheezy (with aac(m4a) and x264 support)
# Add multimedia source
echo "deb http://www.deb-multimedia.org wheezy main non-free" >> /etc/apt/sources.list
echo "deb-src http://www.deb-multimedia.org wheezy main non-free" >> /etc/apt/sources.list
apt-get update
apt-get install deb-multimedia-keyring # if this aborts, try again
apt-get update
# Go to local source directory
cd /usr/local/src
# Become root
su -
# Install all dependencies we'll need
aptitude install \
-y \
libfaad-dev \
faad \
faac \
libfaac0 \
libfaac-dev \
libmp3lame-dev \
x264 \
libx264-dev \
libxvidcore-dev \
build-essential \
checkinstall
# Install all build dependencies for ffmpeg
apt-get build-dep ffmpeg
# Get the actual ffmpeg source code
apt-get source ffmpeg
# Go into the ffmpeg source directory
cd ffmpeg-*
# Configure it
./configure \
--enable-gpl \
--enable-nonfree \
--enable-libfaac \
--enable-libgsm \
--enable-libmp3lame \
--enable-libtheora \
--enable-libvorbis \
--enable-libx264 \
--enable-libxvid \
--enable-zlib \
--enable-postproc \
--enable-swscale \
--enable-pthreads \
--enable-x11grab \
--enable-libdc1394 \
--enable-version3 \
--enable-libopencore-amrnb \
--enable-libopencore-amrwb
# a fix
mkdir -p /usr/local/share/ffmpeg
# Generate the debian package (*.deb)
checkinstall -D --install=no --pkgname=ffmpeg-full --autodoinst=yes -y
# if after this step you'll probably will get an error
# libavcodec/libx264.c:492: undefined reference to `x264_encoder_open_125'
# here's a solution:
cd ..
apt-get remove x264
git clone git://git.videolan.org/x264.git
cd x264
./configure --enable-static --enable-shared
make && make install
ldconfig
cd .. && cd ffmpeg*
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/src/x264/libx264.a ./configure --enable-gpl --enable-nonfree --enable-libfaac --enable-libgsm --enable-libmp3lame --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid --enable-zlib --enable-postproc --enable-swscale --enable-pthreads --enable-x11grab --enable-libdc1394 --enable-version3 --enable-libopencore-amrnb --enable-libopencore-amrwb
make clean
checkinstall -D --install=no --pkgname=ffmpeg-full --autodoinst=yes -y
# install the package :)
dpkg -i ffmpeg-full_*-1_amd64.deb
@ghost

This comment has been minimized.

Copy link

ghost commented Aug 16, 2014

Thanks,
Works perfectly on my Debian 3.2.60-1+deb7u3 x86_64 GNU/Linux

@Proplex

This comment has been minimized.

Copy link

Proplex commented Aug 22, 2014

Why would apt want to remove pipelight to install this? I prefer being able to watch Netflix properly than having an up-to-date ffpmeg.

@kirkegaard

This comment has been minimized.

Copy link

kirkegaard commented Sep 16, 2014

If only this would work with 2.* of ffmpeg

@Metrakit

This comment has been minimized.

Copy link

Metrakit commented Feb 1, 2015

Thanks a lot guy !

@henry-h

This comment has been minimized.

Copy link

henry-h commented Feb 11, 2015

Thanks a lot, JDownloader 2 work again with youtube

@xabikip

This comment has been minimized.

Copy link

xabikip commented Feb 26, 2015

Hello,
I have this error when run this command: checkinstall -D --install=no --pkgname=ffmpeg-full --autodoinst=yes -y

And the error is this:
libavcodec/libavcodec.a(libx264.o): In function X264_init': /usr/local/src/ffmpeg-dmo-1.0.10/libavcodec/libx264.c:533: undefined reference tox264_encoder_open_146'
collect2: error: ld returned 1 exit status
make: *** [ffmpeg_g] Error 1

**** Installation failed. Aborting package creation.

Can you help me please?

Thanks,

@tldsjp

This comment has been minimized.

Copy link

tldsjp commented Mar 2, 2015

Hello,

I meet same problem at xabikip.

I modifyed seqence.
apt-get remove x264 -> apt-get remove x264 x264-dev

Then success.

Thanks,

@wolfgangpue

This comment has been minimized.

Copy link

wolfgangpue commented Mar 11, 2015

Script worked for me, but how can I install a newer verison of ffmpeg (2.*)? Can I use this tutorial somehow?

@ninidc

This comment has been minimized.

Copy link

ninidc commented Mar 17, 2015

Hello,

Same problem with debian 7.
Need to remove x264-dev like that apt-get remove libx264-dev and it work fine !

Thanks you for this guide !
:)

@bobolinkrd

This comment has been minimized.

Copy link

bobolinkrd commented Jul 22, 2015

Can you guys help
I am still struggling to install ffmpeg on debian 8 server
I have jomsocial that need ffmpeg and VLV2tool
Anybody can help step but step
I follow many tip still doesnt work

@rlagreid

This comment has been minimized.

Copy link

rlagreid commented Sep 22, 2015

Hi,
I have tried several tricks and tweaks to get ffmpeg installed, but without success. The last attempts have been following these instructions, but it fails when it comes to installing x264:
$ make && install
cat common/opencl/x264-cl.h common/opencl/motionsearch.cl common/opencl/subpel.cl common/opencl/intra.cl common/opencl/weightp.cl common/opencl/downscale.cl common/opencl/bidir.cl | ./tools/cltostr.sh common/oclobj.h
dependency file generation...
gcc -Wshadow -O3 -ffast-math -Wall -I. -I. -std=gnu99 -mcpu=cortex-a8 -mfpu=neon -I/usr/local/include -I/usr/local/include -fPIC -fomit-frame-pointer -fno-tree-vectorize -c -o x264.o x264.c
x264.c: In function 'print_csp_names':
x264.c:445:15: error: variable 'i' has initializer but incomplete type
x264.c:445:27: error: storage size of 'i' isn't known
x264.c:445:5: error: 'enum PixelFormat' declared in 'for' loop initial declaration
x264.c:445:27: warning: unused variable 'i' [-Wunused-variable]
: recipe for target 'x264.o' failed
make: *** [x264.o] Error 1

@vampiricwulf

This comment has been minimized.

Copy link

vampiricwulf commented Sep 28, 2015

@rlagreid I fixed that by clearing out my /usr/local/lib/pkgconfig of the duplicates that are in /lib/pkgconfig

@adrian2020my

This comment has been minimized.

Copy link

adrian2020my commented Oct 21, 2015

Thank you! Worked perfectly on my Linux 3.2.0-4-amd64 #1 SMP Debian 3.2.65-1+deb7u1 x86_64 GNU/Linux

@recrunchi

This comment has been minimized.

Copy link

recrunchi commented Feb 1, 2016

It worked on my Debian Wheezy 7.8 Raspberry 2, Linux 4.1.16-v7+ . However, i wonder why if i'm downloading the "actual" ffmpeg source (as commented on above script), the resulting ffmpeg version seems old: "ffmpeg version 1.0.10 Copyright (c) 2000-2014". Thanks.

@mh4ck

This comment has been minimized.

Copy link

mh4ck commented May 3, 2016

Got following error on running the full-ffmpeg.sh from another bash script.

dpkg: error processing ffmpeg-full_*-1_amd64.deb (--install): cannot access archive: No such file or directory

Anyone know how to fix that?

@Louris84

This comment has been minimized.

Copy link

Louris84 commented May 24, 2016

I got the following error during ./configure --enable-static --enable-shared:
"No working C compiler found"

And in the config.log:
Failed commandline was: gcc conftest.c -m64 -Wall -I.
I have no idea how to get around this...

Does anyone has any ideas?

@StayerX

This comment has been minimized.

Copy link

StayerX commented May 25, 2016

This might help: http://ubuntuforums.org/showthread.php?t=1393927

@MJunghenn This is happening because to many lines before are failing to install.
Starting from those (This is only for weezy and deb-src no longer exists in this format):
echo "deb http://www.deb-multimedia.org wheezy main non-free" >> /etc/apt/sources.list
echo "deb-src http://www.deb-multimedia.org wheezy main non-free" >> /etc/apt/sources.list

@StayerX

This comment has been minimized.

Copy link

StayerX commented May 25, 2016

@vadikge

This comment has been minimized.

Copy link

vadikge commented Aug 22, 2017

cd .. && cd ffmpeg* - here is error. You should move to /usr/local/src and then run cd ffmpeg*

@mrkapqa

This comment has been minimized.

Copy link

mrkapqa commented Nov 28, 2017

is the support for support for https URLs already included here?

@vertu-web

This comment has been minimized.

Copy link

vertu-web commented Dec 14, 2017

root@vps1519821:/usr/local/src/ffmpeg-dmo-1.0.10# dpkg --install ffmpeg-full_-1_amd64.deb
dpkg: error processing ffmpeg-full_
-1_amd64.deb (--install):
cannot access archive: No such file or directory
Errors were encountered while processing:
ffmpeg-full_*-1_amd64.deb

plz help me

@ElliotElep

This comment has been minimized.

Copy link

ElliotElep commented Mar 15, 2019

Thanks a lot,
Works fine on my Linux Mint LMDE2, based on Debian Jessie.
I just change that :
# Add multimedia source
# echo "deb http://www.deb-multimedia.org wheezy main non-free" >> /etc/apt/sources.list
echo "deb-src http://www.deb-multimedia.org jessie main non-free" >> /etc/apt/sources.list.d/additional-repositories.list

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.