I am developing an application in QT Creator in C ++ on Linux
I created my own library so that I can use some common classes in all sets of applications.
In the library that I created, I used another external static library (libSDL.a). I configured my library in a static library (* .a) and it compiles without problems.
Then I added my library to another application and used some of the classes. When I try to compile my application, I get undefined links from my library to call functions in another library.
From my point of view, during compilation it is supposed to copy static libraries. Why do I get undefined links to a library that should be copied to my library?
This is how the library project is configured in the * .pro file:
QT -= gui TARGET = FoobarTools TEMPLATE = lib CONFIG += staticlib CONFIG -= shared DEFINES += FOOBARTOOLS_LIBRARY INCLUDEPATH += ./include/SDL_Headers/ LIBS += -L./bin/ -lSDL SOURCES += ... HEADERS += ...
This is how my * .pro application file uses my library:
QT -= gui TARGET = FoobarApp CONFIG += console CONFIG -= app_bundle TEMPLATE = app INCLUDEPATH += ./include/ LIBS += -L./bin/ -lFoobarTools SOURCES += ... HEADERS += ...
source share