Author Topic: General questions  (Read 20964 times)

Offline johne53

  • Regular
  • ***
  • Posts: 253
General questions
« on: April 20, 2007, 11:55:52 pm »
Hi there. Pretty soon I'll be starting a project that I need to compile for Linux. I don't have any real experience with Linux although I've been programming for Windows for over 10 years. I'm looking for an IDE that will give me similar functionality to MS Visual Studio and Code::Blocks is one of the products that's been mentioned to me. I just wondered about the following things:-

1) Will Code::Blocks allow me to do source level debugging of C++ apps (i.e. setting break points and stepping through the source code, line-by-line) ?
2) Does it have its own built-in compiler or does it use an external utility, such as 'Make' ?
3) Is it compatible with Scons? (Scons is an enhanced form of Make)
4) Does it have syntax highlighting - either using a built-in editor or via an external editor?

Thanks,

John

Offline raph

  • Almost regular
  • **
  • Posts: 242
Re: General questions
« Reply #1 on: April 21, 2007, 12:33:46 am »
Hi,
welcome to the forums
1) Will Code::Blocks allow me to do source level debugging of C++ apps (i.e. setting break points and stepping through the source code, line-by-line) ?
Yes
2) Does it have its own built-in compiler or does it use an external utility, such as 'Make' ?
It does not have any built-in compiler, since it is an ide.
Codeblocks does support a lot of different compilers. So you could e.g. write your applications with cb and compile them with microsofts compiler (visual C++).
You don't need Makefiles, since cb will know which commands to execute to compile your programs but you surely can use your own external application/script.
3) Is it compatible with Scons? (Scons is an enhanced form of Make)
Yes, you can write a scons script manually and let cb execute it.
4) Does it have syntax highlighting - either using a built-in editor or via an external editor?
Yes, just have a look at the screenshots.

Regards
raph

Offline johne53

  • Regular
  • ***
  • Posts: 253
Re: General questions
« Reply #2 on: April 21, 2007, 09:49:55 am »
Thanks Raph - this sounds like it's exactly what I need. Just out of interest.... is this the same Code::Blocks product that can be found here:-

http://developer.berlios.de/project/showfiles.php?group_id=5358 ?

Don't be surprised if you can't get onto the Berlios web site. I've found it to be massively unreliable.

Offline johne53

  • Regular
  • ***
  • Posts: 253
Re: General questions
« Reply #3 on: April 22, 2007, 04:22:48 pm »
Because I'm not too familiar with Linux yet, I might install the Windows version until I become familiar with Code::Blocks. I use MFC a lot - so should I choose the version with MINGW compiler or the version with no compiler? (in fact, is there even support for MFC?)

Offline raph

  • Almost regular
  • **
  • Posts: 242
Re: General questions
« Reply #4 on: April 22, 2007, 05:09:29 pm »
Because I'm not too familiar with Linux yet, I might install the Windows version until I become familiar with Code::Blocks. I use MFC a lot - so should I choose the version with MINGW compiler or the version with no compiler? (in fact, is there even support for MFC?)
It is highly recommended to not use version RC2 (its too old), but to use a current nightly version.
Grab a nightly here and migw, the win32 port of gcc, here.
Sorry, you won't be able to use mfc with mingw, since it is a microsoft product for sale (anyway, afaik it hasn't been improved for some time in favor of .net now).
I was using MFC, too and I recommend you to try out the wxWidgets framework.
It should be very easy for you, since wxWidgets code style is very similar to mfcs one (see this article: http://www.codeproject.com/library/wxwidgets.asp).
wxWidgets also has the advantage, that it is OpenSource, cross platform, and it looks native on each platform.

Offline johne53

  • Regular
  • ***
  • Posts: 253
Re: General questions
« Reply #5 on: April 24, 2007, 08:18:29 am »
I've got some time today so I'll download the Windows version and give it a try. BTW, was MIGW a typo or is it an alternative version of MINGW - or are they both different products??

Also, is there ANY support for Microsoft compilers - even via MAKE ?

Offline raph

  • Almost regular
  • **
  • Posts: 242
Re: General questions
« Reply #6 on: April 24, 2007, 09:33:55 am »
I've got some time today so I'll download the Windows version and give it a try. BTW, was MIGW a typo or is it an alternative version of MINGW - or are they both different products??
Typo sorry.

Also, is there ANY support for Microsoft compilers - even via MAKE ?
Yes, CB does support Microsoft compilers (using build systems should be possible).
« Last Edit: April 24, 2007, 09:37:55 am by raph »

Offline johne53

  • Regular
  • ***
  • Posts: 253
Re: General questions
« Reply #7 on: April 24, 2007, 12:53:35 pm »
Thanks again, raph.

Now this is going to sound like a dumb question - but if MS compiler is supported, why no support for MFC?

The whole of MFC is available as source code AFAIK...  :?:

Also - why no 'confused' icon - lol  :)

Offline Biplab

  • Developer
  • Lives here!
  • *****
  • Posts: 1874
    • Biplab's Blog
Re: General questions
« Reply #8 on: April 24, 2007, 01:09:21 pm »
Now this is going to sound like a dumb question - but if MS compiler is supported, why no support for MFC?

C::B can compile MFC based code provided appropriate compiler settings, libraries are used.

Be a part of the solution, not a part of the problem.

Offline Charon

  • Multiple posting newcomer
  • *
  • Posts: 49
  • fnord
    • charon - where mental illness meets chronic nonsense
Re: General questions
« Reply #9 on: April 24, 2007, 02:41:17 pm »
Since you usually get MFC precompiled with the Microsoft Compiler, MINGW does not support it (this has something to do with ABI compatibility as long as i know, google can give you the proper answer).

Some sources on the net say that MFC *can* be compiled with MINGW (you get the sourcecode for it with the Microsoft Platform SDK), but the lincense forbids you to redistribute it.

Hi there. Pretty soon I'll be starting a project that I need to compile for Linux.
I hope you know that MFC is Microsoft only and can't be used on Linux.

So you better go with wxWidgets.

Good Luck
Markus
« Last Edit: April 24, 2007, 02:48:11 pm by Charon »
hi, i am a signature virus. please copy me into your sig!
Wish list : no root-node for workspaces, open files and symbols; world domination

Offline johne53

  • Regular
  • ***
  • Posts: 253
Re: General questions
« Reply #10 on: April 24, 2007, 02:57:20 pm »
I hope you know that MFC is Microsoft only and can't be used on Linux.

Yes thanks - the only reason I'm asking is that all my existing projects are for Windows so my plan was to try out Code::Blocks with a project that I'm already familiar with. Ultimately of course I'll need the Linux installation but since I'm already familiar with Windows programming, I think that this approach might avoid me dealing with too many unknown quantities all at once.

Offline johne53

  • Regular
  • ***
  • Posts: 253
Re: General questions
« Reply #11 on: April 25, 2007, 11:27:27 am »
Downloaded Code::Blocks this morning (from last night's build) but when I attempt to start it I get this error message:-

The application failed to start because wxmsw26u_gcc_cb.dll was not found.

Under Windows, DLL's normally reside in the \Windows\System or \Windows\System32 folders. I've tried putting the DLL into both those folders and I also put it into the same folder as codeblocks.exe (which, on my system, is E:\Program Files\CodeBlocks). However, I still get the error message. Any ideas?

Offline ANIRBAN GHOSH

  • Multiple posting newcomer
  • *
  • Posts: 19
Re: General questions
« Reply #12 on: April 25, 2007, 11:59:18 am »
Yes that happened because you have overwritten the old IDE files! Do not overwrite! Extract the 'build' into one folder other than the installed folder (ex C:\Code_Blocks), then put inside the dll files(mingw10 and wxmsw26u_gcc_cb.dll). Run the IDE from the exe in this folder.

Offline johne53

  • Regular
  • ***
  • Posts: 253
Re: General questions
« Reply #13 on: April 25, 2007, 02:02:59 pm »
I'm sorry, I don't understand. I don't have any 'old' IDE. This is my first installation. Do you mean that I should have installed an older version first?

Offline Charon

  • Multiple posting newcomer
  • *
  • Posts: 49
  • fnord
    • charon - where mental illness meets chronic nonsense
Re: General questions
« Reply #14 on: April 25, 2007, 02:18:32 pm »
I guess he assumed that you are installing a nightly over an older RC2 installation.

Sorry, no idea for your specific problem :-(
hi, i am a signature virus. please copy me into your sig!
Wish list : no root-node for workspaces, open files and symbols; world domination