From 8382ef436288664a1199e33f21336c7b9388ab58 Mon Sep 17 00:00:00 2001 From: tomas Date: Wed, 29 Sep 2004 17:46:24 +0000 Subject: [PATCH] Atualizando o codigo para a nova proposta de pacotes. --- Makefile | 22 +++++++++------------- t_lfs.lua | 8 -------- 2 files changed, 9 insertions(+), 21 deletions(-) delete mode 100644 t_lfs.lua diff --git a/Makefile b/Makefile index df9d59a..37703e7 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -# $Id: Makefile,v 1.3 2004/07/29 16:47:11 tomas Exp $ +# $Id: Makefile,v 1.4 2004/09/29 17:46:24 tomas Exp $ T= lfs @@ -9,8 +9,6 @@ DIST_DIR= luafilesystem-$V TAR_FILE= $(DIST_DIR).tar.gz ZIP_FILE= $(DIST_DIR).zip LIBNAME= lib$T.$V$(LIB_EXT) -L= $T.lua -TL= t_$T.lua SRCS= $T.c OBJS= $T.o @@ -18,24 +16,22 @@ OBJS= $T.o lib: $(LIBNAME) -$(LIBNAME): $(OBJS) $(TL) +$(LIBNAME): $(OBJS) $(CC) $(CFLAGS) $(LIB_OPTION) -o $(LIBNAME) $(OBJS) $(LIBS) - sed -e "s|LIB_NAME|$(LIB_DIR)/$(LIBNAME)|" $(TL) > $L -$(LUA_DIR)/$L: $L - mkdir -p $(LUA_DIR) - cp $L $(LUA_DIR) - -install: $(LUA_DIR)/$L $(LIBNAME) +install: $(LIBNAME) mkdir -p $(LIB_DIR) cp $(LIBNAME) $(LIB_DIR) + ln -f -s $(LIB_DIR)/$(LIBNAME) $(LIB_DIR)/$T$(LIB_EXT) clean: rm -f $L $(LIBNAME) $(OBJS) -dist: - mkdir -p $(DIST_DIR) - cp config $(SRCS) $T.h $T.def $(TL) Makefile *html $(DIST_DIR) +dist: dist_dir tar -czf $(TAR_FILE) $(DIST_DIR) zip -rq $(ZIP_FILE) $(DIST_DIR)/* rm -rf $(DIST_DIR) + +dist_dir: + mkdir -p $(DIST_DIR) + cp config $(SRCS) $T.h $T.def Makefile *html $(DIST_DIR) diff --git a/t_lfs.lua b/t_lfs.lua deleted file mode 100644 index b81950a..0000000 --- a/t_lfs.lua +++ /dev/null @@ -1,8 +0,0 @@ --- $Id: t_lfs.lua,v 1.1 2004/07/29 14:26:33 tomas Exp $ -if not lfs and loadlib then - local libname = "LIB_NAME" - local libopen = "luaopen_lfs" - local init, err1, err2 = loadlib (libname, libopen) - assert (init, (err1 or '')..(err2 or '')) - init () -end