Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: dd60ccaca722
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 2dc7486b39ee
Choose a head ref
  • 4 commits
  • 3 files changed
  • 2 contributors

Commits on Mar 7, 2019

  1. lua: add isLua53

    teto authored and Mic92 committed Mar 7, 2019

    Verified

    This commit was signed with the committer’s verified signature.
    zimbatm Jonas Chevalier
    Copy the full SHA
    b93ccb7 View commit details
  2. lua: run postConfigure hook for rock and rockspec

    it was previously run only for src.rock
    teto authored and Mic92 committed Mar 7, 2019

    Verified

    This commit was signed with the committer’s verified signature.
    zimbatm Jonas Chevalier
    Copy the full SHA
    ed78182 View commit details
  3. lua5Packages.luuid: fix build

    libuuid is null outside of linux which may explain why ofborg refused it.
    teto authored and Mic92 committed Mar 7, 2019

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    246e354 View commit details
  4. Merge pull request #57015 from Mic92/lua-pkgs

    Subset of  `Lua: convert some more packages`
    Mic92 authored Mar 7, 2019

    Verified

    This commit was signed with the committer’s verified signature.
    zimbatm Jonas Chevalier
    Copy the full SHA
    2dc7486 View commit details
Showing with 19 additions and 6 deletions.
  1. +4 −4 pkgs/development/interpreters/lua-5/build-lua-package.nix
  2. +13 −0 pkgs/development/lua-modules/overrides.nix
  3. +2 −2 pkgs/top-level/lua-packages.nix
8 changes: 4 additions & 4 deletions pkgs/development/interpreters/lua-5/build-lua-package.nix
Original file line number Diff line number Diff line change
@@ -3,8 +3,6 @@
, lua
, stdenv
, wrapLua
, unzip
, writeText
# Whether the derivation provides a lua module or not.
, toLuaModule
}:
@@ -117,14 +115,16 @@ builtins.removeAttrs attrs ["disabled" "checkInputs"] // {
cat > ${luarocks_config} <<EOF
${luarocks_content}
EOF
export LUAROCKS_CONFIG=$PWD/${luarocks_config};
export LUAROCKS_CONFIG="$PWD/${luarocks_config}";
''
+ lib.optionalString (knownRockspec != null) ''
# prevents the following type of error:
# Inconsistency between rockspec filename (42fm1b3d7iv6fcbhgm9674as3jh6y2sh-luv-1.22.0-1.rockspec) and its contents (luv-1.22.0-1.rockspec)
rockspecFilename="$TMP/$(stripHash ''${knownRockspec})"
cp ''${knownRockspec} $rockspecFilename
cp ''${knownRockspec} "$rockspecFilename"
''
+ ''
runHook postConfigure
'';

13 changes: 13 additions & 0 deletions pkgs/development/lua-modules/overrides.nix
Original file line number Diff line number Diff line change
@@ -55,4 +55,17 @@ with super;
install -D completions/zsh/_busted $out/share/zsh/site-functions/_busted
'';
});

luuid = super.luuid.override({
buildInputs = [ pkgs.libuuid ];
extraConfig = ''
variables = {
LIBUUID_INCDIR="${pkgs.lib.getDev pkgs.libuuid}/include";
LIBUUID_LIBDIR="${pkgs.lib.getLib pkgs.libuuid}/lib";
}
'';
meta = {
platforms = pkgs.lib.platforms.linux;
};
});
}
4 changes: 2 additions & 2 deletions pkgs/top-level/lua-packages.nix
Original file line number Diff line number Diff line change
@@ -60,7 +60,7 @@ let

buildLuarocksPackage = with pkgs.lib; makeOverridable( callPackage ../development/interpreters/lua-5/build-lua-package.nix {
inherit toLuaModule;
inherit lua writeText;
inherit lua;
});
in
with self; {
@@ -87,7 +87,7 @@ with self; {
inherit toLuaModule lua-setup-hook;
inherit buildLuarocksPackage buildLuaApplication;
inherit requiredLuaModules luaOlder luaAtLeast
isLua51 isLua52 isLuaJIT lua callPackage;
isLua51 isLua52 isLua53 isLuaJIT lua callPackage;

# wraps programs in $out/bin with valid LUA_PATH/LUA_CPATH
wrapLua = callPackage ../development/interpreters/lua-5/wrap-lua.nix {