lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

On Feb 1, 2008, at 3:42 PM, Jelle Huisman wrote:

I'm new to Lua, so maybe I miss something totally obvious, but I would like to use the slnunicode library but I can't figure out how and where to install it. The .tar file I just downloaded doesn't include any documentation or makefile :-( How do I proceed? Any help would be appreciated. BTW, I'm on Mac OS X (10.4.11)

Try to compile it directly, e.g.:

% gcc -O2 -fno-common -c -o slnudata.o slnudata.c
% gcc -O2 -fno-common -c -o slnunico.o slnunico.c
% gcc -bundle -undefined dynamic_lookup -o slnudata.o slnunico.o

Here is a little Lua script that does that for you:

Attachment: lub.lua
Description: Binary data

It expects a 'lubfile' in the current directory:

Attachment: lubfile
Description: Binary data

If you define an alias to the lub.lua script, e.g.:

alias lub 'lua /Path/To/lub.lua'

You can invoke it as such:

% lub

(info) compile: 'gcc -O2 -fno-common -c -o slnudata.o slnudata.c'
(info) compile: 'gcc -O2 -fno-common -c -o slnunico.o slnunico.c'
(info) link: 'gcc -bundle -undefined dynamic_lookup -o slnudata.o slnunico.o'