Linux user having trouble compiling

Linux user having trouble compiling

Postby Daphron » 28 Dec 2012, 22:06

So I've downloaded the repo but upon make I get this: http://pastebin.com/120aBr1p
(After commit 2472c98722)

Anyone have any suggestions on how to fix this? (If it's a work in progress type thing then could someone tell me the commit with the same code as the windows release?)
Daphron
 
Posts: 5
Joined: 10 Dec 2012, 21:31

Re: Linux user having trouble compiling

Postby qubodup » 29 Dec 2012, 16:39

User avatar
qubodup
Global Moderator
 
Posts: 1671
Joined: 08 Nov 2009, 22:52
Location: Berlin, Germany

Re: Linux user having trouble compiling

Postby Roots » 29 Dec 2012, 18:41

What version of Lua do you have installed on your system? I believe that a new Lua version came out recently that isn't compatible with the latest Luabind version. Unfortunately, it seems that development of Luabind has been stalled (it's a somewhat troublesome library, which is why we include it's source and compile it in directly).
Image
Roots
 
Posts: 96
Joined: 04 Mar 2010, 21:54

Re: Linux user having trouble compiling

Postby Daphron » 29 Dec 2012, 19:55

Lua version 5.2.1 (the latest).
Daphron
 
Posts: 5
Joined: 10 Dec 2012, 21:31

Re: Linux user having trouble compiling

Postby Roots » 29 Dec 2012, 20:49

Well I did some searching and found this: http://lua.2524044.n2.nabble.com/Luabin ... 82662.html

Here's the information I learned:
- Lua 5.2.1 is a very recent release
- The latest official release of Luabind (what is contained with the VT repository) will not work with Lua 5.2.1
- The original developers of Luabind are AWOL
- Several people have forked the project and continued development on it, including some with 5.2.1 compatibility
- However, there is no official 5.2.1 supported release

We might have to just pull some unofficial code from one of these repositories in the Luabind github network: https://github.com/luabind/luabind/network , and put it in our own repository and hope it works. Supporting 5.2.1 right now seems a bit risky when there is no official, tested release...
Image
Roots
 
Posts: 96
Joined: 04 Mar 2010, 21:54

Re: Linux user having trouble compiling

Postby IkarusDowned » 30 Dec 2012, 01:59

I think you're better off sticking with an older version of LUA that VT is stable with. otherwise we risk playing cat and mouse with releases and it can get realy messy.
IkarusDowned
 
Posts: 37
Joined: 12 Nov 2012, 06:01

Re: Linux user having trouble compiling

Postby Bertram » 30 Dec 2012, 02:20

Hi,

While using a newer not stable-considered lib, whatever it is, is unadvised, I do think the precise error seen here could be rather easily be fixed. And I'll fix it as soon as I've got the time to live test the compilation of VT on ArchLinux.

Regards,
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby Daphron » 31 Dec 2012, 22:49

Ok, just going to confirm that it is the new lua version. Using lua 5.1 works fine, thanks for the help.
Daphron
 
Posts: 5
Joined: 10 Dec 2012, 21:31

Re: Linux user having trouble compiling

Postby qubodup » 01 Jan 2013, 05:36

An alternative would be to set lua to <5.2 in the cmake files.
User avatar
qubodup
Global Moderator
 
Posts: 1671
Joined: 08 Nov 2009, 22:52
Location: Berlin, Germany

Re: Linux user having trouble compiling

Postby Bertram » 01 Jan 2013, 20:43

qubodup {l Wrote}:An alternative would be to set lua to <5.2 in the cmake files.


Why not, but only as a temporary solution, since it wouldn't help you, right?
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby Bertram » 01 Jan 2013, 21:17

Re,

I will work toward being able to compile against the system lubaind for linux systems. I hope it will do the trick for you both.

Regards,
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby qubodup » 01 Jan 2013, 22:45

That's very kind.

Sometimes, I have the feeling that reporting bugs as an arch linux user makes developers waste time, trying to fix them. On the other hand, they might have to do it later anyway, when Debian etc. catch up. in this case, for example, somebody at debian would have probably would have found or made a replacement for the official luabind package, which would have saved some time for you.

Then again, reading this post might take more time than you will ever really uselessly waste on supporting arch linux... :)

A find of a ported luabind: http://lua.2524044.n2.nabble.com/Luabin ... 82662.html
User avatar
qubodup
Global Moderator
 
Posts: 1671
Joined: 08 Nov 2009, 22:52
Location: Berlin, Germany

Re: Linux user having trouble compiling

Postby Bertram » 02 Jan 2013, 15:22

Hi qubodup,

As told in github's issue #93: https://github.com/Bertram25/ValyriaTea ... t-11788182

Added the option: USE_SYSTEM_LUABIND in commit:
03c5337

Please test using:

cmake -DUSE_SYSTEM_LUABIND=on .

If it's working, I add that into the HEI-Release branch.

Regards,
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby qubodup » 02 Jan 2013, 21:37

On Arch Linux, there is no luabind package in the official repositories and the on in the user repository is flagged out of date. I built and installed it, building VT then throws the same error as mentioned above.

There is an official lua51 package in Arch Linux and I have it installed. There might be a way to request a list of all lua versions and demand that 5.1 is used...
User avatar
qubodup
Global Moderator
 
Posts: 1671
Joined: 08 Nov 2009, 22:52
Location: Berlin, Germany

Re: Linux user having trouble compiling

Postby Bertram » 02 Jan 2013, 23:08

It must be yes. I need to have a look at it. When installing lua 5.1, does it work for you?
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby qubodup » 03 Jan 2013, 04:16

I have both lua (5.2) and lua51 installed, it does not work.

Location of installed files: http://codepad.org/96yEifEl
User avatar
qubodup
Global Moderator
 
Posts: 1671
Joined: 08 Nov 2009, 22:52
Location: Berlin, Germany

Re: Linux user having trouble compiling

Postby Bertram » 03 Jan 2013, 08:56

Arg, then I definitely need to adapt the static luabind source for deprecated lua calls.

I'll have a look at the port.
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby qubodup » 03 Jan 2013, 21:42

softcoder, a cmake expert who did much work for MegaGlest, helped me out on irc.freenode.net#freegamer.

softcoder runs Ubuntu, which has also lua5.1 and lua5.2 installed. There, `cmake .` works just like that with current VT git.

On my box, the following command allowed me to build VT, while having lua5.2 and lua5.1 installed:

{l Code}: {l Select All Code}
cmake -DLUA_LIBRARIES=/usr/lib/liblua5.1.so -DLUA_INCLUDE_DIR=/usr/include/lua5.1/ .


Thanks softcoder!
User avatar
qubodup
Global Moderator
 
Posts: 1671
Joined: 08 Nov 2009, 22:52
Location: Berlin, Germany

Re: Linux user having trouble compiling

Postby Bertram » 04 Jan 2013, 01:39

Awesome. Thanks to him for taking the time to help :)

I hope you'll enjoy the end of this demo.

I'll still have a go at fixing the error people could have with luabind on lua 5.2 iteratively, for now at least.

Best regards,
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby Bertram » 04 Jan 2013, 02:20

I've pushed this:

https://github.com/Bertram25/ValyriaTea ... 7b096a86ff

Can you try and tell whether the error is evolving when compiling against lua 5.2?
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby qubodup » 04 Jan 2013, 02:41

Processing...
{l Code}: {l Select All Code}
git pull
rm CMakeCache.txt
make clean
cmake .
make -j 1 &> no.txt
curlpaste no.txt

http://codepad.org/09is9USu

Maybe the problem is that lua5.1 and 5.2 are being used at the same time... somehow? (uneducated guess).

EDIT: I always used master. I'm sorry, I am not too good with git. Was I supposed to switch to another branch?
User avatar
qubodup
Global Moderator
 
Posts: 1671
Joined: 08 Nov 2009, 22:52
Location: Berlin, Germany

Re: Linux user having trouble compiling

Postby Bertram » 04 Jan 2013, 03:21

Hmm, to me, it's the next logical error, eh.
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby Bertram » 04 Jan 2013, 11:58

Ahh!!!
How could I have missed that one:
Peter's commit were pushed in the 0.9 branch of luabind, adapting it for both lua 5.1 and 5.2:
https://github.com/luabind/luabind/commits/0.9

I'll import all that soon. :)

qubodup {l Wrote}:EDIT: I always used master. I'm sorry, I am not too good with git. Was I supposed to switch to another branch?

Np, use the master one.

Btw, you might want to make the arch linux maintainers aware of the 0.9 branch adaptation to lua 5.2.

regards,
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby Bertram » 05 Jan 2013, 20:18

Hi,

I pushed all the adaptations used to port luabind to lua 5.2:
https://github.com/Bertram25/ValyriaTea ... 0d5c1dd7ec

Could you try it out?
User avatar
Bertram
VT Moderator
 
Posts: 1652
Joined: 09 Nov 2012, 12:26

Re: Linux user having trouble compiling

Postby qubodup » 07 Jan 2013, 18:04

Thank you,

{l Code}: {l Select All Code}
[  0%] Building CXX object src/CMakeFiles/valyriatear.dir/modes/boot/boot.cpp.o
In file included from /home/qubodup/src/git/ValyriaTear/src/modes/boot/boot.cpp:19:0:
/home/qubodup/src/git/ValyriaTear/src/engine/script/script_modify.h: In member function ‘void hoa_script::ModifyScriptDescriptor::_ModifyData(const string&, T)’:
/home/qubodup/src/git/ValyriaTear/src/engine/script/script_modify.h:243:66: error: ‘LUA_GLOBALSINDEX’ was not declared in this scope
/home/qubodup/src/git/ValyriaTear/src/engine/script/script_modify.h: In member function ‘void hoa_script::ModifyScriptDescriptor::_AddNewData(const string&, T)’:
/home/qubodup/src/git/ValyriaTear/src/engine/script/script_modify.h:321:66: error: ‘LUA_GLOBALSINDEX’ was not declared in this scope
In file included from /home/qubodup/src/git/ValyriaTear/src/common/global/global.h:37:0,
                 from /home/qubodup/src/git/ValyriaTear/src/modes/menu/menu_views.h:25,
                 from /home/qubodup/src/git/ValyriaTear/src/modes/boot/boot.h:26,
                 from /home/qubodup/src/git/ValyriaTear/src/modes/boot/boot.cpp:16:
/home/qubodup/src/git/ValyriaTear/src/modes/map/map_utils.h: At global scope:
/home/qubodup/src/git/ValyriaTear/src/modes/map/map_utils.h:50:14: warning: ‘hoa_map::private_map::HALF_TILES_ON_X_AXIS’ defined but not used [-Wunused-variable]
/home/qubodup/src/git/ValyriaTear/src/modes/map/map_utils.h:51:14: warning: ‘hoa_map::private_map::HALF_TILES_ON_Y_AXIS’ defined but not used [-Wunused-variable]
make[2]: *** [src/CMakeFiles/valyriatear.dir/modes/boot/boot.cpp.o] Error 1
make[1]: *** [src/CMakeFiles/valyriatear.dir/all] Error 2
make: *** [all] Error 2
User avatar
qubodup
Global Moderator
 
Posts: 1671
Joined: 08 Nov 2009, 22:52
Location: Berlin, Germany

Who is online

Users browsing this forum: No registered users and 1 guest