Author Topic: How to compile a file which is part of a project (C++)???  (Read 5102 times)

Offline rohith

  • Multiple posting newcomer
  • *
  • Posts: 11
How to compile a file which is part of a project (C++)???
« on: July 22, 2008, 03:20:07 am »
Hi everyone.

I am unable to compile a file which is a part of a project. When I tried to I received the following message-

"Nothing to be done".
         
Can someone help me out.
                 
                  Any help would be highly appreciated.
« Last Edit: July 24, 2008, 02:34:22 am by rohith »

Offline frithjofh

  • Regular
  • ***
  • Posts: 376
Re: How to compile a file which is part of a project (C++)???
« Reply #1 on: July 26, 2008, 02:44:27 pm »
hi,

I not a guru of programming, but perhaps I can help you. The effect you tell happens as far as my experience is concerned either when you try to compile a *.cpp file which did not suffer any changes since the last time or when you try to compile a header file with or without changes made. In the latter case it only saves the changes and does nothing more. You will have to try to compile the corresponding source file (*.cpp) in order to compile the header in.

Assuming you are using the keys alt+F9 to compile a single file, I hope I could help you in any way.

Greetings

nausea
architect with some spare time  -  c::b compiled from last svn  -   openSuSE leap x86_64  -  AMD FX-4100

Offline frithjofh

  • Regular
  • ***
  • Posts: 376
Re: How to compile a file which is part of a project (C++)???
« Reply #2 on: July 26, 2008, 08:10:23 pm »
ah, sorry, the right key combination is Ctrl+Shift+F9 of course, sorry for the error, the finger know, the mind doesn't.

and the reason for the behavior of codeblocks: in a header file there normally is no source code, only declarations and similar, these do not compile but serve the compiler and linker to get his work done and to do some checking of types and so ...

Ciau
architect with some spare time  -  c::b compiled from last svn  -   openSuSE leap x86_64  -  AMD FX-4100

Offline rohith

  • Multiple posting newcomer
  • *
  • Posts: 11
Re: How to compile a file which is part of a project (C++)???
« Reply #3 on: July 27, 2008, 03:41:58 am »
Thanks for ur help.

Regards.
Rohith