

Note that if the project is built on the Windows side, you would need to use the $” in target_link_libraries() means “the library pointed by the sqlite3 variable” and “sqlite3” would mean “ libsqlite3.*“.
#Cmake library path full

As we have included the header files (that provide the definitions for sqlite3_xxx() functions), but have not referenced the library defining them, the linker will fail due to missing definitions for the sqlite3 functions:

Ensure the “test connection” checkbox is checked so that VisualGDB can check that all the necessary packages are present:
#Cmake library path install

I will look at this again.This tutorial shows various ways to use CMake’s target_link_libraries() statement and explains the differences between them. As these still failed, I deleted the extra flags in my CMakeList.txt. But this was no solution in my case as I also need the example tools build with library X. I linked one of my several CMake tagets with -Wl,-enable-new-dtags which seemed to solve the problem. LibvtkCommonComputationalGeometry-8.2.so.1 => not found VTK and library X using VTK are compiled with mkdir build Same result for “locate” after “sudo updatedb”. LibvtkFiltersGeometry-8.2.so.1 => not found LibvtkFiltersSources-8.2.so.1 => correct full path to library Running ldd on the resulting executable gives: The RPATH is not set … and LD_LIBRARY_PATH does not contain “/home/me/opt/vtk/lib” (and I would rather not set LD_LIBRARY_PATH - although I will if I have to). Project(“Display Sphere Example”) set(VTK_DIR /home/me/opt/vtk/lib/cmake/vtk-8.2)Īfterwards, the executable built without error, but when running it, it appears that there are some VTK libraries that are not found (and confusingly, some are found)? Running “readelf -d” on the resulting executable gives the correct RUNPATH: I did not use the CMakeLists.txt file in the example, but I did use it as a guide for what I wrote: I copied the sphere example into a directory. My system is Ubuntu 19.10, with kernel 5.3.0-42-generic. I built VTK from source (8.2.0) and I am using CMake 3.13.
