mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-25 04:12:44 +03:00
parent
95c72a5f60
commit
4d5336316c
28
pkgs/development/interpreters/lua-5/zip.nix
Normal file
28
pkgs/development/interpreters/lua-5/zip.nix
Normal file
@ -0,0 +1,28 @@
|
||||
{ pkgs, stdenv, fetchurl, lua5_1, zziplib }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "1.2.3";
|
||||
name = "lua-zip-${version}";
|
||||
isLibrary = true;
|
||||
src = fetchurl {
|
||||
url = "https://github.com/luaforge/luazip/archive/0b8f5c958e170b1b49f05bc267bc0351ad4dfc44.zip";
|
||||
sha256 = "beb9260d606fdd5304aa958d95f0d3c20be7ca0a2cff44e7b75281c138a76a50";
|
||||
};
|
||||
|
||||
buildInputs = [ pkgs.unzip lua5_1 zziplib ];
|
||||
|
||||
preBuild = ''
|
||||
makeFlagsArray=(
|
||||
PREFIX=$out
|
||||
LUA_LIBDIR="$out/lib/lua/${lua5_1.luaversion}"
|
||||
LUA_INC="-I${lua5_1}/include");
|
||||
'';
|
||||
|
||||
patches = [ ./zip.patch ];
|
||||
|
||||
meta = {
|
||||
homepage = "https://github.com/luaforge/luazip";
|
||||
hydraPlatforms = stdenv.lib.platforms.linux;
|
||||
license = stdenv.lib.licenses.mit;
|
||||
};
|
||||
}
|
23
pkgs/development/interpreters/lua-5/zip.patch
Normal file
23
pkgs/development/interpreters/lua-5/zip.patch
Normal file
@ -0,0 +1,23 @@
|
||||
--- a/Makefile 2007-10-30 01:59:10.000000000 +0300
|
||||
+++ b/Makefile 2014-09-18 11:04:53.176320021 +0400
|
||||
@@ -6,10 +6,6 @@
|
||||
|
||||
include $(CONFIG)
|
||||
|
||||
-ifeq "$(LUA_VERSION_NUM)" "500"
|
||||
-COMPAT_O= $(COMPAT_DIR)/compat-5.1.o
|
||||
-endif
|
||||
-
|
||||
SRCS= src/lua$T.c
|
||||
OBJS= src/lua$T.o $(COMPAT_O)
|
||||
|
||||
@@ -19,9 +15,6 @@
|
||||
src/$(LIBNAME): $(OBJS)
|
||||
export MACOSX_DEPLOYMENT_TARGET="10.3"; $(CC) $(CFLAGS) $(LIB_OPTION) -o src/$(LIBNAME) $(OBJS) -lzzip
|
||||
|
||||
-$(COMPAT_DIR)/compat-5.1.o: $(COMPAT_DIR)/compat-5.1.c
|
||||
- $(CC) -c $(CFLAGS) -o $@ $(COMPAT_DIR)/compat-5.1.c
|
||||
-
|
||||
install: src/$(LIBNAME)
|
||||
mkdir -p $(LUA_LIBDIR)
|
||||
cp src/$(LIBNAME) $(LUA_LIBDIR)
|
@ -3721,6 +3721,7 @@ let
|
||||
lua5_expat = callPackage ../development/interpreters/lua-5/expat.nix {};
|
||||
lua5_filesystem = callPackage ../development/interpreters/lua-5/filesystem.nix {};
|
||||
lua51_filesystem = lua5_filesystem.override { lua5=lua5_1; };
|
||||
lua51_zip = callPackage ../development/interpreters/lua-5/zip.nix { };
|
||||
lua5_sec = callPackage ../development/interpreters/lua-5/sec.nix { };
|
||||
|
||||
luarocks = callPackage ../development/tools/misc/luarocks {
|
||||
|
Loading…
Reference in New Issue
Block a user