greenbone / openvas-smb

SMB module for OpenVAS Scanner
GNU General Public License v2.0
47 stars 47 forks source link

No package 'popt' found yet popt-devel is installed. #71

Closed misterjmw closed 1 year ago

misterjmw commented 1 year ago

Expected behavior

cmake3 . should create a makefile

Actual behavior

cmake3 throws an error about popt being missing, when all possible popt-* modules are installed.

-- Install prefix: /usr/local
-- Checking for module 'popt'
--   No package 'popt' found
CMake Error at /usr/share/cmake3/Modules/FindPkgConfig.cmake:497 (message):
  A required package was not found
Call Stack (most recent call first):
  /usr/share/cmake3/Modules/FindPkgConfig.cmake:681 (_pkg_check_modules_internal)
  CMakeLists.txt:148 (pkg_check_modules)
openvas-smb-22.5.3]# yum list popt-*
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: abqix.mm.fcix.net
 * epel: d2lzkl7pfhq30w.cloudfront.net
 * extras: ix-denver.mm.fcix.net
 * remi-php82: mirror.usi.edu
 * remi-safe: mirror.usi.edu
 * updates: ix-denver.mm.fcix.net
Installed Packages
popt.x86_64                                              1.13-16.el7                                        @anaconda
popt-devel.x86_64                                        1.13-16.el7                                        @base
popt-static.x86_64                                       1.13-16.el7                                        @base
Available Packages
popt.i686                                                1.13-16.el7                                        base
popt-devel.i686                                          1.13-16.el7                                        base
popt-static.i686                                         1.13-16.el7                                        base

Steps to reproduce

wget https://github.com/greenbone/openvas-smb/archive/refs/tags/v22.5.3.tar.gz tar xvzf v22.5.3.tar.gz cd openvas-smb-22.5.3 cmake3 .

Environment

Operating system: CentOS Linux release 7.9.2009 (Core)

Installation method / source: tar.gz distribution from Github.

Logfiles

I do not believe there are any log files that are applicable here, however it might be noted that the cmake output does not include anything referencing popt.

jjnicola commented 1 year ago

Hello @misterjmw

It seems to be more like a configuration problem than a bug. In our reference system (Debian 11 Bullseye) it works as expected.

Cmake is using pkgconfig for module check. I would suggest to check if the PKG_CONFIG_PATH environment variable is set, and if the .pc file is even provided in your distribution.

$ grep -r popt CMakeLists.txt 
pkg_check_modules (POPT REQUIRED popt)

Therefore, closing this as invalid for now, since this might be an environmental issue.

Please open a new topic in the [Greenbone Forum](https://forum.greenbone.net/ for support). Once it has been found to be a real bug we can still re-open this issue here.