aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile15
-rw-r--r--Makefile.win15
-rw-r--r--rockspecs/luafilesystem-cvs-1.rockspec28
3 files changed, 39 insertions, 19 deletions
diff --git a/Makefile b/Makefile
index f356cf3..c9bf206 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,4 @@
1# $Id: Makefile,v 1.30 2007/06/07 01:28:08 tomas Exp $ 1# $Id: Makefile,v 1.31 2008/01/23 02:48:47 mascarenhas Exp $
2 2
3T= lfs 3T= lfs
4V= 1.3.0 4V= 1.3.0
@@ -9,15 +9,14 @@ include $(CONFIG)
9SRCS= src/$T.c 9SRCS= src/$T.c
10OBJS= src/$T.o 10OBJS= src/$T.o
11 11
12lib: src/$(LIBNAME) 12lib: src/lfs.so
13 13
14src/$(LIBNAME): $(OBJS) 14src/lfs.so: $(OBJS)
15 export MACOSX_DEPLOYMENT_TARGET="10.3"; $(CC) $(CFLAGS) $(LIB_OPTION) -o src/$(LIBNAME) $(OBJS) 15 export MACOSX_DEPLOYMENT_TARGET="10.3"; $(CC) $(CFLAGS) $(LIB_OPTION) -o src/lfs.so $(OBJS)
16 16
17install: src/$(LIBNAME) 17install: src/lfs.so
18 mkdir -p $(LUA_LIBDIR) 18 mkdir -p $(LUA_LIBDIR)
19 cp src/$(LIBNAME) $(LUA_LIBDIR) 19 cp src/lfs.so $(LUA_LIBDIR)
20 cd $(LUA_LIBDIR); ln -f -s $(LIBNAME) $T.so
21 20
22clean: 21clean:
23 rm -f src/$(LIBNAME) $(OBJS) 22 rm -f src/lfs.so $(OBJS)
diff --git a/Makefile.win b/Makefile.win
index aeff54a..9e8f6fc 100644
--- a/Makefile.win
+++ b/Makefile.win
@@ -1,4 +1,4 @@
1# $Id: Makefile.win,v 1.6 2008/01/23 01:58:25 mascarenhas Exp $ 1# $Id: Makefile.win,v 1.7 2008/01/23 02:48:47 mascarenhas Exp $
2 2
3T= lfs 3T= lfs
4V= 1.3.0 4V= 1.3.0
@@ -8,17 +8,18 @@ include config.win
8SRCS= src\$T.c 8SRCS= src\$T.c
9OBJS= src\$T.obj 9OBJS= src\$T.obj
10 10
11lib: src\$(LIBNAME) 11lib: src\lfs.dll
12 12
13.c.obj: 13.c.obj:
14 $(CC) /c /Fo$@ $(CFLAGS) $< 14 $(CC) /c /Fo$@ $(CFLAGS) $<
15 15
16src\$(LIBNAME): $(OBJS) 16src\lfs.dll: $(OBJS)
17 link /manifest:no /dll /def:src\$T.def /out:src\$(LIBNAME) $(OBJS) $(LUA_LIB) 17 link /dll /def:src\$T.def /out:src\lfs.dll $(OBJS) $(LUA_LIB)
18 mt -manifest src\lfs.dll.manifest -outputresource:src\lfs.dll;2
18 19
19install: src\$(LIBNAME) 20install: src\lfs.dll
20 IF NOT EXIST $(LUA_LIBDIR) mkdir $(LUA_LIBDIR) 21 IF NOT EXIST $(LUA_LIBDIR) mkdir $(LUA_LIBDIR)
21 copy src\$(LIBNAME) $(LUA_LIBDIR) 22 copy src\lfs.dll $(LUA_LIBDIR)
22 23
23clean: 24clean:
24 del src\$(LIBNAME) $(OBJS) src\$T.lib src\$T.exp 25 del src\lfs.dll $(OBJS) src\$T.lib src\$T.exp
diff --git a/rockspecs/luafilesystem-cvs-1.rockspec b/rockspecs/luafilesystem-cvs-1.rockspec
index 253f4f1..a02d4f1 100644
--- a/rockspecs/luafilesystem-cvs-1.rockspec
+++ b/rockspecs/luafilesystem-cvs-1.rockspec
@@ -17,8 +17,28 @@ dependencies = {
17 "lua >= 5.1" 17 "lua >= 5.1"
18} 18}
19build = { 19build = {
20 type = "module", 20 platforms = {
21 modules = { 21 unix = {
22 lfs = "src/lfs.c" 22 type = "make",
23 } 23 build_variables = {
24 LIB_OPTION = "$(LIBFLAG)",
25 CFLAGS = "$(CFLAGS) -I$(LUA_INCDIR)",
26 },
27 install_variables = {
28 LUA_LIBDIR = "$(LIBDIR)"
29 }
30 },
31 win32 = {
32 type = "make",
33 build_variables = {
34 LUA_LIB = "$(LUA_LIBDIR)\\lua5.1.lib",
35 CFLAGS = "$(CFLAGS) /I$(LUA_INCDIR)",
36 },
37 install_variables = {
38 LUA_LIBDIR = "$(LIBDIR)",
39 LUA_DIR = "$(LUADIR)",
40 BIN_DIR = "$(BINDIR)"
41 }
42 }
43 }
24} 44}