Compiling x264 with mp4 support

5

3

I need x264 for my project.
I have one at /opt/local/bin/x264, but when I execute the following command:

x264 --qpfile cuepoints.qp --output output.mp4 input.mp4

it says:

x264 [error]: not compiled with MP4 output support

I decided to compile x264 from the source. I downloaded the source from http://www.videolan.org/ (git://git.videolan.org/x264.git).
Now I do:

cd x264
./configure --enable-mp4-output

And x264 says:

Unknown option --enable-mp4-output, ignored

And indeed, if I open configure file, there is no such option.

Finally, I could find compiled x264 with mp4 support (see here), but it is 3 years old and I need one more for Windows.

Do you know if x264 have dropped mp4 support, or I need to use a different option to compile it?

Ivan Zamylin

Posted 2013-06-19T14:33:36.260

Reputation: 155

1on a mobile device currently so can't properly check but from memory you need to download and compile GPAC then copy output into the x264 git folder before compiling in order to enable mp4. Doom9 / Doom10 forums might be a better place to look for specifics on the topic – James – 2013-06-19T15:21:00.287

Answers

3

There is no --enable-mp4-output option. MP4 support is automatically detected, but l-smash or gpac are required.

For a script that might compile x264 see HOWTO: x264.
For another example see Compiling X264 on Ubuntu.
Also see the FFmpeg and x264 Encoding Guide.

harrymc

Posted 2013-06-19T14:33:36.260

Reputation: 306 093

1

You can install x264 with mp4 output support on macOS with brew:

brew install x264 --with-l-smash

Daniel Cambría

Posted 2013-06-19T14:33:36.260

Reputation: 21

This gives me Warning: x264: this formula has no --with-l-smash option so it will be ignored! – Dan – 2018-11-14T08:23:41.450

0

Have a look at https://astrataro.wordpress.com/category/encode/x264/ which provides modified builds with mp4 and audio enabled.

cherouvim

Posted 2013-06-19T14:33:36.260

Reputation: 819