[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: I'm having trouble with libraries
- From: Mukhsein Johari <mukhsein@...>
- Date: Thu, 31 Mar 2005 01:00:51 +0800
This is my first post. Sorry if it's too long. Please bear with me, though.
I've recently been learning lua. I've read the lua book almost cover
to cover (skipped the c api). So I'm not a total newbie. My problem
starts as soon as I try to do anything non-trivial. Like xavante,
right now. It seems require() fails a lot and it's not always easy to
find out why.
I have to go through the source to make some changes. (I have
installed compat-5.1, btw.)
There must be a better way for third party libs to install everything
in its proper place.
I come from python, in case you're curious and I really miss "python
setup.py install" way of installing extra python libs. All imports
just work after a successful install. Will lua (5.1?) have something
like python's distutils?
I'm sorry if I seem incoherent. I've been trying to get xavante to
work since late morning and it's past midnight now. I've only
partially succeeded. I found I had to make a lot of edits in the lib
sources - I'm sure I'm not supposed to do that but the requires fail,
otherwise. eg. I had to change the requires("socket.url") to
requires("url") in a couple of places. And I had to change
module("socket.url") in url.lua to module("url"). Stuff like this
makes me nervous.
Right now, I'm stuck at:
mukhsein:~/xavante-1.1b/bin$ lua ./xavante_start.lua
coxpcall loaded: table: 0x8080498 -- just prints to see the
symbols are loaded
url loaded: table: 0x807d300
pcall = function: 0x806e558
lua: /usr/local/share/lua/5.0/copas.lua:155: coxpcall.lua:25:
coxpcall.lua:25: coxpcall.lua:39: attempt to call a nil value
[C]: in function `error'
/usr/local/share/lua/5.0/copas.lua:155: in function `def_tick'
/usr/local/share/lua/5.0/copas.lua:214: in function `tick'
/usr/local/share/lua/5.0/copas.lua:257: in function `loop'
xavante/server.lua:69: in function `start'
./xavante_start.lua:35: in main chunk
Now I'm stumped. What do I do now?