On Wed, Apr 11, 2012 at 4:02 PM, klaas.holwerda <n...@klaasholwerda.nl> wrote:
> Hi,
>
> I am trying to compile wxLua and wxCode its stedit for wxWidgets2.9.3, on 
> Ubuntu 64 bit.
> stedit i finally managed.
> By forcing it to use (else could not be detected):
>     set(IS_32_BIT FALSE)
>     set(IS_64_BIT TRUE)

Why can it not be detected? In CMakewxAppLib.txt there is:

if ((CMAKE_SIZEOF_VOID_P MATCHES 4) OR (CMAKE_CL_64 MATCHES 0))
    set(IS_32_BIT TRUE)
    set(IS_64_BIT FALSE)
elseif((CMAKE_SIZEOF_VOID_P MATCHES 8) OR (CMAKE_CL_64 MATCHES 1))
    set(IS_32_BIT FALSE)
    set(IS_64_BIT TRUE)
else()
    MESSAGE(WARNING "Oops, unable to determine if using 32 or 64 bit
compilation.")
endif()

What are the values of these variables so I can fix it for systems like yours?

> And do:
>
>     if (IS_64_BIT)v
>         add_definitions( -fPIC )
>         #set(CMAKE_EXE_LINKER_FLAGS ${CMAKE_EXE_LINKER_FLAGS} -fPIC)
>     endif()
>
> If not i get an error that -fPIC file is not found.

I think this is right, but why do you get an error and I don't? I'm
guessing you have a newer compiler?
I use Fedora 13 : gcc version 4.4.5 20101112 (Red Hat 4.4.5-2) (GCC)

> Next comes wxLua.
> Setting:  export wxStEdit_ROOT_DIR=/home/klaas/soft/buildwxsteditdeb
> did not help, so it put it straight into cmake-gui, and it can generate the 
> make files using stedit.

Yes, this is the way to do it. Either that or run :
$cmake -DwxStEdit_ROOT_DIR=/home/klaas/soft/buildwxsteditdeb

> Now i got stuck here, and i am lost.
>
> [ 15%] Building C object modules/lua/CMakeFiles/LuaLibShared.dir/src/lapi.c.o
> cd /home/klaas/soft/buildwxluadeb29/modules/lua && /usr/bin/gcc  
> -DLUA_BUILD_AS_DLL
> -D_FILE_OFFSET_BITS=64 -D__WXGTK__ -DwxLUA_USEBINDING_WXGL=0 
> -DwxLUA_USEBINDING_WXSTC=1
> -DwxLUA_USEBINDING_WXXRC=1 -DwxLUA_USEBINDING_WXRICHTEXT=1 
> -DwxLUA_USEBINDING_WXHTML=1
> -DwxLUA_USEBINDING_WXMEDIA=1 -DwxLUA_USEBINDING_WXAUI=1 
> -DwxLUA_USEBINDING_WXADV=1
> -DwxLUA_USEBINDING_WXCORE=1 -DwxLUA_USEBINDING_WXXML=1 
> -DwxLUA_USEBINDING_WXNET=1
> -DwxLUA_USEBINDING_WXBASE=1 -DLUA_USE_LINUX -g -fPIC -isystem
> /usr/local/lib/wx/include/gtk2-unicode-static-2.9 -isystem 
> /usr/local/include/wx-2.9
> -I/home/klaas/soft/wxlua/trunk/wxLua/modules/wxbind/setup
> -I/home/klaas/soft/wxlua/trunk/wxLua/modules/..
> -I/home/klaas/soft/wxlua/trunk/wxLua/modules/../modules
> -I/home/klaas/soft/wxlua/trunk/wxLua/modules/../modules/lua/src    -Wall 
> -fPIC -o
> CMakeFiles/LuaLibShared.dir/src/lapi.c.o   -c 
> /home/klaas/soft/wxlua/trunk/wxLua/modules/lua/src/lapi.c
> In file included from 
> /home/klaas/soft/wxlua/trunk/wxLua/modules/lua/src/lapi.c:16:0:
> /home/klaas/soft/wxlua/trunk/wxLua/modules/lua/src/lua.h:110:1: warning: 
> return type defaults to
> 'int' [-Wreturn-type]
> /home/klaas/soft/wxlua/trunk/wxLua/modules/lua/src/lua.h: In function 
> '__declspec':
> /home/klaas/soft/wxlua/trunk/wxLua/modules/lua/src/lua.h:111:1: error: 
> expected declaration
> specifiers before '__declspec'
> etc. etc.

This is really strange, I think I found the problem though. I had set
the compiler define LUA_BUILD_AS_DLL by accident. This doesn't explain
why I didn't get any errors/warnings in Fedora though.

Please try again, hopefully this time it'll work better.

Regards,
    John

------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
wxlua-users mailing list
wxlua-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wxlua-users

Reply via email to