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. How to install Qt4 and Qt Creator for Qt4 on Ubuntu?
QtWS25 Last Chance

How to install Qt4 and Qt Creator for Qt4 on Ubuntu?

Scheduled Pinned Locked Moved Unsolved General and Desktop
9 Posts 8 Posters 4.8k Views
  • 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
    JacobNovitsky
    wrote on 29 Sept 2023, 14:08 last edited by aha_1980
    #1

    Having some old project, could not build on Qt6
    how to install Qt4 and Qt Cretator for Qt4 on Ubuntu?

    Below no effect

    sudo apt-get install qt5-qmake
    sudo apt-get install qt5-default
    sudo apt-get install libqt5gui5
    sudo apt-get install qt5-doc
    sudo apt-get install libqt5svg5-dev
    sudo apt-get install libleptonica-dev

    C J S 3 Replies Last reply 29 Sept 2023, 14:22
    0
    • J JacobNovitsky
      29 Sept 2023, 14:08

      Having some old project, could not build on Qt6
      how to install Qt4 and Qt Cretator for Qt4 on Ubuntu?

      Below no effect

      sudo apt-get install qt5-qmake
      sudo apt-get install qt5-default
      sudo apt-get install libqt5gui5
      sudo apt-get install qt5-doc
      sudo apt-get install libqt5svg5-dev
      sudo apt-get install libleptonica-dev

      C Offline
      C Offline
      Christian Ehrlicher
      Lifetime Qt Champion
      wrote on 29 Sept 2023, 14:22 last edited by
      #2

      @JacobNovitsky said in How to install Qt4 and Qt Cretator for Qt4 on Ubuntu?:

      Qt4

      Below no effect

      sudo apt-get install qt5-qmake
      sudo apt-get install qt5-default
      sudo apt-get install libqt5gui5
      sudo apt-get install qt5-doc
      sudo apt-get install libqt5svg5-dev
      sudo apt-get install libleptonica-dev

      I mean - what do you expect? When you want to install Qt4 you have to insteall qt4 packages, not Qt5 ones... you have to look for the Qt4 packages (don't know if there're some - you have to look at the ubuntu repos).

      Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
      Visit the Qt Academy at https://academy.qt.io/catalog

      1 Reply Last reply
      2
      • J JacobNovitsky
        29 Sept 2023, 14:08

        Having some old project, could not build on Qt6
        how to install Qt4 and Qt Cretator for Qt4 on Ubuntu?

        Below no effect

        sudo apt-get install qt5-qmake
        sudo apt-get install qt5-default
        sudo apt-get install libqt5gui5
        sudo apt-get install qt5-doc
        sudo apt-get install libqt5svg5-dev
        sudo apt-get install libleptonica-dev

        J Offline
        J Offline
        JoeCFD
        wrote on 29 Sept 2023, 14:28 last edited by
        #3

        @JacobNovitsky install a virtual machine and an old Ubuntu version(for example 18.04). Then, you may be able to use Qt4. I just checked my 18.04 and Qt 4.8.7 is available for installation.

        1 Reply Last reply
        2
        • J JacobNovitsky
          29 Sept 2023, 14:08

          Having some old project, could not build on Qt6
          how to install Qt4 and Qt Cretator for Qt4 on Ubuntu?

          Below no effect

          sudo apt-get install qt5-qmake
          sudo apt-get install qt5-default
          sudo apt-get install libqt5gui5
          sudo apt-get install qt5-doc
          sudo apt-get install libqt5svg5-dev
          sudo apt-get install libleptonica-dev

          S Offline
          S Offline
          SimonSchroeder
          wrote on 4 Oct 2023, 07:16 last edited by
          #4

          @JacobNovitsky said in How to install Qt4 and Qt Cretator for Qt4 on Ubuntu?:

          Qt Cretator for Qt4

          Don't bother with the version of Qt Creator. It is mostly unrelated to the version of Qt you are using. If you want to use Qt 4 on a modern system you should compile it yourself.

          1 Reply Last reply
          0
          • B Offline
            B Offline
            bl3ssedc0de
            wrote on 21 Sept 2024, 08:35 last edited by bl3ssedc0de
            #5

            Error when compiling Qt4 on Ubuntu 22.04

            I also have an old project in Qt4, but my current system is Ubuntu 22.04, unfortunately the Qt4 package is NO longer available in the Ubuntu repositories. I was able to solve it by installing Qt4 with a PPA:

            sudo add-apt-repository ppa:ubuntuhandbook1/ppa
            sudo apt update
            sudo apt install qt4-default
            

            However, when installing Qt4 this way, it does not come with Qt designer 4.

            My problem now is that I am trying to compile Qt4 from source code and I am getting the following error:

            You don't seem to have 'make' or 'gmake' in your PATH. Cannot proceed.

            qt4-error.png

            could someone help me???

            The last alternative, as @JoeCFD mentioned is to use a virtual machine with old Ubuntu 18.04.

            J 1 Reply Last reply 21 Sept 2024, 08:44
            0
            • B bl3ssedc0de
              21 Sept 2024, 08:35

              Error when compiling Qt4 on Ubuntu 22.04

              I also have an old project in Qt4, but my current system is Ubuntu 22.04, unfortunately the Qt4 package is NO longer available in the Ubuntu repositories. I was able to solve it by installing Qt4 with a PPA:

              sudo add-apt-repository ppa:ubuntuhandbook1/ppa
              sudo apt update
              sudo apt install qt4-default
              

              However, when installing Qt4 this way, it does not come with Qt designer 4.

              My problem now is that I am trying to compile Qt4 from source code and I am getting the following error:

              You don't seem to have 'make' or 'gmake' in your PATH. Cannot proceed.

              qt4-error.png

              could someone help me???

              The last alternative, as @JoeCFD mentioned is to use a virtual machine with old Ubuntu 18.04.

              J Offline
              J Offline
              JonB
              wrote on 21 Sept 2024, 08:44 last edited by
              #6

              @bl3ssedc0de
              Just how large or complex is your Qt4 project? Rather than fiddling around trying to install and use, or create a VM with an old OS for, a very old Qt4 have you considered porting it to at least Qt5 (easier than to Qt6)?

              B 1 Reply Last reply 21 Sept 2024, 23:27
              1
              • J JonB
                21 Sept 2024, 08:44

                @bl3ssedc0de
                Just how large or complex is your Qt4 project? Rather than fiddling around trying to install and use, or create a VM with an old OS for, a very old Qt4 have you considered porting it to at least Qt5 (easier than to Qt6)?

                B Offline
                B Offline
                bl3ssedc0de
                wrote on 21 Sept 2024, 23:27 last edited by
                #7

                @JonB Actually they are not very complex, they are projects from my university, with Qt4 PyQt4 and Qt designer 4, they provided me with .exe executables for windows, but I am stubborn and I refuse to use windows 😁, after many tests, I found another alternative, without using an old operating system, using the arch linux AUR repositories, I achieved my goal of installing Qt4 PyQt4 and Qt Designer 4.

                Qt4 PyQt4 Qt Designer 4.gif

                However, I am left with the question of how to compile Qt4 in Ubuntu and solve this compilation error:

                You don't seem to have 'make' or 'gmake' in your PATH. Cannot proceed.

                It shouldn't be impossible, I just don't have enough knowledge to solve it, I'm sharing this in case someone has the same problem in the future.

                Pl45m4P C 2 Replies Last reply 22 Sept 2024, 01:10
                0
                • B bl3ssedc0de
                  21 Sept 2024, 23:27

                  @JonB Actually they are not very complex, they are projects from my university, with Qt4 PyQt4 and Qt designer 4, they provided me with .exe executables for windows, but I am stubborn and I refuse to use windows 😁, after many tests, I found another alternative, without using an old operating system, using the arch linux AUR repositories, I achieved my goal of installing Qt4 PyQt4 and Qt Designer 4.

                  Qt4 PyQt4 Qt Designer 4.gif

                  However, I am left with the question of how to compile Qt4 in Ubuntu and solve this compilation error:

                  You don't seem to have 'make' or 'gmake' in your PATH. Cannot proceed.

                  It shouldn't be impossible, I just don't have enough knowledge to solve it, I'm sharing this in case someone has the same problem in the future.

                  Pl45m4P Offline
                  Pl45m4P Offline
                  Pl45m4
                  wrote on 22 Sept 2024, 01:10 last edited by
                  #8

                  @bl3ssedc0de said in How to install Qt4 and Qt Cretator for Qt4 on Ubuntu?:

                  they are projects from my university, with Qt4 PyQt4 and Qt designer 4

                  Yes, probably over a decade old...

                  If you want to continue to work on the project(s), why you pick QtDesigner 4 and Qt4?
                  The program you show in the GIF does pretty much nothing... takes 5mins to rebuild the same with modern Qt6...

                  For future Qt development and to learn Qt, I would not use Qt4


                  If debugging is the process of removing software bugs, then programming must be the process of putting them in.

                  ~E. W. Dijkstra

                  1 Reply Last reply
                  0
                  • B bl3ssedc0de
                    21 Sept 2024, 23:27

                    @JonB Actually they are not very complex, they are projects from my university, with Qt4 PyQt4 and Qt designer 4, they provided me with .exe executables for windows, but I am stubborn and I refuse to use windows 😁, after many tests, I found another alternative, without using an old operating system, using the arch linux AUR repositories, I achieved my goal of installing Qt4 PyQt4 and Qt Designer 4.

                    Qt4 PyQt4 Qt Designer 4.gif

                    However, I am left with the question of how to compile Qt4 in Ubuntu and solve this compilation error:

                    You don't seem to have 'make' or 'gmake' in your PATH. Cannot proceed.

                    It shouldn't be impossible, I just don't have enough knowledge to solve it, I'm sharing this in case someone has the same problem in the future.

                    C Offline
                    C Offline
                    ChrisW67
                    wrote on 22 Sept 2024, 06:15 last edited by
                    #9

                    @bl3ssedc0de said in How to install Qt4 and Qt Cretator for Qt4 on Ubuntu?:

                    However, I am left with the question of how to compile Qt4 in Ubuntu and solve this compilation error:
                    You don't seem to have 'make' or 'gmake' in your PATH. Cannot proceed.

                    To compile Qt (any version), or any project you write to use such libraries, you will need suitable tools installed; and you do not. The first line below will probably get you close but is only the start of the fun:

                    $ sudo apt update && sudo apt install build-essential g++ git
                    
                    $ git clone https://github.com/qt/qt.git qt4
                    $ cd qt4
                    $ git switch 4.8
                    $ ./configure --prefix=/usr/local --no-openssl --no-webkit 
                    ...
                    Qt is now configured for building. Just run 'gmake'.
                    Once everything is built, you must run 'gmake install'.
                    Qt will be installed into /usr/local
                    
                    To reconfigure, run 'gmake confclean' and 'configure'.
                    
                    $ make  ## or gmake... it is just a symlink
                    

                    This will likely fail with compiler, default library changes, and other missing development packages.

                    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