<div dir="ltr"><span style="font-family:arial,sans-serif;font-size:13px">Hi,</span><div style="font-family:arial,sans-serif;font-size:13px">we are trying to link a shared library to connect to tracker from a plugin. We know, that the code that calls the .so library works in a test application and also in the main method of our CTK application. After we have added our code to the plugin and linked it to the .so library, we can link and compile the code without errors, but we don't get a connection to the tracker. </div>
<div style="font-family:arial,sans-serif;font-size:13px">The cmakelists code to link the .so file in our test application is</div><div style="font-family:arial,sans-serif;font-size:13px">TARGET_LINK_LIBRARIES(optoExtern ${OPTOTRAK_LIBRARY})</div>
<div style="font-family:arial,sans-serif;font-size:13px">(${OPTOTRAK_LIBRARY} is the library path, optoExtern the project name)</div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">
The cmakelists code to link the .so file in our plugin:</div><div style="font-family:arial,sans-serif;font-size:13px"><div>ctkMacroBuildPlugin(</div><div> NAME ${PROJECT_NAME}</div><div> EXPORT_DIRECTIVE ${PLUGIN_export_directive}</div>
<div> SRCS ${PLUGIN_SRCS}</div><div> MOC_SRCS ${PLUGIN_MOC_SRCS}</div><div> UI_FORMS ${PLUGIN_UI_FORMS}</div><div> INCLUDE_DIRECTORIES ${Plugin_SOURCE_DIR}</div><div> RESOURCES ${PLUGIN_resources}</div><div> TARGET_LIBRARIES ${PLUGIN_target_libraries} ${OPTOTRAK_LIBRARY}</div>
<div>)</div><div><br></div><div>Has anyone an idea how to link external shared libraries within a plugin properly?</div><div><br></div><div>Best regards,</div><div>Florian Ganglberger</div></div></div>