Author Topic: QT 4.1 MinGW and Code::Blocks ?  (Read 23077 times)

Marco812

  • Guest
QT 4.1 MinGW and Code::Blocks ?
« on: February 04, 2006, 11:09:21 pm »
Hi,

i have install Code::Blocks and create an new qt project, then i have add  all *.cpp and *.h from existing project, but i can't compile this project (error <qtgui> no such file directory).

How must i configure Code::Blocks to compile a qt project?
I use QT 4.1 and MinGW!

Thanx in advance,

Marco812

Offline jimp

  • Multiple posting newcomer
  • *
  • Posts: 15
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #1 on: February 05, 2006, 07:18:46 pm »
It looks like you just need a directory path to the QT headers or libraries.  In Project>Build Options, Directories.

Offline yop

  • Regular
  • ***
  • Posts: 387
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #2 on: February 05, 2006, 07:24:52 pm »
How must i configure Code::Blocks to compile a qt project?
I use QT 4.1 and MinGW!
Would you care to try this? You'll need to downlad one of the latest night builds if you 're using Code::Blocks RC2.
Life would be so much easier if we could just look at the source code.

les_insectes_sont_nosamis

  • Guest
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #3 on: February 20, 2006, 12:10:53 am »
hello,

excuse my poor english, i'm a french man...
i'm a newbie in programming in C++, and i want to develop with Code::Blocks and QT

i've installed QT 4.1 on my windows using the file : "qt-win-opensource-4.1.0-mingw.exe" in d:/qt
then i've installed CodeBlocks in d:/codeblocks with the file "codeblocks-1.0rc2_mingw.exe"

well, when i'm doing a new project with QT, , i've got a file :

<<---->>
    #include <QApplication>
    #include <QPushButton>

    int main(int argc, char *argv[])
    {
        QApplication app(argc, argv);

        QPushButton hello("Hello world!");
        hello.resize(100, 30);

        hello.show();
        return app.exec();
    }
<<---->>

but i can't build the project, i've got an error : "main.cpp:1:28: QApplication: No such file or directory"

what must i do ??

thanks a lot !!


Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #4 on: February 20, 2006, 11:47:25 am »
then i've installed CodeBlocks in d:/codeblocks with the file "codeblocks-1.0rc2_mingw.exe"

First I would advice you to give a try to the latest nightly build instead of RC2 (and eventually to download and install MinGW 5.0.2).

About your problem, did you build Qt? AFAIK after downloading it you have to build it.

Also have a look at the helpful post of yop just above :).

Best wishes,
Michael

les_insectes_sont_nosamis

  • Guest
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #5 on: February 20, 2006, 02:23:21 pm »
thank you for your help Michael

apparently, that's work now ... I haven't built QT...
I'va cliked on "Qt 4.1.0 (Build Debug Libraries)"
and i' have got a MSDOS window with command for about 25 minutes !!

and now it seems to work !!

nevertheless, i don't understand what is nightly build and where i can find that ...
and I don't understand lhe Yop's post ....

but finally, that's work and that's the principle !!

thanks for your help

@++


Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #6 on: February 20, 2006, 02:36:24 pm »
Hello,

You can find info about the nightly builds here:

http://www.codeblocks.org/nightly/
http://forums.codeblocks.org/index.php?board=20.0

Is there something that you do not understand about the yop's post, post your question(s) :).

Best wishes,
Michael

les_insectes_sont_nosamis

  • Guest
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #7 on: February 20, 2006, 03:41:23 pm »
HUMM

in fact, I don't understand what is "nightly build"
does that mean that someone build a new codeblocks every night ??
why ??

and the thread with "the xx february 2006 build is out"... I understand anything !!

there are some files with the extension ".7z" ... I failed with open them

in fact I think i suceed in buiding QT, and that seem to work... so I will do some tutorials and if there is a problem I will come back


you know, i'm new with programming and compiling, and it is not easy to undersand some concepts in another language than your mother tongue.



thank you
@+++



Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #8 on: February 20, 2006, 05:11:39 pm »
HUMM

in fact, I don't understand what is "nightly build"
does that mean that someone build a new codeblocks every night ??
why ??

A nightly build is an unofficial version of C::B (RC is instead an official version). A nightly build is a C::B build which represents the actual development status. Each night there is a new one (C::B devs work not only very good, but very fast too :D), which includes the features and bug fixes done from the previous nightly build. Nightly build is a kind of service offered to C::B users who do not want or cannot compile SVN sources and/or wait until the new release.

We have to thank Killerbot for providing each night a new nightly build. A big thank you :D.
 
there are some files with the extension ".7z" ... I failed with open them

.7z files are files compressed with 7zip. It's compressed much better than WinZip or WinRar. Moreover it is free. Check it out here.

you know, i'm new with programming and compiling, and it is not easy to undersand some concepts in another language than your mother tongue.

Yes, I can understand this very well. Anyway, in computer science English is practically mandatory. English is not so difficult to learn and it is for sure a very good investment :).

Best wishes,
Michael

les_insectes_sont_nosamis

  • Guest
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #9 on: February 20, 2006, 06:27:44 pm »
ok thank u very much !!

I understand :D

wooh !! one version per day !! yes, thank u Killerbot !!

thks for 7zip, i didn't know that, and it's very cool !!


merci et a bientot ;)



Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #10 on: February 20, 2006, 09:16:39 pm »
ok thank u very much !!

I understand :D

wooh !! one version per day !! yes, thank u Killerbot !!

thks for 7zip, i didn't know that, and it's very cool !!


merci et a bientot ;)

Pas de problemes!

A ton service.

A+.

Michael

les_insectes_sont_nosamis

  • Guest
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #11 on: February 21, 2006, 12:31:41 am »
oh, mais je vois que tu ecris extremement bien le francais ...
je vais pouvoir ecrire en francais donc  :P

@++

Offline TDragon

  • Lives here!
  • ****
  • Posts: 943
    • TDM-GCC
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #12 on: February 21, 2006, 01:20:59 am »
Ou il utilise le Babel Fish Translator. Est très utile pour ceci.
https://jmeubank.github.io/tdm-gcc/ - TDM-GCC compiler suite for Windows (GCC 9.2.0 2020-03-08, 32/64-bit, no extra DLLs)

Offline mandrav

  • Project Leader
  • Administrator
  • Lives here!
  • *****
  • Posts: 4315
    • Code::Blocks IDE
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #13 on: February 21, 2006, 08:32:48 am »
Parlez Anglais ici, s' il vous plait ;)

(PS: my French are really rusty)
Be patient!
This bug will be fixed soon...

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #14 on: February 21, 2006, 09:18:35 am »
Parlez Anglais ici, s' il vous plait ;)

Sorry :oops:.

@les_insectes_sont_nosamis: Yes, I speak French (it is quite a second mother language for me) :). If you really would cannot translate you question in English, you can send me a PM in French.

@TDragon: No, I did not use Babel Fish Translator :wink:. But I agree with you. It is relatively useful :).

Best wishes,
Michael

sethjackson

  • Guest
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #15 on: February 21, 2006, 04:42:11 pm »
@TDragon: No, I did not use Babel Fish Translator :wink:. But I agree with you. It is relatively useful :).

Yeah Babel Fish is cool. Seeing I only know English (native language), and very little Spanish......

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #16 on: February 21, 2006, 10:04:20 pm »
Hello,

Sorry for being a bit off-topic, but I have found this website that could be useful for people using Qt.

Best wishes,
Michael

Offline yop

  • Regular
  • ***
  • Posts: 387
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #17 on: February 21, 2006, 10:42:24 pm »
Sorry for being a bit off-topic, but I have found this website that could be useful for people using Qt.
It is the best community forum for Qt though it's relatively new (well not quite as the guys who run it where running www.qtforum.org but that one is kind of old news). Also the Qt mailing list is a great resource but probably not for inexperienced users.
Life would be so much easier if we could just look at the source code.

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #18 on: February 21, 2006, 10:50:19 pm »
Also the Qt mailing list is a great resource but probably not for inexperienced users.

Yes you are right. The mailing list is helpful und really active :).

It seems that there are more Qt communities as 1-2 years ago. I have also found prog.qt (in french), which seems to be good.

Best wishes,
Michael

Offline yop

  • Regular
  • ***
  • Posts: 387
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #19 on: February 21, 2006, 10:57:26 pm »
...I have also found prog.qt (in french), which seems to be good.
Well thanks but for me it's as usefull as this one. Me not speak French :lol:
Since we're on the subject may I also suggest the Object-Oriented Programming and Design Patterns in C++ with Qt 4 book? (you'll have to sign on first)
Life would be so much easier if we could just look at the source code.

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #20 on: February 21, 2006, 11:05:42 pm »
Well thanks but for me it's as usefull as this one. Me not speak French :lol:

Touché.... :lol:

Since we're on the subject may I also suggest the Object-Oriented Programming and Design Patterns in C++ with Qt 4 book? (you'll have to sign on first)

I did not know it. In my first impression it seems really good (and free is even better). Thank you very much for the info. I really appreciate it :D.

Best wishes,
Michael

les_insectes_sont_nosamis

  • Guest
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #21 on: February 22, 2006, 12:04:37 am »
hello,

and sorry for having speaking french, but english is everywhere, so when I can speak french, it's a good news for me :D

so, I've posted a message in another forum (the french one :D) and a man answered me !

and now that's work !!

it's a little bit "complex" but the programs run !!!

thank u for your help, especially the private help of Michael with my mother tongue :D

for those who are interested , a solution is here

@++++


« Last Edit: February 22, 2006, 12:06:55 am by les_insectes_sont_nosamis »

Offline szczepan

  • Multiple posting newcomer
  • *
  • Posts: 42
[OT] English "easy" to learn
« Reply #22 on: March 06, 2006, 09:23:02 pm »
Yes, I can understand this very well. Anyway, in computer science English is practically mandatory. English is not so difficult to learn and it is for sure a very good investment :).

English is quite easy to learn to understand but difficult like hell to learn to speak/write (as this very sentence proves ;) ).

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: [OT] English "easy" to learn
« Reply #23 on: March 06, 2006, 09:29:42 pm »
English is quite easy to learn to understand but difficult like hell to learn to speak/write (as this very sentence proves ;) ).

Well, I find it not so difficult to speak/write, especially when compared with language such as e.g., Portuguese (Brazil), Thai :D. IMHO the best way to learn a language is to practice. Each day a bit.

Anyway, you can practice you writing skill by posting in this or other english forums. After some days, you will feel that you can write easily in english :D.

Best wishes,
Michael

RockV

  • Guest
Re: QT 4.1 MinGW and Code::Blocks ?
« Reply #24 on: October 03, 2006, 05:00:37 am »
I am just installing C::B and Qt4 and find the same error...

I solved it by setting the include directories and lib directory in Settings / Compiler / Directories...
I put C:\Qt\4.1.4\include\Qt and C:\Qt\4.1.4\include\QtGui in compiler.
and put C:\Qt\4.1.4\lib in Linker.
Maybe I should add the other qt4 directories...

RockV