Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Compiling ffmpeg for iPhone SDK (Symbol(s) not found - Linker)

I'm using ffplay in my Application. I implemented the Librarys which has been used in this Project: http://code.google.com/p/ffmpeg4iphone/downloads/detail?name=ffplay-xproj.zip&can=2&q=

But I've seen that this Sources are very old(Apr 2009). I wanted to Build new Librarys and then change it with these In my project.

What I've done:

  1. Downloaded the ffmpeg Source code: (using command line: svn checkout svn://svn.ffmpeg.org/ffmpeg/trunk ffmpeg)
  2. Compiled the Project with special ./configure options and the gas-processor : http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/2009-October/076618.html
  3. I only changed here the Paths of the actual locations for the iPhone SDK 4.1
  4. Changed the header Path in xCode Active Target Project Settings to my ffmpeg folder
  5. Included the .a files in my project in xCode
  6. Added the Other Linker Flags -lm -lbz2 -lz
  7. Tried to Build my Application, but I get some Linker errors where symbol(s) wasn't found.

Undefined symbols: "avcodec_init()", referenced from:

And the other errors are nearly the same (_av_codec.....)

How can I build it correctly?

like image 664
brokedid Avatar asked Nov 15 '22 04:11

brokedid


1 Answers

I've found the solution: I set the architecture to Optimized(arm7) and then all was working.

One more Question: I use ffmpeg for streaming an online stream. Which Values Should I set to get a good streaming quality also when I am in 3G. This what i've done:

  • set the audio-buffer to 1024
  • set the lowres value of mpeg to 3
like image 94
brokedid Avatar answered Dec 21 '22 05:12

brokedid