Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Shared lib QtCore/qglobal.h: No such file or directory.



  • Hi all. I'm doing my homework, working with libraries.
    I'm using this tutorial youtube.com/watch?v=9JTooLxhmC0, it helped me with static lib. But when i'm trying to make sharel lib, i got an error.
    It't in dll_global.h, when i'm debuging it. It's in @#include <QtCore/qglobal.h>@ - No such file or directory.
    I'm doing exectly like in that video. What should i do?
    Should i add smt more to any folders?


  • Moderators

    [quote author="Max_a" date="1417359016"]when i'm trying use it in my app, when i'm including headers[/quote]Did you set up your app as a Qt app?

    Post the contents of your app's *.pro file.



  • don't know did i set it up. How can i do it, if not?
    .pro is:
    @
    TEMPLATE = app
    CONFIG += console
    CONFIG -= app_bundle
    CONFIG -= qt

    SOURCES += main.cpp

    HEADERS +=
    dll_global.h
    dll.h
    @



  • There some additional info about the same question in this closed thread http://qt-project.org/forums/viewthread/50208/


  • Moderators

    [quote author="Max_a" date="1417463623"]
    .pro is:
    @
    ...
    CONFIG -= qt
    ...
    @
    [/quote]Remove that line. It turns your project into a non-Qt project -- that's why you can't find Qt headers.

    [quote author="Max_a" date="1417464184"]if i add qt5/ in that include it works, and shows errors in the qglobal.h, in some includes, where i can add qt5/ too. Should i do that?[/quote]No, don't do that. Modify your .pro file instead.



  • this is it. thx, now i can finish my labs and prepare for exams. TY


Log in to reply