Bug#989958: libopencv-*-dev: Missing pkg-config file (.pc)
Alejandro Colomar (man-pages)
alx.manpages at gmail.com
Sat Jul 3 18:13:45 BST 2021
Hi Jochen,
On 6/21/21 8:43 PM, Jochen Sprickerhof wrote:
> * Alejandro Colomar (man-pages) <alx.manpages at gmail.com> [2021-06-21
> 17:35]:
>> Maybe Debian could write separate pkg-config files, and maybe offer
>> them to upstream OpenCV (I offer myself to help write them if you
>> decide it's a good idea).
>
> It's easier if you talk to upstream about this directly. Adding them to
> Debian only would be incompatible with other distros and be of limited use.
It seems that they decided long ago to drop support for pkg-config
files. See
<https://github.com/opencv/opencv/issues/20269#event-4970006284> and
<https://github.com/opencv/opencv/issues/13154>
Their only response is "consider using cmake's `find_package()`", which
is not an option for me, and BTW not an option also in many other
important projects.
What should we do about it? Maintain our pkg-config files in Debian?
>
>> Yes, for linking against the shared libraries, that's all you need:
>> link against the module you want. BUT, if you want to try to link
>> against the static library (and now I'm talking from memory (it's been
>> a year since I tried to do that, and I don't remember the result, I
>> only remember a bunch of errors)), you'll need to know which libraries
>> you need, which is the magic of pkg-config.
>
> Static linking should work fine without pkg-config as well, except that
> you would have to list all dependencies, but looking at the opencv4.pc I
> guess they are incomplete anyhow ;).
Yep, I meant that it's insane adding all of the -l... manually. That's
the "magic" of pkg-config :).
>
> Cheers Jochen
Cheers,
Alex
--
Alejandro Colomar
Linux man-pages comaintainer; https://www.kernel.org/doc/man-pages/
http://www.alejandro-colomar.es/
More information about the debian-science-maintainers
mailing list