User forums > Help
wxWidgets Application Crash 0xc0000005
mhamed:
Hi every body,
I'm a new to code block and i wanna use it to develope a GUI application using the wxwidgets library,
I'm using Ubuntu 9.4 running on VirtualBox (as Virtual machine )
* I installed the Wxwidgets successfully.
--- Code: ---# tar -xzvf wxwidgets-2.8.10.tar.gz
# cd wxwidgets-2.8.10
# mkdir build-x11
# cd build-x11
# ../configure --with-x11 --without-gtk --enable-no_rtti --enable-no_exceptions --disable-threads --disable-sockets --disable-joystick --disable-mdi --disable-printarch --disable-postscript --disable-resources --disable-prologio --with-zlib=builtin --with-libpng=builtin --with-libjpeg=builtin --with-libtiff=builtin
# make
#make install
#ldconfig
--- End code ---
* I installed the Code::Block successfully too.
--- Code: ---
#apt-get install codeblocks
--- End code ---
* I create a new Wxwidget projects. file -> new project -> wxwidgets project -> ...
* I compiled this project and every thing gonna good.
* Run the project in Linux and the project run successfullyAfter that i install the Arm-Linux cross compilation tool-chain to the linux as follow:
--- Code: ---# cd /opt/FriendlyArm/mini2440/source/
# tar -xzvf arm-linux-gcc-4.3.2.tgz
--- End code ---
after unpacking the ziped file it gives me usr directory
--- Code: ---export PATH=/opt/FriendlyArm/mini2440/source/usr/local/arm/4.3.2:$PATH
--- End code ---
After that i gone to the my code::block
Setting -> compiler and debugger -> choose the GNU ARM GCC compiler -> and under the toolchain executables change this configuration
* c compiler --> arm-linux-gcc
* c++ compiler --> arm-linux-g++
* Linker for dynamic library --> arm-linux-gcc
* Linker for static library --> arm-linux-ar
* Debugger --> arm-linux-qdb
* compiler installation directory --> /opt/FriendlyArm/mini2440/source/usr/local/arm/4.3.2
project -> properties -> build option
Choose release tap -> duplicated ->and choose ArmRelease as new name
Choose the compiler as GNU ARM GCC compiler
OK
and when i compiled ARMRelease it gives me this error
cannot find -lwx_gtk2u_richtext-2.8
I googled in the internet and find that i should add this lines to the configuration
'wx-config --cflags' to the compiler option and
'wx-config --libs' to the linker option
I successfully add this lines to the compiler and linker as follow:
project -> properties -> build-option ->choose ARMRelease -> compiler -> other option
project -> properties -> build-option ->choose ARMRelease -> linker -> other option
After that i got more errors :
this some of all because it is more that 2000 char and it got refused by the forumas follow:
--- Code: ---obj/ARMRelease/GUIFrame.o||In function `__static_initialization_and_destruction_0(int, int)':|
GUIFrame.cpp:(.text+0x48)||undefined reference to `std::ios_base::Init::Init()'|
GUIFrame.cpp:(.text+0x64)||undefined reference to `wxEventHashTable::wxEventHashTable(wxEventTable const&)'|
GUIFrame.cpp:(.text+0x174)||undefined reference to `std::ios_base::Init::~Init()'|
GUIFrame.cpp:(.text+0x180)||undefined reference to `wxEventHashTable::~wxEventHashTable()'|
GUIFrame.cpp:(.text+0x18c)||undefined reference to `wxEVT_CLOSE_WINDOW'|
GUIFrame.cpp:(.text+0x190)||undefined reference to `wxEVT_COMMAND_MENU_SELECTED'|
GUIFrame.cpp:(.text+0x194)||undefined reference to `wxEVT_NULL'|
obj/ARMRelease/GUIFrame.o||In function `GUIFrame::GUIFrame(wxWindow*, int, wxString, wxPoint, wxSize, int)':|
GUIFrame.cpp:(.text+0x1dc)||undefined reference to `wxStringBase::InitWith(wchar_t const*, unsigned int, unsigned int)'|
GUIFrame.cpp:(.text+0x1e4)||undefined reference to `wxFrameBase::wxFrameBase()'|
GUIFrame.cpp:(.text+0x1f4)||undefined reference to `wxFrame::Init()'|
GUIFrame.cpp:(.text+0x224)||undefined reference to `wxFrame::Create(wxWindow*, int, wxString const&, wxPoint const&, wxSize const&, long, wxString const&)'|
||=== Build finished: 534 errors, 0 warnings ===|
--- End code ---
Could any body help me please
I don't know what can i do.
MortenMacFly:
--- Quote from: mhamed on February 15, 2010, 02:00:40 pm ---# ../configure --with-x11 --without-gtk --enable-no_rtti --enable-no_exceptions --disable-threads --disable-sockets --disable-joystick
--- End quote ---
--- Quote from: mhamed on February 15, 2010, 02:00:40 pm ---cannot find -lwx_gtk2u_richtext-2.8
--- End quote ---
Guess why again...
stahta01:
--- Quote ---Linker for dynamic library --> arm-linux-gcc
--- End quote ---
Should that not be arm-linux-g++ ??
Tim S
mhamed:
Hi Tim,
Thanks for your reply
I changed the Linker for dynamic library to --> arm-linux-g++
and reinstall the wxwidgets with removing --without-gtk
and i still have the erreor
Question : if the library was missed how the code block compiled the program for (86 processor)using GNU GCC compiler and didn't compile for ARmGNU GCC compiler
Thanks for your help
M.Hamed
MortenMacFly:
--- Quote from: mhamed on February 16, 2010, 12:50:49 pm ---Question : if the library was missed how the code block compiled the program for (86 processor)using GNU GCC compiler and didn't compile for ARmGNU GCC compiler
--- End quote ---
What I don't get: You are developing an ARM application (that's why you are using an ARM compiler) but want to link against wxWidgets?! To my knowledge wxWidgets is not available at all for ARM platform, but even if I am wrog, you must compile/use the ARM version of wxWidgets first.
If you don't want to use wxWidgets on ARM (which I guess is what you want to do), don't setup a wxWidgets project, but start with a simple (ARM) console project.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version