feat: init luasocket at 3.1.0
This commit is contained in:
parent
825a749f74
commit
21ae63573b
2 changed files with 48 additions and 0 deletions
|
@ -73,6 +73,7 @@ in {
|
|||
libubootenv = callPackage ./libubootenv {};
|
||||
linotify = callPackage ./linotify {};
|
||||
lualinux = callPackage ./lualinux {};
|
||||
luasocket = callPackage ./luasocket {};
|
||||
|
||||
# we need to build real lzma instead of using xz, because the lzma
|
||||
# decoder in u-boot doesn't understand streaming lzma archives
|
||||
|
|
47
pkgs/luasocket/default.nix
Normal file
47
pkgs/luasocket/default.nix
Normal file
|
@ -0,0 +1,47 @@
|
|||
{
|
||||
lib,
|
||||
stdenv,
|
||||
fetchFromGitHub,
|
||||
lua,
|
||||
gcc,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "luasocket";
|
||||
version = "3.1.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "lunarmodules";
|
||||
repo = "luasocket";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-sKSzCrQpS+9reN9IZ4wkh4dB50wiIfA87xN4u1lyHo4=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
gcc
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
lua
|
||||
];
|
||||
|
||||
preConfigure = ''
|
||||
substituteInPlace src/makefile \
|
||||
--replace-fail "gcc" "$CC"
|
||||
'';
|
||||
|
||||
preInstall = ''
|
||||
export DESTDIR=$out
|
||||
export prefix=
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Network support for the Lua language";
|
||||
homepage = "https://github.com/lunarmodules/luasocket";
|
||||
changelog = "https://github.com/lunarmodules/luasocket/blob/${src.rev}/CHANGELOG.md";
|
||||
license = lib.licenses.mit;
|
||||
maintainers = with lib.maintainers; [ soyouzpanda ];
|
||||
mainProgram = "luasocket";
|
||||
platforms = lib.platforms.all;
|
||||
};
|
||||
}
|
Loading…
Add table
Reference in a new issue