sq: 0.48.3 -> 0.48.4 (#359055)
[NixPkgs.git] / pkgs / tools / package-management / apk-tools / default.nix
blobf289ff36f7a0c70ee06d3311864aca6c53cf8808
1 { lib, stdenv, fetchFromGitLab, pkg-config, scdoc, openssl, zlib
2 , luaSupport ? stdenv.hostPlatform == stdenv.buildPlatform, lua
3 }:
5 stdenv.mkDerivation rec {
6   pname = "apk-tools";
7   version = "2.14.5";
9   src = fetchFromGitLab {
10     domain = "gitlab.alpinelinux.org";
11     owner = "alpine";
12     repo = "apk-tools";
13     rev = "v${version}";
14     sha256 = "sha256-GtWwLQoN0106uErEDjPrwlz8pmOKdV3OrtfisFhGqoY=";
15   };
17   nativeBuildInputs = [ pkg-config scdoc ]
18     ++ lib.optionals luaSupport [ lua lua.pkgs.lua-zlib ];
19   buildInputs = [ openssl zlib ] ++ lib.optional luaSupport lua;
20   strictDeps = true;
22   makeFlags = [
23     "CROSS_COMPILE=${stdenv.cc.targetPrefix}"
24     "SBINDIR=$(out)/bin"
25     "LIBDIR=$(out)/lib"
26     "LUA=${if luaSupport then "lua" else "no"}"
27     "LUA_LIBDIR=$(out)/lib/lua/${lib.versions.majorMinor lua.version}"
28     "MANDIR=$(out)/share/man"
29     "DOCDIR=$(out)/share/doc/apk"
30     "INCLUDEDIR=$(out)/include"
31     "PKGCONFIGDIR=$(out)/lib/pkgconfig"
32   ];
34   env.NIX_CFLAGS_COMPILE = toString [
35     "-Wno-error=unused-result"
36     "-Wno-error=deprecated-declarations"
37   ];
39   enableParallelBuilding = true;
41   meta = with lib; {
42     homepage = "https://gitlab.alpinelinux.org/alpine/apk-tools";
43     description = "Alpine Package Keeper";
44     maintainers = with maintainers; [ qyliss ];
45     license = licenses.gpl2Only;
46     platforms = platforms.linux;
47     mainProgram = "apk";
48   };