diff options
author | Sandro <sandro.jaeckel@gmail.com> | 2020-12-26 18:35:30 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-26 18:35:30 +0100 |
commit | a76d69addf1bc24a165e8b3b69ede70162159f87 (patch) | |
tree | 106b01afbc18a56c83269dfb19291ee11386c7a3 | |
parent | 5afb1fed39a8fd035295475344a2145e49a81553 (diff) | |
parent | 0da8ad438559138425e87e873a10bce2ce9a4997 (diff) |
Merge pull request #107009 from jonringer/add-pappl
pappl: init at 1.0.0
-rw-r--r-- | pkgs/applications/printing/pappl/default.nix | 62 | ||||
-rw-r--r-- | pkgs/top-level/all-packages.nix | 2 |
2 files changed, 64 insertions, 0 deletions
diff --git a/pkgs/applications/printing/pappl/default.nix b/pkgs/applications/printing/pappl/default.nix new file mode 100644 index 0000000000000..5cad364d240b3 --- /dev/null +++ b/pkgs/applications/printing/pappl/default.nix @@ -0,0 +1,62 @@ +{ lib, stdenv, fetchFromGitHub +, avahi +, cups +, gnutls +, libjpeg +, libpng +, libusb1 +, pkg-config +, withPAMSupport ? true, pam +, zlib +}: + +stdenv.mkDerivation rec { + pname = "pappl"; + version = "1.0.0"; + + src = fetchFromGitHub { + owner = "michaelrsweet"; + repo = pname; + rev = "v${version}"; + sha256 = "1cg06v8hxska0hnybnmfda1v4h3ifjir24nx2iqx80kb6jq0hayb"; + }; + + outputs = [ "out" "dev" ]; + + nativeBuildInputs = [ + pkg-config + ]; + + buildInputs = [ + cups + libjpeg + libpng + libusb1 + zlib + ] ++ lib.optionals (!stdenv.isDarwin) [ + # upstream mentions these are not needed for Mac + # see: https://github.com/michaelrsweet/pappl#requirements + avahi + gnutls + ] ++ lib.optionals withPAMSupport [ + pam + ]; + + # testing requires some networking + # doCheck = true; + + doInstallCheck = true; + installCheckPhase = '' + $out/bin/pappl-makeresheader --help + ''; + + enableParallelBuilding = true; + + meta = with lib; { + description = "C-based framework/library for developing CUPS Printer Applications"; + homepage = "https://github.com/michaelrsweet/pappl"; + license = licenses.asl20; + platforms = platforms.linux; # should also work for darwin, but requires additional work + maintainers = with maintainers; [ jonringer ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c0ffefc72e438..9b9bf8008c3be 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6435,6 +6435,8 @@ in papertrail = callPackage ../tools/text/papertrail { }; + pappl = callPackage ../applications/printing/pappl { }; + par2cmdline = callPackage ../tools/networking/par2cmdline { }; parallel = callPackage ../tools/misc/parallel { }; |