Joining the conversation, as I had to patch this too to get mediakit to
build ;)
On Fri, 21 Nov 2008 14:34:14 +0000, David Chisnall <[EMAIL PROTECTED]>
wrote:
> Bottom line:
>
> I am not going to break the build on other platforms to work around
> Debian. If you can provide a solution that doesn't break other
> platforms, I will commit it, but adding prefixes in the headers will
> break other platforms and this is unacceptable.
This is not only Debian, but also Gentoo, Arch and every future
distribution release that will include a ffmpeg snapshot that more recent
than march 2008 (afaik that was when the switch was made)
The ffmpeg project has reorganized their include paths, using separate
subdirectories for every sub libraries.
So libavformat headers are in .../libavformat, libavcodec ones in
.../libavcodec, etc
Usual fix to work on both current ffmpeg and old one is to check for
libavcodec/libavcodec.h at configure time, cache the result (config.h or
something like that) and include depending on it libavcodec.h or
libavcodec/libavcodec.h. sox for example behaves like that.
> The location of the headers is not the problem, the problem is the
> fact that the output from pkg-config does not provide the correct
> location. It is entirely up to the packager where headers for any
> given package go, but they must ensure that this location matches the
> location provided by pkg-config.
pkg-config returning only "-I/usr/include/ffmpeg" instead of something like
"-I/usr/include/ffmpeg/libavcodec -I/usr/include/ffmpeg/libavformat .." is
not a packaging problem, upstream designed it so. Many projects depending
on ffmpeg have updated to the new include paths (xine, vlc, blender, ...)
Anyway here after a quick sed line mediakit compiles fine ;)
sed -i -e "s#avcodec.h#libavcodec/avcodec.h#" \
-e "s#avformat.h#libavformat/avformat.h#" \
MKMediaFile.h
Regards,
--
Bernard Cafarelli (Voyageur)
Gentoo developer (NX, GNUstep, net-misc, ...)
> On 21 Nov 2008, at 14:26, Bertrand Gmail wrote:
>
>> I've written to the maintainer of Debian Multimedia about libavcodec
>> and
>> pkg-config. Here is an abstract of his answer (the whole answer at the
>> end in french).
>>
>> Debian Multimedia ffmpeg is from june in the svn repo of ffmpeg ; and
>> the debian lenny from february. The headers have been moved to
>> /usr/include/ffmpeg/avcodec/ (and friends avformat avutils too) since
>> more than 6 months.
>> So : pkg-config always returns /usr/include/ffmpeg and the include
>> have
>> to be changed in the source of MediaKit.
>>
>> Cheers,
>> Bertrand Dekoninck
>>
>>> Bertrand Gmail <[EMAIL PROTECTED]> writes:
>>>
>>>>>>>>> Same problem here on Debian Lenny and ffmpeg from debian-
>>>>>>>>> multimedia.
>>>>>>>>>
>>>>>>>>> But "pkg-config libavcodec --cflags" gives :
>>>>>>>>>
>>>>>>>>> -I/usr/include/ffmpeg -I/usr/include/dirac
>>>>>
>>>>> Are the libav* headers in subdirectories of ffmpeg here? On
>>>>> FreeBSD 7
>>>>> they are all in /usr/include/ffmpeg and pkg-config returns:
>>>>>
>>>>> -I/usr/local/include -I/usr/local/include/ffmpeg
>>>
>>> Quelle version de ffmpeg ? Comme je le disais dans mon précédent
>>> e-mail, les en-têtes ont changés de place depuis au moins 6 mois, si
>>> le ffmpeg de FreeBSD est trop vieux pkg-config ne retournera pas la
>>> même valeur.
>>>
>>> [...]
>>>
>>>>> pkg-config ne devrait-il pas renvoyer -I/usr/include/ffmpeg/
>>>>> libavcodec ?
>>>
>>> Non, parce que les en-têtes sont dans différents répertoires :
>>>
>>> ,----
>>> | $ ls -l /usr/include/ffmpeg/
>>> | total 12
>>> | drwxr-xr-x 2 root root 4096 16 nov 2008 libavcodec
>>> | drwxr-xr-x 2 root root 4096 16 nov 2008 libavutil
>>> | drwxr-xr-x 2 root root 4096 16 nov 2008 libpostproc
>>> `----
>>>
>>> pkg-config retourne toujours -I/usr/include/ffmpeg et il faut donc
>>> changer les includes dans les sources.
>>>
>>> ,----
>>> | $ pkg-config --cflags libavcodec
>>> | -I/usr/include/ffmpeg -I/usr/include/dirac
>>> | marillat ~/src/cvs/ffmpeg
>>> | $ pkg-config --cflags libavutil
>>> | -I/usr/include/ffmpeg
>>> | marillat ~/src/cvs/ffmpeg
>>> | $ pkg-config --cflags libpostproc
>>> | -I/usr/include/ffmpeg
>>> `----
_______________________________________________
Etoile-discuss mailing list
[email protected]
https://mail.gna.org/listinfo/etoile-discuss