updated makefile for vc2008

This commit is contained in:
mascarenhas
2008-01-23 02:48:47 +00:00
parent d219de7885
commit 804e976407
3 changed files with 39 additions and 19 deletions

View File

@@ -1,4 +1,4 @@
# $Id: Makefile,v 1.30 2007/06/07 01:28:08 tomas Exp $
# $Id: Makefile,v 1.31 2008/01/23 02:48:47 mascarenhas Exp $
T= lfs
V= 1.3.0
@@ -9,15 +9,14 @@ include $(CONFIG)
SRCS= src/$T.c
OBJS= src/$T.o
lib: src/$(LIBNAME)
lib: src/lfs.so
src/$(LIBNAME): $(OBJS)
export MACOSX_DEPLOYMENT_TARGET="10.3"; $(CC) $(CFLAGS) $(LIB_OPTION) -o src/$(LIBNAME) $(OBJS)
src/lfs.so: $(OBJS)
export MACOSX_DEPLOYMENT_TARGET="10.3"; $(CC) $(CFLAGS) $(LIB_OPTION) -o src/lfs.so $(OBJS)
install: src/$(LIBNAME)
install: src/lfs.so
mkdir -p $(LUA_LIBDIR)
cp src/$(LIBNAME) $(LUA_LIBDIR)
cd $(LUA_LIBDIR); ln -f -s $(LIBNAME) $T.so
cp src/lfs.so $(LUA_LIBDIR)
clean:
rm -f src/$(LIBNAME) $(OBJS)
rm -f src/lfs.so $(OBJS)

View File

@@ -1,4 +1,4 @@
# $Id: Makefile.win,v 1.6 2008/01/23 01:58:25 mascarenhas Exp $
# $Id: Makefile.win,v 1.7 2008/01/23 02:48:47 mascarenhas Exp $
T= lfs
V= 1.3.0
@@ -8,17 +8,18 @@ include config.win
SRCS= src\$T.c
OBJS= src\$T.obj
lib: src\$(LIBNAME)
lib: src\lfs.dll
.c.obj:
$(CC) /c /Fo$@ $(CFLAGS) $<
src\$(LIBNAME): $(OBJS)
link /manifest:no /dll /def:src\$T.def /out:src\$(LIBNAME) $(OBJS) $(LUA_LIB)
src\lfs.dll: $(OBJS)
link /dll /def:src\$T.def /out:src\lfs.dll $(OBJS) $(LUA_LIB)
mt -manifest src\lfs.dll.manifest -outputresource:src\lfs.dll;2
install: src\$(LIBNAME)
install: src\lfs.dll
IF NOT EXIST $(LUA_LIBDIR) mkdir $(LUA_LIBDIR)
copy src\$(LIBNAME) $(LUA_LIBDIR)
copy src\lfs.dll $(LUA_LIBDIR)
clean:
del src\$(LIBNAME) $(OBJS) src\$T.lib src\$T.exp
del src\lfs.dll $(OBJS) src\$T.lib src\$T.exp

View File

@@ -17,8 +17,28 @@ dependencies = {
"lua >= 5.1"
}
build = {
type = "module",
modules = {
lfs = "src/lfs.c"
}
platforms = {
unix = {
type = "make",
build_variables = {
LIB_OPTION = "$(LIBFLAG)",
CFLAGS = "$(CFLAGS) -I$(LUA_INCDIR)",
},
install_variables = {
LUA_LIBDIR = "$(LIBDIR)"
}
},
win32 = {
type = "make",
build_variables = {
LUA_LIB = "$(LUA_LIBDIR)\\lua5.1.lib",
CFLAGS = "$(CFLAGS) /I$(LUA_INCDIR)",
},
install_variables = {
LUA_LIBDIR = "$(LIBDIR)",
LUA_DIR = "$(LUADIR)",
BIN_DIR = "$(BINDIR)"
}
}
}
}