nixpkgs/pkgs/by-name/dj/djvulibre/package.nix
aleksana 571c71e6f7 treewide: migrate packages to pkgs/by-name, take 1
We are migrating packages that meet below requirements:

1. using `callPackage`
2. called path is a directory
3. overriding set is empty (`{ }`)
4. not containing path expressions other than relative path (to
makenixpkgs-vet happy)
5. not referenced by nix files outside of the directory, other
than`pkgs/top-level/all-packages.nix`
6. not referencing nix files outside of the directory
7. not referencing `default.nix` (since it's changed to `package.nix`)
8. `outPath` doesn't change after migration

The tool is here: https://github.com/Aleksanaa/by-name-migrate.
2024-11-09 20:04:51 +08:00

51 lines
1.1 KiB
Nix

{ lib, stdenv
, fetchurl
, libjpeg
, libtiff
, librsvg
, libiconv
, bash
}:
stdenv.mkDerivation rec {
pname = "djvulibre";
version = "3.5.28";
src = fetchurl {
url = "mirror://sourceforge/djvu/${pname}-${version}.tar.gz";
sha256 = "1p1fiygq9ny8aimwc4vxwjc6k9ykgdsq1sq06slfbzalfvm0kl7w";
};
outputs = [ "bin" "dev" "out" ];
strictDeps = true;
nativeBuildInputs = [
librsvg
];
buildInputs = [
libjpeg
libtiff
libiconv
bash
];
enableParallelBuilding = true;
patches = [
# Remove uses of the `register` storage class specifier, which was removed in C++17.
# Fixes compilation with clang 16, which defaults to C++17.
./c++17-register-class.patch
./CVE-2021-3500+CVE-2021-32490+CVE-2021-32491+CVE-2021-32492+CVE-2021-32493.patch
];
meta = with lib; {
description = "Big set of CLI tools to make/modify/optimize/show/export DJVU files";
homepage = "https://djvu.sourceforge.net";
license = licenses.gpl2Plus;
maintainers = with maintainers; [ Anton-Latukha ];
platforms = platforms.all;
};
}