Author Topic: Problems with Visual C++ 2008 Express edition  (Read 9817 times)

echelon

  • Guest
Problems with Visual C++ 2008 Express edition
« on: July 18, 2009, 06:43:30 pm »
Hello,

first post here, so hello to everybody.

I did a search on the forum before posting, but didn't find anything related to my problem. Apologies if this has been discussed before.

The environment is WinXP SP2+Codeblocks 8.02+wxWidgets 2.8.10.
I installed and compiled wxWidgets with Visual C++ 2008 Express edition, and everything went fine.
I was also able to compile and run all (but 5 requiring OpenGL that are not installed on my machine) of the wxWidgets samples, so the wxWidget install looks fine.

Then I installed Codeblocks, that autodected the presence of Visual C++ and set the corresponding path and lib information into the Compiler (C:\Program Files\Microsoft SDKs\Windows\v6.0A\include & C:\Program Files\Microsoft Visual Studio 9.0\VC\include) and Linker (C:\Program Files\Microsoft SDKs\Windows\v6.0A\lib & C:\Program Files\Microsoft Visual Studio 9.0\VC\lib).

So, I tried to compile the standard project that is automatically created by Codeblocks when choosing the "wxWidgets project" from the wizard, but I get the following error

> C:\wxWidgets-2.8.10\include\wx\platform.h|196|fatal error C1083: Cannot open include file: 'wx/setup.h': No such file or directory|

I've fiddled with the settings of the include directories, but only to get include errors in other wxWidgets include files.
Given that Visual C++ is correctly compiling the sample projects of wxWidgets, I suspect that there is some setup problem with Codeblocks.

Can someone help me, please?

Many thanks in advance.

-- Echelon

Offline GeO

  • Multiple posting newcomer
  • *
  • Posts: 51
Re: Problems with Visual C++ 2008 Express edition
« Reply #1 on: July 18, 2009, 06:54:24 pm »
> C:\wxWidgets-2.8.10\include\wx\platform.h|196|fatal error C1083: Cannot open include file: 'wx/setup.h': No such file or directory|

Add C:\wxWidgets-2.8.10\lib\vc_lib\mswu or mswud to the include directories

Greets GeO

echelon

  • Guest
Re: Problems with Visual C++ 2008 Express edition
« Reply #2 on: July 18, 2009, 07:11:21 pm »
Hello GeO,

thanks a lot for your prompt reply, that solved the setup.h problem.
However, now I have a linking problem, as the linker says it cannot find the
wxmsw28d.lib file.
I've tried to add some dir to the Linker directories, but without success.
Actually, the search for that file in the wxWindows installation directory
does not yield any result, so the file seems not to be there.
What I instead found are various files named 'wxmsw28d_*.llib'
(where * is adv, aui, core, etc.).
So, I suspect that I'm again doing something wrong.

Could you help me again, please?

Thanks a lot,

-- Echelon

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: Problems with Visual C++ 2008 Express edition
« Reply #3 on: July 18, 2009, 07:35:13 pm »
Create a wxWdgets-project with the wizard and have a look how it can be done.

This wiki-page might also be of interest for you:
Code
http://wiki.codeblocks.org/index.php?title=Global_compiler_variables

Offline GeO

  • Multiple posting newcomer
  • *
  • Posts: 51
Re: Problems with Visual C++ 2008 Express edition
« Reply #4 on: July 18, 2009, 07:52:57 pm »
However, now I have a linking problem, as the linker says it cannot find the
wxmsw28d.lib file.
What I instead found are various files named 'wxmsw28d_*.llib'
(where * is adv, aui, core, etc.).
Just add these libraries (or at least wxmsw28d_core.lib) to your linkersettings!
or to make it easier (as jens said) create a new wxwidget-project and select there the right options
(I think the right for your compilation is -no unicode(-ansi), -multilib, -static))

I hope that this will help you!
Greets GeO!