nixpkgs/pkgs/tools/package-management/apt/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

87 lines
1.5 KiB
Nix
Raw Normal View History

2021-09-02 14:02:50 +00:00
{ lib
, stdenv
, fetchurl
, bzip2
, cmake
, curl
, db
, docbook_xml_dtd_45
, docbook_xsl
, dpkg
, gnutls
, gtest
, libgcrypt
, libseccomp
, libtasn1
, libxslt
, lz4
, perlPackages
, pkg-config
, triehash
, udev
, xxHash
, xz
, zstd
, withDocs ? true , w3m, doxygen
, withNLS ? true , gettext
2017-06-14 03:36:52 +00:00
}:
stdenv.mkDerivation rec {
pname = "apt";
2022-02-07 15:27:29 +00:00
version = "2.3.15";
2017-06-14 03:36:52 +00:00
src = fetchurl {
url = "mirror://debian/pool/main/a/apt/apt_${version}.tar.xz";
2022-02-07 15:27:29 +00:00
hash = "sha256-JWIAfREJk91+eobdgeplDmEhAXm1nqxytu3/Y2TAu6Y=";
2017-06-14 03:36:52 +00:00
};
2021-09-02 14:02:50 +00:00
nativeBuildInputs = [
cmake
gtest
libxslt.bin
pkg-config
triehash
];
2017-06-14 03:36:52 +00:00
buildInputs = [
2021-09-02 14:02:50 +00:00
bzip2
curl
db
dpkg
gnutls
libgcrypt
libseccomp
libtasn1
lz4
perlPackages.perl
udev
xxHash
xz
zstd
2017-06-14 03:36:52 +00:00
] ++ lib.optionals withDocs [
2021-09-02 14:02:50 +00:00
docbook_xml_dtd_45
doxygen
perlPackages.Po4a
w3m
2017-06-14 03:36:52 +00:00
] ++ lib.optionals withNLS [
gettext
];
cmakeFlags = [
2021-09-02 14:02:50 +00:00
"-DBERKELEY_INCLUDE_DIRS=${db.dev}/include"
"-DDOCBOOK_XSL=${docbook_xsl}/share/xml/docbook-xsl"
2021-09-02 14:02:50 +00:00
"-DGNUTLS_INCLUDE_DIR=${gnutls.dev}/include"
"-DROOT_GROUP=root"
"-DUSE_NLS=${if withNLS then "ON" else "OFF"}"
2021-09-02 14:02:50 +00:00
"-DWITH_DOC=${if withDocs then "ON" else "OFF"}"
];
2017-06-14 03:36:52 +00:00
meta = with lib; {
homepage = "https://salsa.debian.org/apt-team/apt";
2021-09-02 14:02:50 +00:00
description = "Command-line package management tools used on Debian-based systems";
2017-06-14 03:36:52 +00:00
license = licenses.gpl2Plus;
platforms = platforms.linux;
maintainers = with maintainers; [ cstrahan ];
};
}