nixpkgs/pkgs/by-name/pt/ptouch-print/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

58 lines
1.0 KiB
Nix

{ cmake
, fetchgit
, gd
, gettext
, git
, lib
, libjpeg
, libpng
, libusb1
, pkg-config
, stdenv
, zlib
}:
stdenv.mkDerivation rec {
pname = "ptouch-print";
version = "1.5-unstable-2024-02-11";
src = fetchgit {
url = "https://git.familie-radermacher.ch/linux/ptouch-print.git";
rev = "8aaeecd84b619587dc3885dd4fea4b7310c82fd4";
hash = "sha256-IIq3SmMfsgwSYbgG1w/wrBnFtb6xdFK2lkK27Qqk6mw=";
};
nativeBuildInputs = [
cmake
git
pkg-config
];
buildInputs = [
gd
gettext
libjpeg
libpng
zlib
libusb1
];
installPhase = ''
runHook preInstall
mkdir -p $out/bin
mv ptouch-print $out/bin
runHook postInstall
'';
meta = with lib; {
description = "Command line tool to print labels on Brother P-Touch printers on Linux";
homepage = "https://dominic.familie-radermacher.ch/projekte/ptouch-print/";
license = licenses.gpl3Plus;
mainProgram = "ptouch-print";
maintainers = with maintainers; [ shamilton ];
platforms = platforms.linux;
};
}