Building Luabind

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Building Luabind

Diego Benavides

Hello,

 

I’m new to Luabind and am having some difficulties building the project. For reference I’m using Windows 7 64bit with MinGW and the Eclipse CDT IDE (Helios). I tried building Luabind with bjam but couldn’t get it to work (and I’m not sure I understand the mechanics). I instead created a new project within Eclipse, added the source files, included the boost and Lua libraries, and I feel fairly close to getting it going. However I receive the following build errors:

 

..\src\class_registry.cpp: In constructor 'luabind::detail::class_registry::class_registry(lua_State*)':

..\src\class_registry.cpp:112:61: error: call of overloaded 'create_cpp_class_metatable(lua_State*&)' is ambiguous

C:\Development\luabind-0.9.1/luabind/open.hpp:34:19: note: candidates are: int luabind::detail::create_cpp_class_metatable(lua_State*)

..\src\class_registry.cpp:38:13: note:                 int luabind::detail::<unnamed>::create_cpp_class_metatable(lua_State*)

..\src\class_registry.cpp:113:61: error: call of overloaded 'create_lua_class_metatable(lua_State*&)' is ambiguous

C:\Development\luabind-0.9.1/luabind/open.hpp:36:19: note: candidates are: int luabind::detail::create_lua_class_metatable(lua_State*)

..\src\class_registry.cpp:74:13: note:                 int luabind::detail::<unnamed>::create_lua_class_metatable(lua_State*)

 

I have tried adding the namespace luabind::detail specifically to the two methods above, however if I do this I am then presented with a slew of “undefined reference” errors across the entire project. I’m not sure how to proceed. Would anyone have insight or suggestions? My boost version is 1.46.1, Lua 5.1 and Luabind is 0.9.1.

 

Regards,

Diego


------------------------------------------------------------------------------
Xperia(TM) PLAY
It's a major breakthrough. An authentic gaming
smartphone on the nation's most reliable network.
And it wants your games.
http://p.sf.net/sfu/verizon-sfdev
_______________________________________________
luabind-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/luabind-user
Reply | Threaded
Open this post in threaded view
|

Re: Building Luabind

Ryan Pavlik-4
You could try my fork that adds a CMake-based build system: I've used it successfully on windows, but haven't tried it with MinGW.

Ryan

On Tue, Apr 5, 2011 at 8:34 AM, Diego Benavides <[hidden email]> wrote:

Hello,

 

I’m new to Luabind and am having some difficulties building the project. For reference I’m using Windows 7 64bit with MinGW and the Eclipse CDT IDE (Helios). I tried building Luabind with bjam but couldn’t get it to work (and I’m not sure I understand the mechanics). I instead created a new project within Eclipse, added the source files, included the boost and Lua libraries, and I feel fairly close to getting it going. However I receive the following build errors:

 

..\src\class_registry.cpp: In constructor 'luabind::detail::class_registry::class_registry(lua_State*)':

..\src\class_registry.cpp:112:61: error: call of overloaded 'create_cpp_class_metatable(lua_State*&)' is ambiguous

C:\Development\luabind-0.9.1/luabind/open.hpp:34:19: note: candidates are: int luabind::detail::create_cpp_class_metatable(lua_State*)

..\src\class_registry.cpp:38:13: note:                 int luabind::detail::<unnamed>::create_cpp_class_metatable(lua_State*)

..\src\class_registry.cpp:113:61: error: call of overloaded 'create_lua_class_metatable(lua_State*&)' is ambiguous

C:\Development\luabind-0.9.1/luabind/open.hpp:36:19: note: candidates are: int luabind::detail::create_lua_class_metatable(lua_State*)

..\src\class_registry.cpp:74:13: note:                 int luabind::detail::<unnamed>::create_lua_class_metatable(lua_State*)

 

I have tried adding the namespace luabind::detail specifically to the two methods above, however if I do this I am then presented with a slew of “undefined reference” errors across the entire project. I’m not sure how to proceed. Would anyone have insight or suggestions? My boost version is 1.46.1, Lua 5.1 and Luabind is 0.9.1.

 

Regards,

Diego


------------------------------------------------------------------------------
Xperia(TM) PLAY
It's a major breakthrough. An authentic gaming
smartphone on the nation's most reliable network.
And it wants your games.
http://p.sf.net/sfu/verizon-sfdev
_______________________________________________
luabind-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/luabind-user




--
Ryan Pavlik
HCI Graduate Student
Virtual Reality Applications Center
Iowa State University

[hidden email]
http://academic.cleardefinition.com
Internal VRAC/HCI Site: http://tinyurl.com/rpavlik

------------------------------------------------------------------------------
Xperia(TM) PLAY
It's a major breakthrough. An authentic gaming
smartphone on the nation's most reliable network.
And it wants your games.
http://p.sf.net/sfu/verizon-sfdev
_______________________________________________
luabind-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/luabind-user
Reply | Threaded
Open this post in threaded view
|

Re: Building Luabind

David Wolfe
On 4/5/2011 9:53 AM, Ryan Pavlik wrote:
> You could try my fork that adds a CMake-based build system: I've used it
> successfully on windows, but haven't tried it with MinGW.
> https://github.com/rpavlik/luabind

Nice! I've been looking for something like this. For the OP, in case
you're not familiar with CMake, it would work something like this:

C:\Users\Joe>mkdir build && cd build
C:\Users\Joe\build>cmake -DCMAKE_PREFIX_PATH=C:/Users/JohnDoe/opt \
    -G"Eclipse CDT4 - MinGW Makefiles" <path_to_luabind_cmakelists.txt>

This will create Eclipse project files that you should be able to import
into Eclipse using File->Import->Existing Projects Into Workspace.  This
is *way* better than trying to configure all of this by hand!

The -DCMAKE_PREFIX_PATH bit is hint to CMake about where it should look
for external libs/headers.  It will often be able to locate this stuff
on its own under Unix, but not so much on Windows.  The layout of the
hypothetical 'opt' folder in the above invocation might look like
this:

   opt/
     |
      - bin/
     |
      - lib/
     |
      - include/

Haven't tried this with MinGW, but would be very interested to hear if
it works for you!

------------------------------------------------------------------------------
Xperia(TM) PLAY
It's a major breakthrough. An authentic gaming
smartphone on the nation's most reliable network.
And it wants your games.
http://p.sf.net/sfu/verizon-sfdev
_______________________________________________
luabind-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/luabind-user