ECM find-modules

Yury G. Kudryashov urkud.urkud at gmail.com
Fri Jan 13 12:53:15 UTC 2012


Andreas Pakulat wrote:

> On 12.01.12 22:48:10, Alexander Neundorf wrote:
>> On Thursday 12 January 2012, Yury G. Kudryashov wrote:
>> > Alexander Neundorf wrote:
>> > > I think FindLibUSB1.cmake looks good.
>> > 
>> > From libusb-1.0.pc:
>> > includedir=${prefix}/include
>> > Cflags: -I${includedir}/libusb-1.0
>> > 
>> > So, PC_LIBUSB1_INCLUDE_DIR is $prefix/include and
>> > PC_LIBUSB1_INCLUDE_DIRS is $prefix/include/libusb-1.0.
>> >
>> > Should LIBUSB1_INCLUDE_DIR and LIBUSB1_INCLUDE_DIRS follow the same
>> > logic?
>> 
>> Eh, what ?
>> But there is only one directory added using -I to the compile command,
>> right ? I don't see a reason then why LIBUSB1_INCLUDE_DIR and
>> LIBUSB1_INCLUDE_DIRS should contain different things.
> 
> I'd even go as far as saying that the .pc file is buggy if advertises
> two different paths as include directory.
$ pkg-config --cflags libusb-1.0
/usr/include/libusb-1.0
$ pkg-config --variable=includedir libusb-1.0
/usr/include

It seems that the authors think that `pkg-config --variable=includedir` is 
an internal variable, and the only "visible" path is `pkg-config --cflags` 
output.
-- 
Yury G. Kudryashov,
mailto: urkud at mccme.ru



More information about the Kde-buildsystem mailing list