News:

The new Release 25.03 is out! You can download binaries for Windows and many major Linux distros here .

Main Menu

Code::Blocks + wxWidgeth project no compile clear project: wx* must be defined

Started by ioann, August 06, 2011, 03:58:18 PM

Previous topic - Next topic

ioann

Sorry for my poor English.
IDE: CodeBlocks 10.05
wxWidgeth: 2.8.10 | 2.9.1 | 2.9.2
OS: Windows 7 Pro 64 bit

I have problem on build clear project on wxWidgeth with Code::Blocks. Build show me errors list
QuoteC:\wxMSW-2.8.10\include\wx\platform.h|196|error: wx/setup.h: No such file or directory
C:\wxMSW-2.8.10\include\wx\chkconf.h|103|error: #error "wxUSE_DYNLIB_CLASS must be defined."
...
I already tried:

  • Create project on wx 2.8, 2.9 (SVN)
  • Switch global variable (builtin fields base) between version
  • Compile wxWidgeth

On OS Ubuntu i have error:
Quote/projects/test6/test6App.h|13|fatal error: wx/app.h: No such file or directory|

Goes i no have possibility compile project any platform. Need help, please.
Sorry for my poor English

stahta01

Read http://wiki.codeblocks.org/index.php?title=WxWindowsQuickRef
Quote
I get errors like "wx/setup.h: No such file or directory"

You're missing an important compiler search path in your build options. Make sure you choose the correct wxWidgets build configuration when running the wxWidgets project wizard. If re-running the wizard isn't an option, then open your project's build options and add "$(#wx.lib)\gcc_dll\mswu" (assuming a monolithic Unicode DLL build) to the compiler search paths.


C:\wxMSW-2.8.10\include\wx\platform.h|196|error: wx/setup.h: No such file or directory


Did YOU build wxWidgets?
If not, do so.

If yes, turn on Full Compiler Logging.
http://wiki.codeblocks.org/index.php?title=FAQ#Q:_How_do_I_troubleshoot_an_compiler_problem.3F

You likely have missing or wrong Compiler search directories.

Tim S.
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]

Jenna

On ubuntu you need the packages wx-common and libwxgtk2.8-dev (and all the dependencies of these packages).
After installing them (and restarting C::B, if it is not closed), you should be able to  use the wizard-created wxWidgets-project.

ioann

To stahta01
I no destend this :
QuoteIf re-running the wizard isn't an option, then open your project's build options and add "$(#wx.lib)\gcc_dll\mswu" (assuming a monolithic Unicode DLL build) to the compiler search paths.

Nevertheless:
Complete steps on this
except (where file nmake?):
Quotenmake -f makefile.vc BUILD=release SHARED=1 MONOLITHIC=1 UNICODE=1
And Install wxPack on this steps

And switch Code::Block on new wxWidgeth (path wx on create project and on Settings->GlobalVariables)
QuoteC:\SourceCode\Libraries\wxWidgets2.8
06.08.2011  19:47    <DIR>          .
06.08.2011  19:47    <DIR>          ..
06.08.2011  19:48    <DIR>          additions
06.08.2011  19:47    <DIR>          art
06.08.2011  19:47    <DIR>          build
06.08.2011  19:47    <DIR>          contrib
06.08.2011  19:47    <DIR>          docs
06.08.2011  19:47    <DIR>          include
06.08.2011  19:48    <DIR>          lib
06.08.2011  19:47    <DIR>          locale
06.08.2011  19:47    <DIR>          samples
06.08.2011  19:47    <DIR>          src
06.08.2011  19:48         1я372я740 unins000.dat
06.08.2011  19:47         1я180я223 unins000.exe
06.08.2011  19:47    <DIR>          utils

And Compile clear project - have new error: full log on attach "CodeBlocks_ClProjOnWx_FullLogBuild.txt"

Yes.. This cross platform bigest problem after C# on Visual Studio.
Sorry for my poor English

Jenna

Looks like incomaptible compilers (different exception handling).

Why not compiling wxWidgets yourself, it's quite straightforward.

http://wiki.codeblocks.org/index.php?title=WxWindowsQuickRef#Build_wxWidgets

Don't use nmake and the *.vc makefile, if you use MinGW as your compiler !

Use mingw32-make or make from MinGW and the *.gcc makefile.

ioann

To Jens on second reply
Before i compile wxWidgeth on version wxMSW-2.8.10 and have error list on first post.
QuoteDon't use nmake and the *.vc makefile, if you use MinGW as your compiler !
Ok. I will not. And still not working.
QuoteUse mingw32-make or make from MinGW and the *.gcc makefile.
yes, i use and this long time (5 minute) compiling wxWidgeth
Quotemingw32-make -f makefile.gcc BUILD=release SHARED=1 MONOLITHIC=1 UNICODE=1
Sorry for my poor English

ioann

Sorry for my poor English

ioann

Quote from: jens on August 06, 2011, 05:03:21 PM
On ubuntu you need the packages wx-common and libwxgtk2.8-dev (and all the dependencies of these packages).
After installing them (and restarting C::B, if it is not closed), you should be able to  use the wizard-created wxWidgets-project.
Ok,  Thanks. It's work
Sorry for my poor English

ioann

Sorry for my poor English

Jenna

Quote from: ioann on August 07, 2011, 09:26:18 PM
ideas on how to run under windows, no?
If you follow the steps in the quick-ref as I wrote here:
Quote from: jens on August 06, 2011, 07:32:58 PM
Looks like incomaptible compilers (different exception handling).
Why not compiling wxWidgets yourself, it's quite straightforward.

http://wiki.codeblocks.org/index.php?title=WxWindowsQuickRef#Build_wxWidgets
or
here
it should not be a problem.

Note compiling wxWidgets can take a long time.

Or you need to find a compiler that is compatible with the one used by the one used to build the wxpack-binaries.

ioann

Than you, all!
jens. than you.

Problem with wxWidgeth resolved
on wersion 2.8
Sorry for my poor English