Author Topic: wxWidgets 2.8 problem  (Read 6029 times)

jack32

  • Guest
wxWidgets 2.8 problem
« on: October 03, 2007, 11:46:07 am »
im am trying to get Code::Blocks to work with wxWidgets 2.8.5

after reading several tutorials and trying many settings

i finally get this error:

Project   : wxWidgets application
Compiler  : GNU GCC Compiler (called directly)
Directory : D:\CodeBlocks\code\test3\
--------------------------------------------------------------------------------
Switching to target: default
Linking executable: D:\CodeBlocks\code\test3\wxWidgets.exe
.objs\main.o: In function `ZNK12wxWindowBase7IsShownEv':
C:/wxWidgets-2.8.5/include/wx/window.h:(.text$_ZN12wxStringBaseC2ERKS_[wxStringBase::wxStringBase(wxStringBase const&)]+0x47): undefined reference to `_imp___Z10wxOnAssertPKciS0_S0_S0_'
C:/wxWidgets-2.8.5/include/wx/window.h:(.rdata$_ZTV5MyApp[vtable for MyApp]+0x90): undefined reference to `wxAppConsole::OnAssertFailure(char const*, int, char const*, char const*, char const*)'
C:/wxWidgets-2.8.5/include/wx/window.h:(.rdata$_ZTV5MyApp[vtable for MyApp]+0x94): undefined reference to `wxAppConsole::OnAssert(char const*, int, char const*, char const*)'
collect2: ld returned 1 exit status
Process terminated with status 1 (0 minutes, 0 seconds)
0 errors, 0 warnings

i can start all over again and reinstall code blocks and compile wxWidgets again, if you name me a tutorial that works.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: wxWidgets 2.8 problem
« Reply #1 on: October 03, 2007, 12:28:13 pm »
What is your OS version? WinXP SP2?

Which drive is MinGW GCC installed on?

Which drive is Code::Blocks installed on?

I will try to update the Installation Direction for you, but will need feedback from you.

Working on Updating Instructions here
http://wiki.codeblocks.org/index.php?title=Compiling_wxWidgets_2.8.6_to_develop_Code::Blocks_%28MSW%29

Tim S
« Last Edit: October 03, 2007, 12:40:57 pm by stahta01 »
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

jack32

  • Guest
Re: wxWidgets 2.8 problem
« Reply #2 on: October 03, 2007, 12:43:53 pm »
Ok. sure. you need more input:

I have Win 2k3, but you can say i have Win XP SP2. :)

My wxWidgets are in D:\wxWidgets-2.8.5
My CodeBlocks is in D:\CodeBlocks

And some Settings:

Settungs > Compiler Settings > Directories > Compiler
d:\CodeBlocks\include
d:\wxWidgets-2.8.5\include
D:\wxWidgets-2.8.5\lib\gcc_dll

Settungs > Compiler Settings > Directories > Linker
d:\CodeBlocks\lib
d:\wxWidgets-2.8.5\lib\gcc_dll

Settungs > Compiler Settings > Directories > Custom Variables
VX_VER = d:\wxWidgets-2.8.5\include

I try to compile a new fresh Project:
File > New Project > wxWidgets Application > Create > [save]
Project > Properties > Projects Build Options > Linker > [Edit from wxmsw26 to wxmsw28]
Build > Build

And i get:
Project   : wxWidgets application
Compiler  : GNU GCC Compiler (called directly)
Directory : D:\CodeBlocks\code\test3\
--------------------------------------------------------------------------------
Switching to target: default
Linking executable: D:\CodeBlocks\code\test3\wxWidgets.exe
.objs\main.o: In function `ZNK12wxWindowBase7IsShownEv':
C:/wxWidgets-2.8.5/include/wx/window.h:(.text$_ZN12wxStringBaseC2ERKS_[wxStringBase::wxStringBase(wxStringBase const&)]+0x47): undefined reference to `_imp___Z10wxOnAssertPKciS0_S0_S0_'
C:/wxWidgets-2.8.5/include/wx/window.h:(.rdata$_ZTV5MyApp[vtable for MyApp]+0x90): undefined reference to `wxAppConsole::OnAssertFailure(char const*, int, char const*, char const*, char const*)'
C:/wxWidgets-2.8.5/include/wx/window.h:(.rdata$_ZTV5MyApp[vtable for MyApp]+0x94): undefined reference to `wxAppConsole::OnAssert(char const*, int, char const*, char const*)'
collect2: ld returned 1 exit status
Process terminated with status 1 (0 minutes, 0 seconds)
0 errors, 0 warnings

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: wxWidgets 2.8 problem
« Reply #3 on: October 03, 2007, 12:49:35 pm »
What compiler are you using?
What directory is the compiler in?
Normally it is C:\MinGW but it should in your case it should be on the D Drive.

Are you using a Code::Blocks nightly build? Or is it RC2 build?

Tim S
« Last Edit: October 03, 2007, 12:52:09 pm by stahta01 »
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

jack32

  • Guest
Re: wxWidgets 2.8 problem
« Reply #4 on: October 03, 2007, 12:54:32 pm »
I use the "Code::Blocks IDE, with MINGW compiler" from here http://www.codeblocks.org/downloads.shtml

Version: 1.0rc2

So the MINGW compiler is in the Code::Blocks Directory

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: wxWidgets 2.8 problem
« Reply #5 on: October 03, 2007, 12:55:57 pm »
Please download a Code::Blocks Nightly version into a fresh Code::Blocks folder.
Use a new folder or delete the contents of the old folder.

Nightly Build are on here
   http://forums.codeblocks.org/index.php/topic,7029.0.html

Or the project page here
   http://developer.berlios.de/project/showfiles.php?group_id=5358

Directions on Nightly Build here
http://forums.codeblocks.org/index.php/topic,3232.0.html

To Install a newer MinGW GCC I suggest
http://prdownloads.sourceforge.net/mingw/MinGW-5.1.3.exe
And pick "candidate" packages.

Time for Classes, so I am off to College.

Tim S
« Last Edit: October 03, 2007, 01:28:56 pm by stahta01 »
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

jack32

  • Guest
Re: wxWidgets 2.8 problem
« Reply #6 on: October 03, 2007, 01:44:34 pm »
ok now i have the nightly build....
with the 2 dlls
and i have installed mingw to D:\MinGW

and now i get
---------------------------
Warning
---------------------------
A matching Debug configuration cannot be found in the wxWidgets directory you specified.
This means that Debug target of your project will not build.

Are you sure you want to continue with these settings?
---------------------------
Ja   Nein  
---------------------------


and

---------------------------
Warning
---------------------------
A matching Release configuration cannot be found in the wxWidgets directory you specified.
This means that Release target of your project will not build.

Are you sure you want to continue with these settings?
---------------------------
Ja   Nein  
---------------------------


but i seems to me that all directorys are set correct.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: wxWidgets 2.8 problem
« Reply #7 on: October 03, 2007, 01:46:58 pm »
Did you compile wxWidgets?

If you don't wish to compile wxWidgets and have a fast internet connection I suggest wxPack, it contains compiled wxWidgets libraries.

http://wxpack.sourceforge.net/Main/Downloads

Tim S
« Last Edit: October 03, 2007, 01:50:38 pm by stahta01 »
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

jack32

  • Guest
Re: wxWidgets 2.8 problem
« Reply #8 on: October 03, 2007, 02:21:23 pm »
yes, wxWidgets were compiled.

Now I have deleted them and recompiled them

using:
mingw32-make.exe -f makefile.gcc clean
mingw32-make.exe -f makefile.gcc USE_XRC=1 SHARED=1 MONOLITHIC=1 BUILD=release UNICODE=0

same error.....

now i will try wxPack


Offline TDragon

  • Lives here!
  • ****
  • Posts: 943
    • TDM-GCC
Re: wxWidgets 2.8 problem
« Reply #9 on: October 03, 2007, 02:34:08 pm »
Rather than trying to use (or update) those dated instructions, just follow the wxWindowsQuickRef.
https://jmeubank.github.io/tdm-gcc/ - TDM-GCC compiler suite for Windows (GCC 9.2.0 2020-03-08, 32/64-bit, no extra DLLs)

jack32

  • Guest
Re: wxWidgets 2.8 problem
« Reply #10 on: October 03, 2007, 03:27:50 pm »
now its working with wxPack

i don't know why it wont work with the self build ones