Re: pkg-config and share/

From: Andrea Pappacoda <andrea_at_pappacoda.it>
Date: Mon, 25 Jul 2022 13:56:12 UTC
Il giorno lun 25 lug 2022 alle 13:10:46 +02:00:00, Baptiste Daroussin 
<bapt@FreeBSD.org> ha scritto:
> how do I lose that? there is something that I am missing here. what is
> fundamentally different from share/pkgconfig and libdata/pkgconfig 
> beside the
> name of the directory?

I guess the difference is in the meaning of the two locations. If a .pc 
file is in share/ you can be sure it can be used for cross compilation, 
as share/ only contains arch-independent stuff. And if it is in 
libdata/? Maybe, I can't know, it could be either arch-specific or 
arch-independent.

For example, if I'm cross compiling to a riscv target and I find the 
toml++ library in share/pkgconfig/, I can use the library for the build 
as it is arch-independent (header-only lib, in this case). If I instead 
find the .pc file in libdata/pkgconfig/, I can't use it anymore, as it 
could either be arch-independent (header-only version), or 
arch-specific (toml++ can also be compiled as a proper shared library).

That's how I see things, but I might be missing something.

Hope I made this a bit cleaner :)

-- 
OpenPGP key: 66DE F152 8299 0C21 99EF  A801 A8A1 28A8 AB1C EE49