Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Error :-1: error: cannot find -lGL
Forum Update on Tuesday, May 27th 2025

Error :-1: error: cannot find -lGL

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 3 Posters 905 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.
  • J Offline
    J Offline
    Jeronimo
    wrote on 2 Nov 2016, 11:25 last edited by
    #1

    Hi i installed qt for linux but show me this error why?

    J 1 Reply Last reply 2 Nov 2016, 11:29
    0
    • J Jeronimo
      2 Nov 2016, 11:25

      Hi i installed qt for linux but show me this error why?

      J Offline
      J Offline
      Jeronimo
      wrote on 2 Nov 2016, 11:29 last edited by Jeronimo 11 Feb 2016, 11:32
      #2

      @Jeronimo /usr/bin/ld: cannot find -lGL
      g++ -m32 -Wl,-O1 -Wl,-rpath,/opt/Qt/5.5/gcc -Wl,-rpath,/opt/Qt/5.5/gcc/lib -o binder main.o mainwindow.o moc_mainwindow.o -L/opt/Qt/5.5/gcc/lib -lQt5Widgets -lQt5Gui -lQt5Core -lGL -lpthread
      /usr/bin/ld: cannot find -lGL

      1 Reply Last reply
      0
      • R Offline
        R Offline
        ramn
        wrote on 2 Nov 2016, 11:34 last edited by
        #3

        You need to install

        libgl1-mesa-dev
        
        J 1 Reply Last reply 2 Nov 2016, 11:34
        0
        • R ramn
          2 Nov 2016, 11:34

          You need to install

          libgl1-mesa-dev
          
          J Offline
          J Offline
          Jeronimo
          wrote on 2 Nov 2016, 11:34 last edited by
          #4

          @ramn with sudo apt-get???

          M 1 Reply Last reply 2 Nov 2016, 11:41
          0
          • J Jeronimo
            2 Nov 2016, 11:34

            @ramn with sudo apt-get???

            M Offline
            M Offline
            mrjj
            Lifetime Qt Champion
            wrote on 2 Nov 2016, 11:41 last edited by
            #5

            @Jeronimo
            yes.
            Also very common error so many posts about it here on forum.

            1 Reply Last reply
            1

            4/5

            2 Nov 2016, 11:34

            • Login

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