Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can i compile ffmpeg with x264? #26

Closed
chengzhf opened this issue Feb 3, 2015 · 7 comments
Closed

How can i compile ffmpeg with x264? #26

chengzhf opened this issue Feb 3, 2015 · 7 comments

Comments

@chengzhf
Copy link

chengzhf commented Feb 3, 2015

hi, thanks for your script, it's great helpful. Now i want to compile ffmpeg with x264 for iOS, what command should I write to use this script? Actually I want to use the 'preset' argument of ffmpeg but there is a hint "no such argument". I google that it needs the x264. So I want to compile the ffmpeg with x264. Thank you very much.

@kewlbear
Copy link
Owner

kewlbear commented Feb 4, 2015

  1. Build x264 for iOS
  2. Uncomment the line containing "X264=" and point it to your x264 build output
  3. Modify any other configure flags if needed
  4. Run script

@chengzhf
Copy link
Author

chengzhf commented Feb 4, 2015

Thank you for your answer. I try to use your another script: x264-iOS. I download x264 source and rename to x264 in the directory where the file build-x264.sh is, and run ./build-x264.sh. The x264 source version is x264-snapshot-20141218-2245. After the running, there are three more folders in the directory:scratch-264, thin-x264 and x264-iOS. In x264-iOS folder, the lib folder has only a *.a. I use the command "lipo -info *.a" to see what architectures it has, and it show that "Architectures in the fat file: *.a are: i386 x86_64". No arm architectures. Did I make anything wrong?

@chengzhf
Copy link
Author

chengzhf commented Feb 4, 2015

And there are a lot of warnings:
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean
'-Wno-uninitialized'? [-Wunknown-warning-option]

@kewlbear
Copy link
Owner

kewlbear commented Feb 4, 2015

I get the following using http://download.videolan.org/x264/snapshots/x264-snapshot-20141218-2245.tar.bz2.

$ lipo -info x264-iOS/lib/libx264.a 
Architectures in the fat file: x264-iOS/lib/libx264.a are: armv7 armv7s i386 x86_64 arm64 

By the way, you should open a separate issue in x264-iOS repo when you have some problem with it.

@fzakaria
Copy link

I've built everything correctly however I'm getting final linking errors in my app.

"_pp_free_context", referenced from:
"_pp_free_mode", referenced from:
"_pp_get_mode_by_name_and_quality", referenced from:

If you have any feedback on what other libraries I'm missing. Google turns up nothing.

@fzakaria
Copy link

I was missing a new static library that got re-generated.
I had added all the previous static libraries prior to running it with x264 build!

D'oh!

@sajidchingchong
Copy link

Hi kewl,

I tried your scripts. What I am looking for is to create a libffmpeg.a in lieu of an executable binary i.e. ffmpeg

Any help would be much appreciated

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants