From: Francesco M. <f18...@ya...> - 2006-01-20 13:19:00
|
Hi, John Labenski ha scritto: >>The library order is: >> >> -lwxluasocket -lwxluadebug -lwxbind -lwxlua -llua >> >>and they come before wx libraries as it should be so I really do not >>understand it. > > > I don't either? They're defined in libwxbind, no compilation errors there? > > These are the order they're linked in apps/wxlua/src/Makefile and it > works there. > -l$(WXLUABIND_LIB) -l$(WXLUA_LIB) -l$(WXLUADEBUG_LIB) > -l$(WXLUASOCKET_LIB) $(LUA_LIBS) I tried to change the library order to match this one but it still doesn't work (same errors). I then tried to use the hand-made Makefile but I get: frm@genius:~/work/wxLua/apps/wxlua/src$ sudo make make[1]: Entering directory `/home/frm/work/wxLua/modules/lua' cd include; make all make[2]: Entering directory `/home/frm/work/wxLua/modules/lua/include' make[2]: Nothing to be done for `all'. make[2]: Leaving directory `/home/frm/work/wxLua/modules/lua/include' cd src; make all make[2]: Entering directory `/home/frm/work/wxLua/modules/lua/src' make[2]: Nothing to be done for `all'. make[2]: Leaving directory `/home/frm/work/wxLua/modules/lua/src' cd src/lib; make all make[2]: Entering directory `/home/frm/work/wxLua/modules/lua/src/lib' make[2]: Nothing to be done for `all'. make[2]: Leaving directory `/home/frm/work/wxLua/modules/lua/src/lib' cd src/luac; make all make[2]: Entering directory `/home/frm/work/wxLua/modules/lua/src/luac' make[2]: Nothing to be done for `all'. make[2]: Leaving directory `/home/frm/work/wxLua/modules/lua/src/luac' cd src/lua; make all make[2]: Entering directory `/home/frm/work/wxLua/modules/lua/src/lua' make[2]: Nothing to be done for `all'. make[2]: Leaving directory `/home/frm/work/wxLua/modules/lua/src/lua' make[1]: Leaving directory `/home/frm/work/wxLua/modules/lua' make[1]: Entering directory `/home/frm/work/wxLua/modules/wxlua/src' g++ -shared -o /usr/local/lib/libwx_gtk2ud_wxlua-2.7.so.1.5.0 internal.o wxlbind.o wxlcallb.o wxlintrp.o wxlstate.o /usr/bin/ld: internal.o: relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object; recompile with -fPIC internal.o: could not read symbols: Bad value collect2: ld returned 1 exit status make[1]: *** [/usr/local/lib/libwx_gtk2ud_wxlua-2.7.so.1.5.0] Error 1 make[1]: Leaving directory `/home/frm/work/wxLua/modules/wxlua/src' make: *** [wxLuaLib] Error 2 frm@genius:~/work/wxLua/apps/wxlua/src$ And this did not work with both a static and a shared build of wxWidgets. Last, I searched for the unresolved linker symbols: i.e. s_wxluatag_wxWindow, s_wxluatag_wxBitmap, s_wxluatag_wxEvtHandler, s_wxluatag_wxEvent and I found that they are all declared as extern symbols at the beginning of some CPP files (like wxlstate.cpp) but then they are not defined anywhere. How did you manage to compile these sources ? Do I have to run some bind generator ? Or you have some un-committed sources in your local copy ? Francesco |