I am compiling a project with ITK 5.1.2 over KDE Neon (based on Ubuntu 20.04 LTS) and I obtain the error: /usr/bin/ld: cannot find -lproxTV. However, if I go to ./itk/lib there is libitkproxTV-5.1.a. And ITK compiled without problem (some warning).
I tried to compile ITK with gcc (9.3.0) and clang (10.0.1) but it shows the same error. I have defined in my .profile:
I cannot reproduce using itk master, and a external example requiring ITK TotalVaration module.
The library associated with the target proxTV::proxTV is indeed libitkproxTV (no -lproxTV).
Was this working before and now failing with that release, or is it a new project?
In your project, do you have any logic specific to the library proxTV?
Running out of ideas, but I suspect that if it is asking for -lproxTV is because an option in the CACHE is set to use the system proxTV (instead of the internal libitkproxTV).
Double checking, the option is named: ITK_USE_SYSTEM_proxTV, not USE_SYSTEM_PROXTV as you reported. Try setting ITK_USE_SYSTEM_proxTV to OFF.
I think there is a bug in ITK 5.1. I installed in a virtual machine Manjaro (it is stable and popular) in order to test if could be because “some” configuration in KDE Neon, moreover, it is based in Arch, not Ubuntu.
I used the KDE version and I compiled from source ITK 5.1.2 without problem using gcc 10.2.0 and cmake 3.19.3. I obtained some warnings but no errors.