1
I'm trying to use FFmpeg to encode files with the iLBC codec, e.g.:
ffmpeg -i audio.wav -ar 8000 -acodec ilbc audio.lbc -y
This worked fine on Windows, however on Mac OS X I'm getting the error Unknown encoder 'ilbc'
.
The official FFmpeg documentation has this to say about libilbc:
Go to https://github.com/dekkers/libilbc and follow the instructions for installing the library. Then pass
--enable-libilbc
to configure to enable it.
I've never compiled a library before so I tried my luck editing the brew recipe, adding these lines where appropriate:
option "with-libilbc", "Enable iLBC library
args << "--enable-libilbc" if build.with? "libilbc"
Then reinstalling ffmpeg with brew install ffmpeg --with-libilbc
. However, that just causes the build to fail and I don't see any message error pertaining to iLBC. My assumption is that the library is simply missing at this point anyway.
Hence my questions:
- How can I compile the libilbc mentioned in the FFmpeg doc for Mac OS X?
- Can I then connect it to brew somehow so as to rebuild ffmpeg with it?
FYI, the error messages while building ffmpeg were not helpful quite simply because they were being truncated. Using the
-v
flag fixed that and helped see what the problem was. – Fabien Snauwaert – 2015-01-13T08:50:07.953Would you consider making libilbc as a formula, and making that and your changes to ffmpeg a pull request? – slhck – 2015-01-13T16:18:32.770
Sure. I've never done it before but I'll try my hand at it. – Fabien Snauwaert – 2015-01-14T12:53:17.870
Would be nice. I can also try but I don't have so much time at the moment :) – slhck – 2015-01-14T14:47:10.650