srinivas
(srinivas)
December 13, 2019, 1:30pm
1
Hi
Could you please help us with below issue?
We are facing the below error while building(make) Icinga2 (core) with source code.
pgsql has already been installed still we are getting this error
/bin/ld: cannot find -lpq
collect2: error: ld returned 1 exit status
make[2]: *** [Bin/Release/libpgsql_shim.so.2.11.2] Error 1
make[1]: *** [lib/pgsql_shim/CMakeFiles/pgsql_shim.dir/all] Error 2
make: *** [all] Error 2
Thanks&Regards
Srinivas
That means you’re missing a dependent library. What operating system/distribution is this?
1 Like
mcktr
(Michael Insel)
December 13, 2019, 5:41pm
3
You can find more information on how to build icinga2 in the development chapter from the documentation.
https://icinga.com/docs/icinga2/latest/doc/21-development/
srinivas
(srinivas)
December 16, 2019, 8:11am
4
hi
Thanks you for your response. It is Linux and RHEL 7x.
We could see that lib files are available under pgsql folder /pgsql/lib/libpq.a, /pgsql/lib/libpq.so, /pgsql/lib/libpq.so.5.
Thanks&Regards
Srinivas
srinivas
(srinivas)
December 16, 2019, 1:47pm
5
Hi
We could resolve the above issue by manually providing the libpq.so file path during compilation
Thanks&Regards
Srinivas