[FFmpeg-devel] Fix libx264

Felipe Contreras felipe.contreras
Wed Feb 24 00:51:42 CET 2010


2010/2/24 M?ns Rullg?rd <mans at mansr.com>:
> Felipe Contreras <felipe.contreras at gmail.com> writes:
>
>> 2010/2/23 M?ns Rullg?rd <mans at mansr.com>:
>>> Felipe Contreras <felipe.contreras at gmail.com> writes:
>>>> They all support -l${library} don't they? Otherwise the current
>>>> "require ?libx264 x264.h x264_encoder_encode -lx264 -lm" wouldn't
>>>> work. Therefore they all support -lpthread, or whatever pkg-config
>>>> throws.
>>>
>>> Yes, all compilers I know of support -llib, but they do *NOT* all
>>> support -pthread, -pthreads, -Kthreads, etc.
>>
>> If they support -llib; they support -lpthread, -lpthreadGC2,
>> -lpthreadGC2 -lwsock32, -lpthreadGC2 -lws2_32, or whatever x264 was
>> compiled with.
>
> Or -pthreads, -Kthreads, or some other non-standard flags x264 was
> built with.

x264 is not built with -Kthreads, it's built with -pthreads only for
OpenBSD, the rest of the cases it's -lpthread -lfoo.

So, things would break *only* if you try to compile FFmpeg on OpenBSD
with a compiler that doesn't support -pthread (very unlikely). In any
case, that issue can be solved by translating -pthread to something
more standard; -lpthread -D_REENTRANT, or whatever is needed in
OpenBSD. Then pkg-config flags couldn't possibly break other
compilers.

-- 
Felipe Contreras



More information about the ffmpeg-devel mailing list