Nish
Nish

Reputation: 189

failed to build codeblocks smith wxWidget project

I am trying to setup code::blocks smith to do wxWidgets GUI programming. Recently I installed code::blocks and wxWidget libraries to my PC.

code::blocks IDE version: 13.12
wxWidget version: 2.8.12
Operating System: Windows 7

Below is the build log for the wxWidget project. I followed the instructions listed in wxWidget web site but didn't work.

-------------- Build: Debug in CsBarcodeScanner (compiler: GNU GCC Compiler)---------------

mingw32-g++.exe -pipe -mthreads -D__GNUWIN32__ -D__WXMSW__ -DwxUSE_UNICODE -Winvalid-pch -include wx_pch.h -DWX_PRECOMP -Wall -g -D__WXDEBUG__ -IC:\wxWidgets-2.8.12\include -IC:\wxWidgets-2.8.12\lib\gcc_lib\mswud -c C:\Data\CsBarcodeScanner\wx_pch.h -o wx_pch.h.gch\Debug_wx_pch_h_gch
In file included from C:\wxWidgets-2.8.12\include/wx/platform.h:293:0,
                 from C:\wxWidgets-2.8.12\include/wx/defs.h:21,
                 from C:\wxWidgets-2.8.12\include/wx/wxprec.h:13,
                 from ./wx_pch.h:14,
                 from <command-line>:0:
C:\wxWidgets-2.8.12\include/wx/chkconf.h:1817:9: error: #error "wxClipboard requires wxDataObject"
Process terminated with status 1 (0 minute(s), 2 second(s))
1 error(s), 0 warning(s) (0 minute(s), 2 second(s))

Upvotes: 1

Views: 1313

Answers (1)

VZ.
VZ.

Reputation: 22688

Have you edited wx/setup.h file? By default, wxUSE_DATAOBJECT should be set to 1 in it so I don't see how can this error occur with unmodified sources.

Also, I'd strongly recommend using wxWidgets 3.0, there is absolutely no reason to use 2.8 for a new project.

Upvotes: 1

Related Questions