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. Problem with installing qt-4.6.2 on ubuntu 14.04
Forum Update on Monday, May 27th 2025

Problem with installing qt-4.6.2 on ubuntu 14.04

Scheduled Pinned Locked Moved General and Desktop
10 Posts 3 Posters 8.0k 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.
  • M Offline
    M Offline
    mostafanfs
    wrote on last edited by
    #1

    Hi guys
    I wanted to install qt-everywhere-opensource-src-4.6.2 on Ubuntu 14.04. I went through its help. After extracting I ran "./configure" command in terminal then I ran "make" command and after 1 hour it showed some errors. Here are last lines of the report :
    .
    .
    .
    .
    .

    ../3rdparty/javascriptcore/JavaScriptCore/wtf/RefPtr.h: In instantiation of ‘QTWTF::RefPtr<T>::~RefPtr() [with T = QTJSC::Label]’:
    ../3rdparty/javascriptcore/JavaScriptCore/bytecompiler/LabelScope.h:49:46: required from here
    ../3rdparty/javascriptcore/JavaScriptCore/wtf/RefPtr.h:51:55: error: ‘derefIfNotNull’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
    ~RefPtr() { T* ptr = m_ptr; derefIfNotNull(ptr); }
    ^
    In file included from ../3rdparty/javascriptcore/JavaScriptCore/jit/ExecutableAllocator.h:31:0,
    from ../3rdparty/javascriptcore/JavaScriptCore/runtime/JSGlobalData.h:33,
    from ../3rdparty/javascriptcore/JavaScriptCore/interpreter/CallFrame.h:26,
    from ../3rdparty/javascriptcore/JavaScriptCore/runtime/ClassInfo.h:26,
    from ../3rdparty/javascriptcore/JavaScriptCore/runtime/JSObject.h:27,
    from ../3rdparty/javascriptcore/JavaScriptCore/runtime/InternalFunction.h:27,
    from ../3rdparty/javascriptcore/JavaScriptCore/runtime/JSFunction.h:27,
    from ../3rdparty/javascriptcore/JavaScriptCore/runtime/Executable.h:29,
    from ../3rdparty/javascriptcore/JavaScriptCore/bytecode/EvalCodeCache.h:32,
    from ../3rdparty/javascriptcore/JavaScriptCore/bytecode/CodeBlock.h:33,
    from ../3rdparty/javascriptcore/JavaScriptCore/bytecode/CodeBlock.cpp:31:
    ../3rdparty/javascriptcore/JavaScriptCore/wtf/PassRefPtr.h:39:10: note: ‘template<class T> void QTWTF::derefIfNotNull(T*)’ declared here, later in the translation unit
    void derefIfNotNull(T* ptr)
    ^
    make[1]: *** [obj/release/CodeBlock.o] Error 1
    make[1]: Leaving directory `/usr/local/qt-everywhere-opensource-src-4.6.2/src/script'
    make: *** [sub-script-make_default-ordered] Error 2

    I couldn't figure it out and I'm not a pro in Linux and Ubuntu area.
    Could you help me with this? I have to use this version since I want to use it on FriendlyARM mini 2440. I wish there was a way I could get this version of qt through repositories since compiling Qt takes a lot of time (can say an hour!)

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

      Type ./configure -help to get a list of all available options.

      Maybe you need to avoid dependencies using some argument when you run ./configure.

      You should also check the requirements:

      http://doc.qt.digia.com/4.6/requirements-x11.html

      "Individually, we are one drop. Together, we are an ocean."

      1 Reply Last reply
      0
      • M Offline
        M Offline
        mostafanfs
        wrote on last edited by
        #3

        Thank you very much
        It has a lot of switch when you run ./configure -help and I kind of have no idea which one needs changing!
        Plus I checked requirements in that link and my system currently has all of them installed.
        I ran make command and got those exact errors again.
        I don't know what to do ...

        1 Reply Last reply
        0
        • M Offline
          M Offline
          mostafanfs
          wrote on last edited by
          #4

          Hi
          I managed to run "configure" and "make" and "make install" commands successfully. You were right. All I did was using some arguments in ./configure command. I ran this command :
          ./configure -nomake doc -nomake examples -nomake demos -fast -no-javascript-jit -no-script -no-scripttools
          I dont know which argument was making problems and I'm not sure if I used the right arguments or not but all that matters to me is that I didn't get any errors !
          By default after running make install command all files go to /usr/local/Trolltech/Qt-4.6.2/
          Now the problem is that I don't know how to use generated files. In bin folder I have following files :
          http://8pic.ir/images/kgxp0828r855vfm3vae1.png
          Which one is Qt ?!
          Am I missing something ?

          1 Reply Last reply
          0
          • T Offline
            T Offline
            tarod.net
            wrote on last edited by
            #5

            Yes, the installation goes there by default.

            But it seems there are less binaries than the usual ones.

            For example, the assistant. Anyway, the important application is qmake to compile Qt applications.

            Do you have the Tools directory?

            Could you try the next configuration:

            ./configure -no-javascript-jit -no-script -no-scripttools

            "Individually, we are one drop. Together, we are an ocean."

            1 Reply Last reply
            0
            • M Offline
              M Offline
              mostafanfs
              wrote on last edited by
              #6

              No I don't have the Tools directory in /usr/local/Trolltech/Qt-4.6.2/
              I ran your configuration (./configure -no-javascript-jit -no-script -no-scripttools) but It ended up with couple of errors as you can see :
              .
              .
              .
              codemodel.h:99:50: note: declarations in dependent base ‘QMultiHash<QByteArray, CodeModel::Type*>’ are not found by unqualified lookup
              codemodel.h:99:50: note: use ‘this->insert’ instead
              make[3]: *** [.obj/release-shared/projectporter.o] Error 1
              make[3]: Leaving directory /usr/local/qt-everywhere-opensource-src-4.6.2/tools/porting/src' make[2]: *** [sub-src-make_default] Error 2 make[2]: Leaving directory /usr/local/qt-everywhere-opensource-src-4.6.2/tools/porting'
              make[1]: *** [sub-porting-make_default-ordered] Error 2
              make[1]: Leaving directory `/usr/local/qt-everywhere-opensource-src-4.6.2/tools'
              make: *** [sub-tools-make_default-ordered] Error 2

              Why would you suggest this? Is it important to have examples and demos compiled?

              The only differences with previous configuration is "-nomake doc -nomake examples -nomake demos -fast" arguments. Probably making one of these is causing problems which is kind of expected especially about examples considering there are lots of them and one of them could cause this.

              Now what is it so important about Tools directory ?
              Plus what should I do now? Can I continue with previous configuration which led to no errors or it wasn't good enough? (considering no Tools directory and less binary files)

              Sorry that I asked a lot of questions! :-)

              1 Reply Last reply
              0
              • T Offline
                T Offline
                tarod.net
                wrote on last edited by
                #7

                Well, demos are important if you need get example code.

                I have Qt Creator in Tools and for me it is an important application to develop in Qt.

                Did you try to install Qt using apt-get?

                You could get Qt using the next command:

                sudo apt-get install qt4-dev-tools libqt4-dev libqt4-core libqt4-gui

                Edit: did you install libx11-dev, right?

                "Individually, we are one drop. Together, we are an ocean."

                1 Reply Last reply
                0
                • M Offline
                  M Offline
                  mostafanfs
                  wrote on last edited by
                  #8

                  Thank you
                  Yes I have tried to install Qt Creator using Ubuntu Software Center but I don't get to choose Qt 4.6.2 version and all it has is the last Qt 5.3 (well actually qtcreator 3.0.1) and I don't know how to configure this version to use my cross compilation tools (arm-linux-gcc 4.4.3) as a compiler.
                  You should know that I want to use arm-linux-gcc 4.4.3 to compile applications in Qt and I don't want to develop softwares for PC or Ubuntu and so on.
                  I will try that apt-get you mentioned and I'll get back to you.
                  Thank you anyway.

                  Edit: Yes I already have the newest version of libx11-dev

                  1 Reply Last reply
                  0
                  • M Offline
                    M Offline
                    mostafanfs
                    wrote on last edited by
                    #9

                    Dude
                    I installed Qt using "sudo apt-get install qt4-dev-tools libqt4-dev libqt4-core libqt4-gui"
                    It has installed Qt Designer 4.8.6 on my system and I don't know what to do with it since it's just a UI designing environment. How am I supposed to configure it for Embedded Linux?

                    I want to do something like this :
                    http://mini2440vietnam.blogspot.com/2011/05/programming-application-for-mini2440-by.html
                    which is why I went through that whole trouble to get Qt4.6.2 working.

                    1 Reply Last reply
                    0
                    • SGaistS Offline
                      SGaistS Offline
                      SGaist
                      Lifetime Qt Champion
                      wrote on last edited by
                      #10

                      Hi,

                      Then don't bother with 4.6.2 if you have a recent linux distribution on your board. Just follow this "guide":http://qt-project.org/doc/qt-4.8/qt-embedded-crosscompiling.html to cross-compile Qt.

                      Interested in AI ? www.idiap.ch
                      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                      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