Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. Qt GUI example won't compile
Forum Updated to NodeBB v4.3 + New Features

Qt GUI example won't compile

Scheduled Pinned Locked Moved Installation and Deployment
3 Posts 2 Posters 1.3k Views 1 Watching
  • 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.
  • D Offline
    D Offline
    derpsichord
    wrote on last edited by
    #1

    I just installed Qt 5 and have never used Qt before. If I try to create a Qt GUI application, it will not compile the basic code that is already provided to me. Without altering the code at all, I received an error saying:

    @10:32:15: Running steps for project FirstGUI...
    10:32:15: Configuration unchanged, skipping qmake step.
    10:32:15: Starting: "/usr/bin/make"
    g++ -Wl,-rpath,/home/carl/CTC/QT5/5.0.2/gcc -Wl,-rpath,/home/carl/CTC/QT5/5.0.2/gcc/lib -o FirstGUI main.o mainwindow.o moc_mainwindow.o -L/home/carl/CTC/QT5/5.0.2/gcc/lib -lQt5Widgets -lQt5Gui -lQt5Core -lGL -lpthread
    /usr/bin/ld: cannot find -lGL
    collect2: ld returned 1 exit status
    make: *** [FirstGUI] Error 1
    10:32:15: The process "/usr/bin/make" exited with code 2.
    Error while building/deploying project FirstGUI (kit: Desktop Qt 5.0.2 GCC 32bit)
    When executing step 'Make'
    10:32:15: Elapsed time: 00:00.@

    The basic "Hello World" example for Qt Quick works fine, so I'm wondering if I need to reinstall, or install another library or what?

    1 Reply Last reply
    0
    • T Offline
      T Offline
      tobias.hunger
      wrote on last edited by
      #2

      The error message is that libGL is not found. Have you installed it and its development package?

      1 Reply Last reply
      0
      • D Offline
        D Offline
        derpsichord
        wrote on last edited by
        #3

        Awesome, thank you. I got it working by installing the libgl1-mesa-dev package on synaptic. I think I had some form of libGL but one without developer files. Sweeeet.

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved