buildLuarocksPackage: cleanup

launchpad/nixpkgs/master
Matthieu Coudron 3 years ago
parent 1d22aed041
commit e62a0eac8f
  1. 4
      maintainers/scripts/update-luarocks-packages
  2. 10
      pkgs/development/interpreters/lua-5/build-lua-package.nix
  3. 5
      pkgs/development/tools/misc/luarocks/luarocks-nix.nix

@ -53,11 +53,11 @@ class LuaPlugin:
'''Name of the plugin, as seen on luarocks.org'''
src: str
'''address to the git repository'''
ref: str
ref: Optional[str]
'''git reference (branch name/tag)'''
version: Optional[str]
'''Set it to pin a package '''
server: str
server: Optional[str]
'''luarocks.org registers packages under different manifests.
Its value can be 'http://luarocks.org/dev'
'''

@ -7,10 +7,8 @@
}:
{
# name ? "${attrs.pname}-${attrs.version}"
pname,
version
pname
, version
# by default prefix `name` e.g. "lua5.2-${name}"
, namePrefix ? if lua.pkgs.isLuaJIT
@ -62,7 +60,7 @@ version
# relative to srcRoot, path to the rockspec to use when using rocks
, rockspecFilename ? null
# "../*.rockspec"
# relative to srcRoot, path to folder that contains the expected rockspec
, rockspecDir ? "."
# must be set for packages that don't have a rock
@ -174,8 +172,6 @@ builtins.removeAttrs attrs ["disabled" "checkInputs" "externalDeps" "extraVariab
${luarocks_content}
EOF
export LUAROCKS_CONFIG="$PWD/${luarocks_config}";
echo "pwd: $PWD"
''
+ lib.optionalString (rockspecFilename == null) ''
rockspecFilename="${generatedRockspecFilename}"

@ -9,11 +9,6 @@ luarocks.overrideAttrs(old: {
sha256 = "sha256-WfzLSpIp0V7Ib4sjYvoJHF+/vHaieccvfVAr5W47QsQ=";
};
patches = [];
# src = builtins.fetchGit {
# url = "https://github.com/nix-community/luarocks-nix.git";
# ref = "test-speedup";
# rev = "68ebd5356206a625021b9add4ec2f916692a55eb";
# };
meta.mainProgram = "luarocks";
})

Loading…
Cancel
Save