From patchwork Tue Apr 8 22:04:46 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fredrik Salomonsson X-Patchwork-Id: 41473 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 574CF27BC4A; Tue, 8 Apr 2025 23:06:30 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-7.4 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H2, RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE, SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 6FAE827BC49 for ; Tue, 8 Apr 2025 23:06:28 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1u2H5B-0008Rx-LM; Tue, 08 Apr 2025 18:06:13 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1u2H56-0008RH-P5 for guix-patches@gnu.org; Tue, 08 Apr 2025 18:06:08 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1u2H56-0000rP-Ga for guix-patches@gnu.org; Tue, 08 Apr 2025 18:06:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:From:To:In-Reply-To:References:Subject; bh=bOOSGV3HboZGHVxSl63HUKJApjjVkjfunr6hgn77Z7s=; b=QpvVTGYGaj982rAYdK0SIH5k0S96jCd5J4WyQ25fJQQGtYi/xTiF8ywmZHAwq/ngGDibnomOPXvhrF/gujq6Qf/LjDVsmrlLiTfh3amv1Y5uHVGl1u/+WYvzlKKJvpjKmqO715DE6RdNRoX/LbEFliu4Iq0YRrpM2Zpq1N+qP/95wfZt78yfM2DI7UrwLyn5CeY5bT6HVhncjLLa3+G97W3RqalzfheqbcLSS8s/qUn0sHTkEX2vi0taDEPRiNi8A4n8TcBw0MfG+7o8bILRPerL4z2u6yTj/XSVGB4/FMhIxaeHjj6V9sgG1hnFWgWswsp2Kl5FmrZDJSInrCsW9w==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1u2H50-0001Xd-H4; Tue, 08 Apr 2025 18:06:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#74315] [PATCH v2] gnu: Add ptouch-print. References: In-Reply-To: Resent-From: Fredrik Salomonsson Original-Sender: "Debbugs-submit" Resent-CC: plattfot@posteo.net, sharlatanus@gmail.com, steve@futurile.net, guix-patches@gnu.org Resent-Date: Tue, 08 Apr 2025 22:06:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74315 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 74315@debbugs.gnu.org Cc: Fredrik Salomonsson , Fredrik Salomonsson , Sharlatan Hellseher , Steve George X-Debbugs-Original-Xcc: Fredrik Salomonsson , Sharlatan Hellseher , Steve George Received: via spool by 74315-submit@debbugs.gnu.org id=B74315.17441499205809 (code B ref 74315); Tue, 08 Apr 2025 22:06:02 +0000 Received: (at 74315) by debbugs.gnu.org; 8 Apr 2025 22:05:20 +0000 Received: from localhost ([127.0.0.1]:35901 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1u2H4J-0001VX-Ok for submit@debbugs.gnu.org; Tue, 08 Apr 2025 18:05:20 -0400 Received: from mout02.posteo.de ([185.67.36.66]:57687) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1u2H4F-0001To-3C for 74315@debbugs.gnu.org; Tue, 08 Apr 2025 18:05:17 -0400 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 40F2A240101 for <74315@debbugs.gnu.org>; Wed, 9 Apr 2025 00:05:05 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1744149906; bh=rcz/HKt75/ChWhGBb9F5CT7ri3rm/igujADY2+d7iNQ=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version: Content-Transfer-Encoding:From; b=O9a4aqTMB7aksYpj4JtTzW2SmwXaJSIoGmX0itKDuFUnTfIg9V4MVVDjCopaWT2Vv 8fDKJMxJOl48nNS+fCYUrSiX/I60s2yeQ8QyHwA6vR48IzEfiIaHm7LuTFoalvqdF/ H9wqP5nTNlgcOKE05oovYzc3POw4eGd0bA7D9GLx6tPla+qMr7BMyuw/pZy1Z3aC5S GRanCEPcjy6bngr0XHbnnHKcdRUVM1LzxCPB2zVHCuNPFkLZhqPxhoecA0k+hT9/H4 by40eAPBsTnWwluI/y35X4mjvpHa4EmLM/HJgGqmyL1/0MvONCmJKhcGHjgeAi0BvS jUVgQLAbw2axw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4ZXKrK10vsz6v0F; Wed, 9 Apr 2025 00:05:03 +0200 (CEST) From: Fredrik Salomonsson Date: Tue, 8 Apr 2025 22:04:46 +0000 Message-ID: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/printers.scm (ptouch-print): New variable. Change-Id: I2ab2a80b80932af8566f6c5879e63e7b0bced747 --- gnu/packages/printers.scm | 51 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) base-commit: c9dfe2aceb69e121b03349b6610d51d9374b4570 diff --git a/gnu/packages/printers.scm b/gnu/packages/printers.scm index 0069494b4d..8a78adbfd7 100644 --- a/gnu/packages/printers.scm +++ b/gnu/packages/printers.scm @@ -22,14 +22,18 @@ (define-module (gnu packages printers) #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix git-download) + #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) #:use-module (guix build-system go) #:use-module ((guix licenses) #:prefix license:) #:use-module (gnu packages avahi) + #:use-module (gnu packages gd) + #:use-module (gnu packages gettext) #:use-module (gnu packages golang-xyz) #:use-module (gnu packages libusb) #:use-module (gnu packages man) #:use-module (gnu packages pkg-config) + #:use-module (gnu packages version-control) #:use-module (gnu packages qt)) ;; This is a module for packages related to printer-like devices, but not @@ -69,6 +73,53 @@ (define-public ipp-usb simply relay a TCP connection to USB do not work.") (license license:bsd-2))) +(define-public ptouch-print + (package + (name "ptouch-print") + (version "1.6") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://git.familie-radermacher.ch/linux/ptouch-print.git") + (commit (string-append "v" version)))) + (sha256 + (base32 "1pxi30a74azhzsl1wni2va4rkhlfn97qxmz4kryrj9xkvf55jv88")) + (file-name (git-file-name name version)))) + (build-system cmake-build-system) + (arguments + '(#:tests? #f ;no test target + #:phases (modify-phases %standard-phases + (add-before 'configure 'patch-cmakefile + (lambda _ + (substitute* "CMakeLists.txt" + ;; Remove the internal override of CMAKE_INSTALL_PREFIX + (("set\\(CMAKE_INSTALL_PREFIX /usr\\)") + "") + ;; Remove hard coded udev install steps, installing it in the + ;; install-udev-rules phase + (("if\\(EXISTS /etc/udev/rules.d\\) + install\\(FILES udev/90-usb-ptouch-permissions.rules DESTINATION /etc/udev/rules.d\\) + install\\(CODE \"execute_process(COMMAND udevadm control --reload-rules)\"\\) +endif\\(\\) +") + "")) #t)) + (add-after 'install 'install-udev-rules + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (rules (string-append out "/lib/udev/rules.d/"))) + (install-file + "../source/udev/90-usb-ptouch-permissions.rules" + rules))))))) + (native-inputs (list gd git gettext-minimal libusb pkg-config)) + (synopsis "CLI tool to print labels on Brother P-Touch printers") + (description + "A command line tool to print labels on Brother P-Touch +printers on Linux. Note that there is no need to install the printer via CUPS, the +printer is accessed directly via libusb.") + (home-page "https://dominic.familie-radermacher.ch/projekte/ptouch-print/") + (license license:gpl3))) + (define-public robocut (package (name "robocut")