Results 1 to 8 of 8

Thread: compiling in linux

  1. #1
    Join Date
    Feb 2009
    Posts
    53
    Thanks
    5

    Default compiling in linux

    Hi Is somewhere some manual how compile source in Linux? I wrote source code under windows and I want to compile this file in linux I use Fedora and KDE,
    It is same like in windows? What I have to prepare for compiling? when I try wrote in console qmake -o Makefile project.pro
    and then make I wrote, that it doesnot know for example
    #include <QMainWindow>
    #include <QObject>

    I am trying find in google, but I find nothing

  2. #2
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: compiling in linux

    If I understand you right, the compiler doesn't find the qt header files. Then I guess, you haven't install qt properly. Normally in Linux you need also the *-dev files. So check your installation to be correct. And what does "echo $QTDIR" says?

    Further you can read http://doc.trolltech.com/4.5/install-x11.html

    Eventual post the error message you get. For "qmake && make".

  3. The following user says thank you to Lykurg for this useful post:

    Noxxik (19th March 2009)

  4. #3
    Join Date
    Feb 2009
    Posts
    53
    Thanks
    5

    Default Re: compiling in linux

    Quote Originally Posted by Lykurg View Post
    If I understand you right, the compiler doesn't find the qt header files. Then I guess, you haven't install qt properly. Normally in Linux you need also the *-dev files. So check your installation to be correct. And what does "echo $QTDIR" says?

    Further you can read http://doc.trolltech.com/4.5/install-x11.html

    Eventual post the error message you get. For "qmake && make".
    So I try to use google and I find, what you wrote (...the compiler doesn't find the qt header files...) there is some solution...

    Qt Code:
    1. /usr/bin/qmake-qt4 -project
    2. /usr/bin/qmake-qt4
    3. make
    To copy to clipboard, switch view to plain text mode 
    and everything is OK


    So one more question. How can I remove all *.o file or some other files, which was created during compilation?

    Thank a lot

  5. #4
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: compiling in linux

    "make clean"

  6. The following user says thank you to Lykurg for this useful post:

    Noxxik (20th March 2009)

  7. #5
    Join Date
    Feb 2009
    Posts
    53
    Thanks
    5

    Default Re: compiling in linux

    Quote Originally Posted by Lykurg View Post
    "make clean"
    thanks once again

  8. #6
    Join Date
    Feb 2009
    Posts
    53
    Thanks
    5

    Default Re: compiling in linux

    Quote Originally Posted by Lykurg View Post
    If I understand you right, the compiler doesn't find the qt header files. Then I guess, you haven't install qt properly. Normally in Linux you need also the *-dev files. So check your installation to be correct. And what does "echo $QTDIR" says?

    Further you can read http://doc.trolltech.com/4.5/install-x11.html

    Eventual post the error message you get. For "qmake && make".
    one more question: I tried in another Linux, where I can change nothing. so what was OK in my Fedora in the another Linux is KO
    for "echo $QTDIR" console says: /usr/lib/qt-3.3
    do you know how I can solve it?

  9. #7
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: compiling in linux

    Qt Code:
    1. lykurg@xxx:~$ echo $WHATEVER
    2.  
    3. lykurg@xxx:~$ export WHATEVER=hihihi
    4. lykurg@xxx:~$ echo $WHATEVER
    5. hihihi
    6. lykurg@xxx:~$ export WHATEVER=hohoho
    7. lykurg@xxx:~$ echo $WHATEVER
    8. hohoho
    9. lykurg@xxx:~$
    To copy to clipboard, switch view to plain text mode 

    Assuming you want chance to qt4.

  10. The following user says thank you to Lykurg for this useful post:

    Noxxik (23rd March 2009)

  11. #8
    Join Date
    Feb 2009
    Posts
    53
    Thanks
    5

    Default Re: compiling in linux

    thanks but I think that problem was bad version od qmake...
    I had to /path.../qmake -o Makefile project.pro and everything is OK... So I hope that it is all

Similar Threads

  1. Replies: 5
    Last Post: 15th January 2009, 09:03
  2. Compiling Problem qt/embedded 4.4.1 linux scratchbox arm
    By hw in forum Installation and Deployment
    Replies: 0
    Last Post: 11th September 2008, 19:25
  3. Weird problem: multithread QT app kills my linux
    By Ishark in forum Qt Programming
    Replies: 2
    Last Post: 8th August 2008, 09:12
  4. Compiling Linux project on Mac
    By December in forum Newbie
    Replies: 2
    Last Post: 25th March 2007, 04:25
  5. Cross compiling QT3 on Linux, for win32
    By mjrich in forum Installation and Deployment
    Replies: 10
    Last Post: 6th March 2006, 18:58

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.