Results 1 to 12 of 12

Thread: QMAKESPEC has not been set, so configuration cannot be deduced

  1. #1
    Join Date
    Jul 2006
    Posts
    18
    Thanks
    2
    Qt products
    Qt4
    Platforms
    Unix/X11

    Post QMAKESPEC has not been set, so configuration cannot be deduced

    hi to everyone,
    i'm new to this forum.. i installed qt-x11-opensource-src-4.1.4 version n wrote a simple program to vieww the dialog box that was created using qtdesigner from command mode.
    the commands that were used are,uic -o sample.h sample.ui .... to generate a sample.h file
    qmake -project sample.pro ......... to create a .pro file
    qmake -o makefile qt.pro ............. to build the file
    but when i gave that command i got the following errors,
    ................................
    MAKESPEC has not been set, so configuration cannot be deduced.
    Error processing project file: qt.pro
    ..................

    so please suggest me now what should i do?

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    Quote Originally Posted by Rekha
    qmake -project sample.pro
    qmake -o makefile qt.pro
    Shouldn't it be "qmake -o makefile sample.pro"?

  3. #3
    Join Date
    Jul 2006
    Posts
    18
    Thanks
    2
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    By default the .pro file generated by this command,
    qmake -project sample.pro
    is
    qt.pro..
    so i need to use that qt.pro than sample.pro
    PLZ help me in solving this problem

  4. #4
    Join Date
    Jan 2006
    Location
    Bremen, Germany
    Posts
    554
    Thanked 86 Times in 81 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    And what keeps you from setting QMAKESPEC? Or from using "qmake -spec linux-g++" or whatever your spec is?

  5. #5
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    Quote Originally Posted by Rekha
    By default the .pro file generated by this command,
    qmake -project sample.pro
    is
    qt.pro..
    so i need to use that qt.pro than sample.pro
    No, you don't --- you just forgot to add "-o" before sample.pro:
    qmake -project -o sample.pro

  6. #6
    Join Date
    Jan 2009
    Location
    Barcelona
    Posts
    5
    Thanks
    1
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    I know is an old issue, but still unanswered...

    Maybe the error is because you didn't load the QMAKESPEC env variable. You can look the ones you can choose on /usr/share/qt4/qmakespec (or qt3, depending)

    set env QMAKESPEC linux-g++ (or instead linux-g++, yours)

    In the compilation directory:

    qmake -project
    qmake
    make
    Last edited by javi; 27th January 2009 at 11:16.

  7. #7
    Join Date
    Feb 2009
    Posts
    3
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    Hi, I've just got a similar question..
    Is it normal not to have the folder '/usr/..../mkspecs' when compiling Qt4 from source ? Because I didn't get it after 'make install' ?
    I managed to copy it from somewhere else .. but is this normal ?
    Last edited by yehdev_cc; 1st February 2009 at 06:01.

  8. #8
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    Quote Originally Posted by yehdev_cc View Post
    Is it normal not to have the folder '/usr/..../mkspecs' when compiling Qt4 from source ?
    Did you pass any paths to configure?

  9. #9
    Join Date
    Feb 2009
    Posts
    3
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    Did you pass any paths to configure?
    No I didn't ...

  10. #10
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    Quote Originally Posted by yehdev_cc View Post
    No I didn't ...
    Then Qt should install itself in /usr/local/Trolltech/Qt-<version>. What does "qmake -query QMAKE_MKSPECS" print?

  11. #11
    Join Date
    Feb 2009
    Posts
    3
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    I just copied this directory from elsewhere... so, the output now may not give a very useful information about the problem .. I think.
    I just don't know why this happened.. it should have created the folder, as make completed successfully without errors...

  12. #12
    Join Date
    Aug 2008
    Posts
    15
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QMAKESPEC has not been set, so configuration cannot be deduced

    Just add this to the script before you run qmake.
    Unix Bourne shell:

    QMAKESPEC=/usr/local/qt/mkspecs/linux-g++
    PATH=$PATH:/local/qmake/bin
    export QMAKESPEC PATH

    Unix C shell:

    setenv QMAKESPEC /usr/local/qt/mkspecs/linux-g++
    setenv PATH $PATH:/local/qmake/bin

    Microsoft Windows:

    set QMAKESPEC=c:\qt\mkspecs\win32-msvc
    set PATH=%PATH%;c:\qmake\bin

    qmake is now installed.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.