Reputation: 11
I have added the cross compiler arm-linux-gnueabi into codelite and successfully cross-compiled a sample C program.
Now I'm trying to cross-compile a wxwidget sample program.
Initially it was throwing me errors in setup.h.
I created a link for /usr/lib/wx/include/gtk2-unicode-release-2.8/wx/setup.h with /usr/include/wx/setup.h. Now its giving me around 159 errors. I give you some of them for your reference.
/usr/include/wx/defs.h:42:13: error: #error "No Target! You should use wx-config program for compilation flags!"
In file included from /usr/include/wx/cursor.h:24:0,
from /usr/include/wx/event.h:22,
from /usr/include/wx/wx.h:25,
from main.cpp:14:
/usr/include/wx/gtk/cursor.h:40:5: error: ‘GdkCursor’ does not name a type
In file included from /usr/include/wx/app.h:570:0,
from /usr/include/wx/wx.h:26,
from main.cpp:14:
/usr/include/wx/gtk/app.h:55:5: error: ‘guint’ does not name a type
/usr/include/wx/gtk/app.h:65:5: error: ‘GdkVisual’ does not name a type
When I add wx-config --libs
wx-config --cxxflags
to my build command it gives me in compatible library errors..
These are the erros I'm stuck on with..
/usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_gtk2u_richtext-2.8 /usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_gtk2u_aui-2.8 /usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_gtk2u_xrc-2.8 /usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_gtk2u_qa-2.8 /usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_gtk2u_html-2.8 /usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_gtk2u_adv-2.8 /usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_gtk2u_core-2.8 /usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_baseu_xml-2.8 /usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_baseu_net-2.8 /usr/lib/gcc/arm-linux-gnueabi/4.6/../../../../arm-linux-gnueabi/bin/ld: cannot find -lwx_baseu-2.8 collect2: ld returned 1 exit status
I think I'm doing something wrong in linking libraries for cross compiler. Can anyone help me on this.. I would appreciate any help..
-Thanks in advance
Upvotes: 1
Views: 1702
Reputation: 22753
It looks like you didn't cross-compile wxWidgets itself. Or didn't install it if you did.
The thing to keep in mind is that you absolutely shouldn't need to manually create any links. In particular, the one you already made for wx/setup.h
will almost certainly break your other builds, don't do this. Just use the correct wx-config
for the cross-build.
Upvotes: 0