Openvas-scanner unable to locate installed libgvm_base (21.4)

GVM versions

gsad: N/A
gvmd: N/A
openvas-scanner: N/A (will be 21.04)
gvm-libs: 21.04

Environment

Operating system: CentOS Stream 8
Kernel: (‘uname -a’) 4.18.0-301.1.el8.x86_64
Installation method / source: Source

Hi there,

I’m working on setting up a new test installation based on the 21.04 release and have successfully installed the gvm-libs installation from source. When attempting to proceed to install openvas-scanner running cmake .. results in the following error and installation does not continue:

Set LIBDIR to /usr/local/lib64
– Install prefix: /usr/local
– Found PkgConfig: /usr/bin/pkg-config (found version “1.4.2”)
– Checking for module ‘glib-2.0>=2.42’
– Found glib-2.0, version 2.56.4
– Checking for module ‘gnutls>=3.6.4’
– Found gnutls, version 3.6.14
– Checking for module 'libgvm_base>=21.4’
– Package ‘libgvm_base’, required by ‘virtual:world’, not found
CMake Error at /usr/share/cmake/Modules/FindPkgConfig.cmake:545 (message):
A required package was not found
Call Stack (most recent call first):
/usr/share/cmake/Modules/FindPkgConfig.cmake:733 (_pkg_check_modules_internal)
misc/CMakeLists.txt:31 (pkg_check_modules)

It appears the libraries are installed into /usr/local/lib64

ls -la /usr/local/lib64
total 824
drwxr-xr-x. 4 root root 4096 Apr 16 12:17 .
drwxr-xr-x. 13 root root 142 Apr 16 12:17 …
drwxr-xr-x. 2 root root 6 May 18 2020 bpf
lrwxrwxrwx. 1 root root 17 Apr 16 12:17 libgvm_base.so -> libgvm_base.so.21
lrwxrwxrwx. 1 root root 21 Apr 16 12:17 libgvm_base.so.21 -> libgvm_base.so.21.4.0
-rwxr-xr-x. 1 root root 235992 Apr 16 12:17 libgvm_base.so.21.4.0
lrwxrwxrwx. 1 root root 19 Apr 16 12:17 libgvm_boreas.so -> libgvm_boreas.so.21
lrwxrwxrwx. 1 root root 23 Apr 16 12:17 libgvm_boreas.so.21 -> libgvm_boreas.so.21.4.0
-rwxr-xr-x. 1 root root 151776 Apr 16 12:17 libgvm_boreas.so.21.4.0
lrwxrwxrwx. 1 root root 16 Apr 16 12:17 libgvm_gmp.so -> libgvm_gmp.so.21
lrwxrwxrwx. 1 root root 20 Apr 16 12:17 libgvm_gmp.so.21 -> libgvm_gmp.so.21.4.0
-rwxr-xr-x. 1 root root 62872 Apr 16 12:17 libgvm_gmp.so.21.4.0
lrwxrwxrwx. 1 root root 16 Apr 16 12:17 libgvm_osp.so -> libgvm_osp.so.21
lrwxrwxrwx. 1 root root 20 Apr 16 12:17 libgvm_osp.so.21 -> libgvm_osp.so.21.4.0
-rwxr-xr-x. 1 root root 58704 Apr 16 12:17 libgvm_osp.so.21.4.0
lrwxrwxrwx. 1 root root 17 Apr 16 12:17 libgvm_util.so -> libgvm_util.so.21
lrwxrwxrwx. 1 root root 21 Apr 16 12:17 libgvm_util.so.21 -> libgvm_util.so.21.4.0
-rwxr-xr-x. 1 root root 316800 Apr 16 12:17 libgvm_util.so.21.4.0
drwxr-xr-x. 2 root root 116 Apr 16 12:17 pkgconfig

Any tips / ideas to have the scanner properly recognize the installed files?

Thank you!

Just to follow up on this one:

I ended up copying the the .pc files from /usr/local/lib64/pkgconfig/ to /usr/lib64/pkgconfig/ on the machine and re-ran the cmake .. command and this time was successful in being able to build / install the openvas-scanner

Hopefully this will help someone else that may run into the issue!