Author Topic: 3.2.alpha1 anyone can compile it?  (Read 9109 times)

titi

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 4,240
    • View Profile
    • http://www.titusgames.de
3.2.alpha1 anyone can compile it?
« on: 30 May 2008, 22:41:58 »
Anyone knows what's  needed to compile this ( the current svn version ) ?
I cannot find "lua_script.h" I only have lua.h( but thats different! ) ....
What do I have to install? ( Ubuntu Dapper )

( I know I have to patch some things manually in the Jamfile too, because I think my autoconf-script is too old )
« Last Edit: 1 January 1970, 00:00:00 by titi »
Try Megaglest! Improved Engine / New factions / New tilesets / New maps / New scenarios

jrepan

  • Guest
(No subject)
« Reply #1 on: 31 May 2008, 16:47:50 »
I only have lua_script.h, and I don't have lua.hpp or lua.h. I have current svn(r154).
« Last Edit: 1 January 1970, 00:00:00 by jrepan »

titi

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 4,240
    • View Profile
    • http://www.titusgames.de
(No subject)
« Reply #2 on: 1 June 2008, 21:36:14 »
same problem here now...
It's probabaly not in the svn yet?
(lua.h is in your system when you have lua headers installed )
« Last Edit: 1 January 1970, 00:00:00 by titi »
Try Megaglest! Improved Engine / New factions / New tilesets / New maps / New scenarios

jrepan

  • Guest
(No subject)
« Reply #3 on: 2 June 2008, 14:47:51 »
I installed lua and now it finds all headers after modifing Jamfile.
But it still has compiling errors: ‘class Shared::Lua::LuaArguments’ has no member named ‘returnVec2i’ in glest_game/game/script_manager.cpp.
I guess Linux users have to wait.
« Last Edit: 1 January 1970, 00:00:00 by jrepan »

ttsmj

  • Guest
(No subject)
« Reply #4 on: 3 June 2008, 14:31:49 »
I too can't compile this new alpha

I had to add lua into Jamfile, in order to compiler find the lua_script.h

But now I am stuck:

Code: [Select]
In file included from shared_lib/sources/lua/lua_script.cpp:12:
shared_lib/sources/lua/lua_script.h:3:20: error: script.h: No such file or directory
shared_lib/sources/lua/lua_script.h:7:25: error: lua/src/lua.h: No such file or directory
shared_lib/sources/lua/lua_script.h:8:54: error: lua/src/lauxlib.h: No such file or directory


I think it needs few more files
« Last Edit: 1 January 1970, 00:00:00 by ttsmj »

martiño

  • Behemoth
  • *******
  • Posts: 1,095
    • View Profile
(No subject)
« Reply #5 on: 3 June 2008, 18:46:34 »
These are the standard Lua headers, you will have to download lua from lua.org, and compile it as well.
« Last Edit: 1 January 1970, 00:00:00 by martiño »

titi

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 4,240
    • View Profile
    • http://www.titusgames.de
(No subject)
« Reply #6 on: 3 June 2008, 22:13:03 »
Which version of lua do you use?
Before I had lua 5.0.
Now I compiled/installed 5.1.3 and now I get the following error (ubuntu 6.06):


Code: [Select]
C++ ./build/i686-pc-linux-gnu/optimize/glest_game/game/script_manager.o
glest_game/game/script_manager.cpp: In static member function »static int Glest::Game::ScriptManager::setCameraPosition(Shared::Lua::LuaHandle*)«:
glest_game/game/script_manager.cpp:271: Fehler: »class Shared::Lua::LuaArguments« hat kein Element namens »getVec2i«
glest_game/game/script_manager.cpp: In static member function »static int Glest::Game::ScriptManager::createUnit(Shared::Lua::LuaHandle*)«:
glest_game/game/script_manager.cpp:280: Fehler: »class Shared::Lua::LuaArguments« hat kein Element namens »getVec2i«
glest_game/game/script_manager.cpp: In static member function »static int Glest::Game::ScriptManager::givePositionCommand(Shared::Lua::LuaHandle*)«:
glest_game/game/script_manager.cpp:295: Fehler: »class Shared::Lua::LuaArguments« hat kein Element namens »getVec2i«
glest_game/game/script_manager.cpp: In static member function »static int Glest::Game::ScriptManager::getStartLocation(Shared::Lua::LuaHandle*)«:
glest_game/game/script_manager.cpp:337: Fehler: »class Shared::Lua::LuaArguments« hat kein Element namens »returnVec2i«
glest_game/game/script_manager.cpp: In static member function »static int Glest::Game::ScriptManager::getUnitPosition(Shared::Lua::LuaHandle*)«:
glest_game/game/script_manager.cpp:344: Fehler: »class Shared::Lua::LuaArguments« hat kein Element namens »returnVec2i«




EDIT: I forgot the translation:
"Fehler"---error
"hat kein Element namens"---"has no element named"
« Last Edit: 4 June 2008, 22:22:37 by titi »
Try Megaglest! Improved Engine / New factions / New tilesets / New maps / New scenarios

ttsmj

  • Guest
(No subject)
« Reply #7 on: 4 June 2008, 15:50:22 »
I have lua 5.1 now

But there are several versions
« Last Edit: 1 January 1970, 00:00:00 by ttsmj »

martiño

  • Behemoth
  • *******
  • Posts: 1,095
    • View Profile
(No subject)
« Reply #8 on: 4 June 2008, 19:04:26 »
hm... maybe the version on the server doesn't have the latest shared lib, i will upload it as soon as i can... probably next week...
« Last Edit: 1 January 1970, 00:00:00 by martiño »

titi

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 4,240
    • View Profile
    • http://www.titusgames.de
(No subject)
« Reply #9 on: 4 June 2008, 23:01:59 »
I downloaded them all (all lua versions) and searched for  "returnVec2i", but it's not defined in any of the them!?
What is this "returnVec2i"?
« Last Edit: 1 January 1970, 00:00:00 by titi »
Try Megaglest! Improved Engine / New factions / New tilesets / New maps / New scenarios

hailstone

  • GAE Team
  • Battle Machine
  • ********
  • Posts: 1,568
    • View Profile
(No subject)
« Reply #10 on: 7 June 2008, 08:06:18 »
a typo? might be return 'space' Vec2i
« Last Edit: 1 January 1970, 00:00:00 by hailstone »
Glest Advanced Engine - Admin/Programmer
https://sourceforge.net/projects/glestae/

martiño

  • Behemoth
  • *******
  • Posts: 1,095
    • View Profile
(No subject)
« Reply #11 on: 7 June 2008, 16:31:03 »
no, the function call is fine, it is a function to return a vector from C++ to a function called from LUA, the problem is that the function is in the shared lib, and the svn code is outdated, i will upload the code ASAP
« Last Edit: 1 January 1970, 00:00:00 by martiño »

martiño

  • Behemoth
  • *******
  • Posts: 1,095
    • View Profile
(No subject)
« Reply #12 on: 8 June 2008, 19:51:50 »
I've uploaded the updated shared lib, it should compile now. Could you guys take a look?
« Last Edit: 1 January 1970, 00:00:00 by martiño »

titi

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 4,240
    • View Profile
    • http://www.titusgames.de
(No subject)
« Reply #13 on: 9 June 2008, 07:31:15 »
I tried it yesterday but had no luck ( trouble with different lua versions in my system ;) ). But I only had linking problems ( due to the version trouble) no more compile problems! This evening I will try it again.
« Last Edit: 10 June 2008, 07:50:13 by titi »
Try Megaglest! Improved Engine / New factions / New tilesets / New maps / New scenarios

jrepan

  • Guest
(No subject)
« Reply #14 on: 9 June 2008, 09:58:21 »
I managed to compile, but I had to modify build files. Also I had to add C standard library includes to some files(patch), because newer gcc(4.3.0) gives errors when they are missing.
Tutorials are not working. I just have castle and no resources. I have Lua version 5.1.3
« Last Edit: 1 January 1970, 00:00:00 by jrepan »

jrepan

  • Guest
(No subject)
« Reply #15 on: 11 June 2008, 15:10:54 »
I got it working! I replaced tutorial directory with http://www.glest.org/files/misc/glest_p ... alpha1.zip
« Last Edit: 1 January 1970, 00:00:00 by jrepan »

titi

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 4,240
    • View Profile
    • http://www.titusgames.de
(No subject)
« Reply #16 on: 11 June 2008, 19:04:19 »
Did you use a shared lua lib or the static one ( which is the lua default )?

What I found http://lua-users.org/lists/lua-l/2006-10/msg00098.html

I don't know how to modify the jamfile to get it linked with a statically linked library.( liblua.a )

UPDATE: I got it working too!
I managed to compile ( linking was done manually!) ) it and it runs fine.
System: ubuntu 6.06 32 bit with lua 5.13(installed manually )

 I had a first look at the tutorial and I have to say:
Good job! The Tutorial is fantastic ( for beginners )
This lua scripting will be very useful!

As I said, the linking was made manually, so
I still don't know how to modify the jam files to get a proper compiling result.
Anyone can help here?
« Last Edit: 11 June 2008, 21:12:27 by titi »
Try Megaglest! Improved Engine / New factions / New tilesets / New maps / New scenarios

jrepan

  • Guest
(No subject)
« Reply #17 on: 11 June 2008, 20:48:27 »
I am using shared library. At least "ldd glest" says:
Code: [Select]
liblua.so => /usr/lib/liblua.so (0x00007f57fc384000)

EDIT: I made very ugly fix: I added -llua to SDL_LIBS in Jamconfig
« Last Edit: 1 January 1970, 00:00:00 by jrepan »

Yggdrasil

  • GAE Team
  • Ornithopter
  • ********
  • Posts: 408
    • View Profile
(No subject)
« Reply #18 on: 17 July 2008, 13:39:49 »
I tried to fix the build files. so here is the patchfile for rev173:
http://http://www1.inf.tu-dresden.de/~s1445051/rev173_jambuildfiles.patch

use it with the patch command in the trunk directory:
Code: [Select]
$ patch -p0 <rev173_jambuildfiles.patch

Another fix is included to make rev173 compilable (look at top of the patchfile).

Please try and maybe improve it because i'm totally new to jam.

EDIT: ok, tutorials doesn't work. it crashs always after clicking (the last) ok :/
« Last Edit: 1 January 1970, 00:00:00 by Yggdrasil »

 

anything