diff options
author | jluehrs2 <jluehrs2@uiuc.edu> | 2008-03-18 22:57:56 -0500 |
---|---|---|
committer | jluehrs2 <jluehrs2@uiuc.edu> | 2008-03-18 22:57:56 -0500 |
commit | 87fe5c137edcfd147bd8b608e2980de1298de1e2 (patch) | |
tree | 542a596bcb861e75751c57ce4a4c49b1c6962475 | |
parent | ea1ae62272d361f3afd714c90b0c5df09b6176b8 (diff) | |
download | luancurses-87fe5c137edcfd147bd8b608e2980de1298de1e2.tar.gz luancurses-87fe5c137edcfd147bd8b608e2980de1298de1e2.zip |
portability - handle distros that have weird names for the lua libraries and include paths
-rw-r--r-- | Make.config | 8 | ||||
-rw-r--r-- | Makefile | 8 |
2 files changed, 11 insertions, 5 deletions
diff --git a/Make.config b/Make.config index 51855da..1ae1404 100644 --- a/Make.config +++ b/Make.config @@ -1,5 +1,11 @@ # Path to your Lua C library directory (LUA_CPATH) -LUA_C_DIR = /usr/local/lib/lua/5.1 +LUA_DIR = /usr/local/lib/lua/5.1 + +# Some distros require, for example, lua5.1 here +LUA_LIBNAME = lua + +# Some distros put Lua include files in /usr/include/lua5.1, for example +LUA_INCLUDEPATH = /usr/include OS = linux #OS = osx @@ -4,9 +4,9 @@ include Make.$(OS) BIN = src/curses.so OBJ = src/curses.o src/strings.o CC = gcc -INCLUDES = +INCLUDES = -I$(LUA_INCLUDEPATH) DEFINES = -LIBS = -lcurses -llua +LIBS = -lcurses -l$(LUA_LIBNAME) COMMONFLAGS = -Werror -Wall -pedantic -O0 -g -pipe $(OS_FLAGS) CFLAGS = -c $(INCLUDES) $(DEFINES) $(COMMONFLAGS) LDFLAGS = $(LIBS) $(COMMONFLAGS) -shared @@ -41,8 +41,8 @@ dep : rm -f Makefile.bak install : - mkdir -p $(LUA_C_DIR) - cp $(BIN) $(LUA_C_DIR) + mkdir -p $(LUA_DIR) + cp $(BIN) $(LUA_DIR) dist : $(VERSION).tar.gz |