lua-users home
lua-l archive

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

On Jul 25, 2006, at 16:48, James Edward Gray II wrote:

I'm on Mac OS X and have compiled Lua 5.1.  I need to know:

1.  How do I compile bitlib so Lua will be able to load it?

Here is what I do:

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

More info under 'Building Modules: Mac OS X bundles':

2.  How to load that library once I have made it that far?

Copy the '' somewhere in 'package.cpath':


Feel free to adjust the 'cpath' to your likening:

package.cpath = package.cpath .. ";./Library/Modules/?.so"