Home/News | About | Download | Documentation | Forum | Bug Reports | Contact | Donations | Consulting | Projects | Legal | Security | FATE


*How to quickly compile libx264

A collection of useful tutorials for some common tasks.

*How to quickly compile libx264

Postby burek » Thu Mar 29, 2012 12:40 am

This will quickly compile/install libx264:
Code: Select all
# cd /my/path/where/i/keep/compiled/stuff
# git clone git://git.videolan.org/x264.git
# cd x264
# ./configure --enable-static --enable-shared
# make
# make install
# ldconfig


P.S. If you are using Ubuntu, you'll most probably have to use sudo for the last 2 commands, like:
Code: Select all
# sudo make install
# sudo ldconfig
burek
 
Posts: 867
Joined: Mon May 09, 2011 10:16 pm
Location: Serbia

Re: *How to quickly compile libx264

Postby acrane1 » Fri Oct 19, 2012 3:37 pm

I have been trying to compile ffmpeg and x264 on my linux system. I am running Ubuntu 11.04 64bit and openmediavault(debian 6) and neither of them will compile x264.\


git clone --depth 1 new users can't post links but it is taken from videolan's git /x264 ste
cd x264
./configure --enable-static
make


This is the output of check install after make fails
========================= Installation results ===========================
gcc -o x264 x264.o input/input.o input/timecode.o input/raw.o input/y4m.o output/raw.o output/matroska.o output/matroska_ebml.o output/flv.o output/flv_bytestream.o filters/filters.o filters/video/video.o filters/video/source.o filters/video/internal.o filters/video/resize.o filters/video/cache.o filters/video/fix_vfr_pts.o filters/video/select_every.o filters/video/crop.o filters/video/depth.o input/thread.o input/lavf.o output/mp4.o libx264.a -lgpac_static -lz -L. -pthread -L/usr/local/lib -lavformat -lavcodec -ldl -lx264 -lvpx -lvorbisenc -lvorbis -ltheoraenc -ltheoradec -logg -lrtmp -lgnutls -lopencore-amrwb -lopencore-amrnb -lmp3lame -lfdk-aac -lfaac -lz -lrt -lswscale -lavutil -lm -L/usr/local/lib -lswscale -lavutil -lm -m64 -lm -lpthread
/usr/local/lib/libavcodec.a(libx264.o): In function `X264_init':
/root/ffmpeg/libavcodec/libx264.c:533: undefined reference to `x264_encoder_open_125'
collect2: ld returned 1 exit status
make: *** [x264] Error 1

Any help would be really appreciated.
acrane1
 
Posts: 1
Joined: Fri Oct 19, 2012 4:16 am

Re: *How to quickly compile libx264

Postby burek » Fri Oct 19, 2012 11:46 pm

you probably have already installed some system's x264 package, so you'll most probably have issues with it anyway..
please first consult our wiki: http://ffmpeg.org/trac/ffmpeg/wiki
if you can't find your solution, please join our IRC channel #ffmpeg on irc.freenode.net so we can help you more quickly.

basically, you need to either remove your system installed x264 package or you need to compile your ffmpeg in such way that you tell it that you have a custom x264 library somewhere in your disk compiled..
burek
 
Posts: 867
Joined: Mon May 09, 2011 10:16 pm
Location: Serbia

Re: *How to quickly compile libx264

Postby zohaib_khalid1 » Mon Oct 20, 2014 11:51 am

Hey after
Code: Select all
# cd x264
command. This command is not working
Code: Select all
# ./configure --enable-gpl --enable-libx264

The error is '.' is not known as internal or external command. Please tell how to correct this .
zohaib_khalid1
 
Posts: 1
Joined: Mon Oct 20, 2014 6:43 am


Return to Tutorials

Who is online

Users browsing this forum: No registered users and 2 guests