Author Topic: Turn Empty Project into a Wxwidgets Project?  (Read 5973 times)

Offline Stevie

  • Single posting newcomer
  • *
  • Posts: 7
Turn Empty Project into a Wxwidgets Project?
« on: June 27, 2007, 03:32:14 pm »
I was building a simple application using wxwidgets.
i did that by creating an Empty Project in code:blocks.
but then it seems that, i couldnt compile it properly.
is there any way to compile it by doing some settings? other than creating a new wxwidgets project ?

Thanks Much!

Offline TDragon

  • Lives here!
  • ****
  • Posts: 936
    • Twilight Dragon Media
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #1 on: June 27, 2007, 03:44:52 pm »
You could create a new wxWidgets project as a test and examine the differences in settings between the two projects.
http://tdm-gcc.tdragon.net/ - TDM-GCC compiler suite for Windows (GCC 5.1.0 2015-06-28, 32/64-bit, no extra DLLs)

Offline mandrav

  • Project Leader
  • Administrator
  • Lives here!
  • *****
  • Posts: 4291
    • Code::Blocks IDE
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #2 on: June 27, 2007, 03:48:22 pm »
Or create a new build target using the wxwidgets wizard (File->New->Target).
Be patient!
This bug will be fixed soon...

Offline Stevie

  • Single posting newcomer
  • *
  • Posts: 7
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #3 on: June 27, 2007, 04:05:36 pm »
Thanks for the replies..

i did try to create a wxwidgets project and check out the different..
even when i did every setting inside the "build option" exactly the same for both project..
i just simply couldnt comply it..
it had some error like "undefined reference"...
and the problem exists even when i tried the build target option

Offline TDragon

  • Lives here!
  • ****
  • Posts: 936
    • Twilight Dragon Media
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #4 on: June 27, 2007, 04:21:50 pm »
It's clear you missed something. "Undefined reference" errors come from the linker and indicate that you've failed to include an important library or object file. Make sure the correct wxWidgets libraries are being used, and make sure the linker can find them (i.e. your "undefined reference" messages aren't proceeded by a "can't find -lwxmsw" message).
http://tdm-gcc.tdragon.net/ - TDM-GCC compiler suite for Windows (GCC 5.1.0 2015-06-28, 32/64-bit, no extra DLLs)

Offline Stevie

  • Single posting newcomer
  • *
  • Posts: 7
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #5 on: June 27, 2007, 04:35:46 pm »
I did check carefully on the linker and search directories setting..
i think.. i have all the important library included..
and it didnt come with the "lwmswu" problem.
it's simply an undefined reference on certains functions which should be alright and nothing wrong.

Offline Biplab

  • Developer
  • Lives here!
  • *****
  • Posts: 1874
    • Biplab's Blog
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #6 on: June 27, 2007, 04:47:29 pm »
it's simply an undefined reference on certains functions which should be alright and nothing wrong.

The error message extends beyond the words "Undefined reference". Please post the full error message. Or we have to post the solution as "Please check...".
Be a part of the solution, not a part of the problem.

Offline Stevie

  • Single posting newcomer
  • *
  • Posts: 7
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #7 on: June 27, 2007, 05:12:14 pm »
the error msg goes like this:

Quote
:: === TestOne, Debug ===
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_toplevel.o):: In function `ZN19wxTopLevelWindowMSW8SetShapeERK8wxRegion':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\toplevel.cpp:989: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\toplevel.cpp:991: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\toplevel.cpp:992: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\toplevel.cpp:1003: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_window.o):: In function `ZN8wxWindow6UpdateEv':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:1558: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_window.o):: In function `ZNK8wxWindow13GetTextExtentERK8wxStringPiS3_S3_S3_PK6wxFont':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:2042: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:2043: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_window.o):: In function `ZN8wxWindow20HandlePaletteChangedEPv':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:4201: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:4204: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:4207: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:4209: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_window.o):: In function `ZN8wxWindow21HandleQueryNewPaletteEv':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:4273: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:4276: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:4278: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:4280: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_window.o):: In function `ZN8wxWindow11HandlePaintEv':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:4396: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_window.o):: In function `Z13wxGetCharSizePvPiS0_RK6wxFont':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:5517: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:5519: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:5522: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_window.o):: In function `Z16wxGetTextMetricsPK8wxWindow':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:6420: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:6425: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:6431: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_window.o):: In function `ZN12wxMouseEventD1Ev':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\window.cpp:(.text$_ZN11SelectInHDCD1Ev[SelectInHDC::~SelectInHDC()]+0x21):: undefined reference to `[email protected]'
)]+0x1a):: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_app.o):: In function `ZN5wxApp10InitializeERiPPw':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\app.cpp:307: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_app.o):: In function `ZN8wxThread6OnExitEv':
C:\wxWidgets-2.8.4\build\msw\..\..\include\wx\thread.h:(.text$_Z15wxOleInitializev[wxOleInitialize()]+0xe):: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\include\wx\thread.h:(.text$_Z17wxOleUninitializev[wxOleUninitialize()]+0x7):: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_dcclient.o):: In function `ZN10wxWindowDC6InitDCEv':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dcclient.cpp:111: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_dcclient.o):: In function `ZN11wxPaintDCExC2EP8wxWindowPv':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dcclient.cpp:332: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_dcclient.o):: In function `ZN11wxPaintDCExC1EP8wxWindowPv':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dcclient.cpp:332: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_dcclient.o):: In function `ZN11wxPaintDCExD2Ev':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dcclient.cpp:345: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_dcclient.o):: In function `ZN11wxPaintDCExD1Ev':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dcclient.cpp:345: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_dcclient.o):: In function `ZN11wxPaintDCExD0Ev':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dcclient.cpp:345: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_gdiimage.o):: In function `Z14wxGetHiconSizeP7HICON__':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\gdiimage.cpp:591: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\gdiimage.cpp:594: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_gdiimage.o):: In function `ZN10wxGDIImageD0Ev':
)]+0x1b):: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\include\wx\msw\gdiimage.h:(.text$_ZN5wxDIB4FreeEv[wxDIB::Free()]+0x21):: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_dc.o):: In function `ZN15wxColourChangerC2ER4wxDC':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:256: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:257: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:264: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:270: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:273: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_dc.o):: In function `ZN15wxColourChangerC1ER4wxDC':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:256: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:257: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:264: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:270: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:273: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\lib\gcc_lib\libwxmsw28ud_core.a(corelib_dc.o):: In function `ZN15wxColourChangerD2Ev':
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:294: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:295: undefined reference to `[email protected]'
C:\wxWidgets-2.8.4\build\msw\..\..\src\msw\dc.cpp:296: undefined reference to `[email protected]'
:: More errors follow but not being shown.
:: Edit the max errors limit in compiler options...
:: === Build finished: 50 errors, 0 warnings ===

Offline rickg22

  • Lives here!
  • ****
  • Posts: 2283
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #8 on: June 27, 2007, 05:38:35 pm »
It seems that you're not linking the win32api libraries...

Offline Stevie

  • Single posting newcomer
  • *
  • Posts: 7
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #9 on: June 28, 2007, 03:32:19 am »
It seems that you're not linking the win32api libraries...

am i not?
i think i did..

Offline rickg22

  • Lives here!
  • ****
  • Posts: 2283
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #10 on: June 28, 2007, 04:31:43 am »
I'm not 100% sure, that's what I found by googling...

I think it's best if you create a new wxWidgets project and copy the routines from your main project in there.

Offline Stevie

  • Single posting newcomer
  • *
  • Posts: 7
Re: Turn Empty Project into a Wxwidgets Project?
« Reply #11 on: June 28, 2007, 05:08:54 am »
I'm not 100% sure, that's what I found by googling...

I think it's best if you create a new wxWidgets project and copy the routines from your main project in there.

Yea, i would better do that.. thanks for all the help from u guys. you people are cool =)