I tried compiling vkvg on Ubuntu 20.04. glfw3 is installed via the system package manager as a static library.
Unfortunately, I get the following error when building vkvg.
/usr/bin/ld: /usr/local/lib/libglfw3.a(vulkan.c.o): undefined reference to symbol 'dlclose@@GLIBC_2.2.5'
If I manually add dl to target_link_libraries, this problem is resolved, but more undefined reference errors appear (this time to GLX).
I was able to solve this problem by replacing FIND_PACKAGE(GLFW3 QUIET) by FIND_PACKAGE(glfw3 QUIET) (and adapting the GLFW3_... variables to glfw3_...). In this case, the system glfw3Config.cmake is used instead of the FindGLFW3.cmake file provided by vkvg.
The changes included in this PR solve this problem by using glfw3Config.cmake if found and FindGLFW3.cmake provided by vkvg otherwise. I believe this might also fix issue #128.
Hi,
I tried compiling vkvg on Ubuntu 20.04. glfw3 is installed via the system package manager as a static library. Unfortunately, I get the following error when building vkvg.
If I manually add
dl
to target_link_libraries, this problem is resolved, but more undefined reference errors appear (this time to GLX).I was able to solve this problem by replacing
FIND_PACKAGE(GLFW3 QUIET)
byFIND_PACKAGE(glfw3 QUIET)
(and adapting theGLFW3_...
variables toglfw3_...
). In this case, the systemglfw3Config.cmake
is used instead of theFindGLFW3.cmake
file provided by vkvg.The changes included in this PR solve this problem by using
glfw3Config.cmake
if found andFindGLFW3.cmake
provided by vkvg otherwise. I believe this might also fix issue #128.