<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">On 23. Sep 2023, at 20:55, Pedro Mitidieri <<a href="mailto:mitidieripedro@gmail.com" class="">mitidieripedro@gmail.com</a>> wrote:<br class=""><div><blockquote type="cite" class=""><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">
<div class="">Hello,</div><div class=""><br class=""></div><div class="">I have a problem while trying to link taglib to my simple project, which is done in windows with Qt 5.15 and C++. <br class=""></div><div class=""><br class=""></div><div class="">I
 have followed the steps of the installation guide. As a result, I have 3
 folders named bin, include and lib and I have copied them into the 
folder of my project inside a folder called taglib. So the path to the 
include folder would be: <br class=""></div><div class="">$root_folder_of_project$/taglib/include . <br class=""></div><div class=""><br class=""></div><div class="">Once
 I have them there, I have modified the CMakeList.txt to try to use it 
in my project. To accomplish this, I have added the following lines:</div><div class="">add_subdirectory("./taglib")</div><div class="">target_link_libraries(AudioDatabaseManager PRIVATE "absolute_path_to_root_folder\\taglib\\lib")</div><div class=""><br class=""></div><div class="">The line: <i class="">target_link_libraries</i>(...) I have added just after the <i class="">target_link_libraries()  </i>used for connecting the other Qt libraries.</div><div class=""><br class=""></div><div class="">After
 these steps, QT Creator 10.0.2 is able to autocomplete the path to the 
files and autocomplete the classes and their methods. So, I am assuming 
that it has worked. However, when I try to build, it fails. The error 
that I am encountering is :</div><div class=""><span id="cid:ii_lmw8adoj0"><image.png></span></div></div></div></blockquote><div><br class=""></div><div>You’re not linking to TagLib at all, you’re just including the headers.  The easiest way to do that on Linux would be by using pkg-config from CMake.  There’s info on that here:</div><div><br class=""></div><div><a href="https://stackoverflow.com/questions/29191855/what-is-the-proper-way-to-use-pkg-config-from-cmake" class="">https://stackoverflow.com/questions/29191855/what-is-the-proper-way-to-use-pkg-config-from-cmake</a></div><div><br class=""></div><div>Just swap SDL for TagLib there.</div><div><br class=""></div><div>-Scott</div></div></body></html>