Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Update: Forum Guidelines & Code of Conduct

    QtCore/QtGlobal: No such file or directory

    General and Desktop
    qtcore qtglobal qtgstreamer
    1
    1
    2900
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J
      JackCWallace last edited by

      I am working with QtGStreamer on one of the examples, and I cannot get it to work. I keep getting the error 'QtCore/QtGlobal: No such file or directory' from global.h, when I try #include <QtCore/QtGlobal in main.cpp I don't get an error from that.
      Here is my code:

      main.cpp

      #include "mediaapp.h"
      #include <QApplication>
      #include <QGst/Init>
      
      
      int main(int argc, char *argv[])
      {
          QApplication app(argc, argv);
          QGst::init(&argc, &argv);
      
          MediaApp media;
          media.show();
      
          if (argc == 2) {
              media.openFile(argv[1]);
          }
      
          return app.exec();
      }
      

      player.pro

      TEMPLATE = app
      TARGET = player
      
      CONFIG += silent
      
      CONFIG += pkgconfig
      
      contains(QT_VERSION, ^4\\..*) {
          PKGCONFIG += QtGStreamer-1.0 QtGStreamerUi-1.0
      }
      contains(QT_VERSION, ^5\\..*) {
          PKGCONFIG += Qt5GStreamer-1.0 Qt5GStreamerUi-1.0\
      }
      
      QT += core quick widgets
      CONFIG += qt console bootstrap
      
      DEFINES += QT_NO_KEYWORDS
      
      HEADERS += mediaapp.h player.h
      SOURCES += main.cpp mediaapp.cpp player.cpp
      
      INCLUDEPATH += C:\qt-gstreamer-1.2.0\src \
          C:\Qt\Qt5.4.1\5.4\mingw491_32\include \
          C:\Qt\Qt5.4.1\5.4\android_armv5\include \
          C:\Qt\Qt5.4.1\5.4\android_armv7\include \
          C:\Qt\Qt5.4.1\5.4\android_x86\include \
          C:\Qt\Qt5.4.1\5.4\Src\qtbase\include
      

      In C:\Qt...\include there is a directory QtCore with QtGlobal. While typing it in to global.h I get suggestions to put it in, but it throws an error when I try and build it.

      1 Reply Last reply Reply Quote 0
      • First post
        Last post