[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lua Digest, Vol 189, Issue 21
- From: Ted Unangst <ted.unangst@...>
- Date: Sat, 16 Jan 2010 18:56:59 -0500
On Sat, Jan 16, 2010 at 12:52 PM, James Hearon <j_hearon@hotmail.com> wrote:
> New to Lua. Still trying to understand why 'require' does not work very
> well.
> I cannot get Lua to find a lib unless I place the exe in the same folder
> next to the lib. The 'require' statement does not use paths it seems, and
> linking often does not work since some libs have no sonames and are not
> named according to standard practices. Some libs require symlinks to other
> libs etc.
This sounds like you're trying to require a library that's not a Lua
extension. That won't work.
> O.K. so I copied the random.so to /usr/lib/lua/5.1/ and this temp fix works;
> but the external libs I want to require are really more extensive than just
> random.so.
>
> What is a good solution to this problem? How do you go about requiring
> external libs which have dependencies to other libs etc.?
You need to link either your Lua extension or your main program
against any other required libraries.