[FFmpeg-devel] [PATCH] configure: only check dispatch header on darwin

Josh de Kock josh at itanimul.li
Thu Feb 25 16:49:38 CET 2016


On 25/02/2016 15:44, Clément Bœsch wrote:
> On Thu, Feb 25, 2016 at 03:34:37PM +0000, Josh de Kock wrote:
>> On 25/02/2016 14:00, Matthieu Bouron wrote:
>>> From: Matthieu Bouron <matthieu.bouron at stupeflix.com>
>>>
>>> Fixes build of lavd/jack on linux if dispatch happens to be available on
>>> this platform. dispatch, as well as its dependencies kqueue and pwq are
>>> generally not installed / distribued on linux systems. If it happens to
>>> be the case, you want to explicitely link against the libraries (using
>>> -ldispatch) as opposed to darwin where it is part of the standard
>>> library and -ldispatch doesn't work.
>> Systems other than OSX/darwin could potentially have a working
>> libdispatch/GCD as well, I know FreeBSD has a port[1].
>
> In this case, is sem_timedwait present? In which case it wouldn't matter
> immediately.
>
Yes, OSX/Darwin is the only OS, that I know of, which actually requires 
libdispatch as an alternative to pthreads.

>> Maybe it would be a good idea to check if pthreads are available (or the
>> system is OSX), and if not then properly check for libdispatch.
>> Making it OSX-only is just going to require another patch when someone using
>> libdispatch on another system wants it.
>
> I think this patch is just meant to fix a regression in the build.
>
Just thought it wouldn't hurt to fix the real problem--that libdispatch 
isn't being checked for correctly, rather than a quick fix. Either is 
fine, I guess, although the quick fix would just require another patch, 
as I previously stated.

- Josh


More information about the ffmpeg-devel mailing list