Author Topic: Can't compile or link anything  (Read 7150 times)

pix0l

  • Guest
Can't compile or link anything
« on: July 30, 2005, 08:27:01 am »
Hi, I'm using codeblocks 1.0 on Windows XP home along with Microsoft 2003 tool kit compiler. I first ran codeblocks before installing 2003 compiler so I had to set the compiler manually by going to settings->configure plugins->compiler and choosing 2003. I created a new win32 project and setup my include and library paths etc and set the compiler to 2003 again for the project. When I try to compile I get an error "Command execution failed...". I got another message saying the compiler couldn't be found and I most likely won't be able to compile anything. So I look in the compiler settings again under the program tab and see the directory is correct: C:\Program Files\Microsoft Visual C++ Toolkit 2003. What's going on? How come I can't compile anything? I feel like a retard with add. Help me before I break my keyboard.

Offline rickg22

  • Lives here!
  • ****
  • Posts: 2283
Re: Can't compile or link anything
« Reply #1 on: July 30, 2005, 09:23:13 am »
You can try setting the compiler advanced optoins to log "full command line". Then paste the compiler log here.

pix0l

  • Guest
Re: Can't compile or link anything
« Reply #2 on: July 30, 2005, 09:43:09 am »
Hi, where can I set this option? I see settings->configure plugins->compiler->other tab->advanced options but I don't see any logging options there. Sorry for the incompetence. This really shouldn't be difficult.

Offline mandrav

  • Project Leader
  • Administrator
  • Lives here!
  • *****
  • Posts: 4315
    • Code::Blocks IDE
Re: Can't compile or link anything
« Reply #3 on: July 30, 2005, 10:16:39 am »
I first ran codeblocks before installing 2003 compiler so I had to set the compiler manually by going to settings->configure plugins->compiler and choosing 2003.

You can go to "Settings->Compiler->[Choose VCToolkit]->Programs" and click on "Auto-detect". This should set everything up...

Yiannis.
Be patient!
This bug will be fixed soon...

Offline squizzz

  • Almost regular
  • **
  • Posts: 132
Re: Can't compile or link anything
« Reply #4 on: July 30, 2005, 01:28:31 pm »
If you manage to set up VC Toolkit 2003 executables properly, don't forget to grab and install Platform SDK from Microsoft site. It contains useful C/C++ header files and *.lib-raries - you won't be able to compile much without it.

BTW. one user of Ogre's forum made a quite detailed instruction how to set up VCToolkit + C::B + Ogre, maybe it can help you, just skip the Ogre part. :)
this space is for rent

pix0l

  • Guest
Re: Can't compile or link anything
« Reply #5 on: July 30, 2005, 07:10:39 pm »
Hi squizzz, I've got platform sdk already and I'm actually using Ogre and I did use their Wiki to configure code::blocks.

mandrav, the path you've told me to follow doesn't exist. The closest thing I've got is "settings->configure plugins->compiler" VC Toolkit is selected but under the programs tab there is no "Auto detect". The build I'm using is from January 4th 2005. I'm thinking this probably isn't the most recent build? I'll try uninstalling and seeing if I can find a newer version.

pix0l

  • Guest
Re: Can't compile or link anything
« Reply #6 on: July 30, 2005, 07:30:15 pm »
Hi again. I am retarded. Somehow I downloaded an older version of code::blocks. I uninstalled it and reinstalled a newer one and finally got a windows app to compile. Now the next step is trying to get my Ogre application to compile and run without crashing. Thanks for your replies. :D

grv575

  • Guest
Re: Can't compile or link anything
« Reply #7 on: August 08, 2005, 06:17:49 am »
If it compiles ok using VC++ toolkit but crashes when run then make sure you enable "C++ exceptions" (/GX = /Ehsc VC++ compiler option) AND remove the __GNUWIN32__ define.