From patchwork Tue Jan 16 11:17:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Christina O'Donnell X-Patchwork-Id: 58935 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 E7D0E27BBEA; Tue, 16 Jan 2024 11:47:22 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham 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 B0CC127BBE2 for ; Tue, 16 Jan 2024 11:47:21 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rPhuA-0003pw-5v; Tue, 16 Jan 2024 06:46:54 -0500 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 1rPhtY-0003kw-9k for guix-patches@gnu.org; Tue, 16 Jan 2024 06:46:23 -0500 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 1rPhtK-0000FX-AJ for guix-patches@gnu.org; Tue, 16 Jan 2024 06:46:13 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rPhtK-0007jp-HK for guix-patches@gnu.org; Tue, 16 Jan 2024 06:46:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#68502] [PATCH] gnu: Add evhz. Resent-From: Christina O'Donnell Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 16 Jan 2024 11:46:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 68502 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 68502@debbugs.gnu.org Cc: Christina O'Donnell , Felix Lechner X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.170540554528012 (code B ref -1); Tue, 16 Jan 2024 11:46:02 +0000 Received: (at submit) by debbugs.gnu.org; 16 Jan 2024 11:45:45 +0000 Received: from localhost ([127.0.0.1]:47940 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rPht2-0007GW-2n for submit@debbugs.gnu.org; Tue, 16 Jan 2024 06:45:45 -0500 Received: from lists.gnu.org ([2001:470:142::17]:53254) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rPhS2-0002Fu-Ou for submit@debbugs.gnu.org; Tue, 16 Jan 2024 06:17:51 -0500 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 1rPhRx-00068m-4E for guix-patches@gnu.org; Tue, 16 Jan 2024 06:17:45 -0500 Received: from vmi993448.contaboserver.net ([194.163.141.236] helo=mutix.org) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rPhRu-0003rY-Tp for guix-patches@gnu.org; Tue, 16 Jan 2024 06:17:44 -0500 Received: from [86.132.246.87] (host86-132-246-87.range86-132.btcentralplus.com [86.132.246.87]) (Authenticated sender: cdo) by mutix.org (Postfix) with ESMTPSA id 53B61A630DA; Tue, 16 Jan 2024 12:17:39 +0100 (CET) From: Christina O'Donnell Date: Tue, 16 Jan 2024 11:17:25 +0000 Message-ID: <3cef1d9bbcfa33eb69881262c5db956cd42c682b.1705403845.git.cdo@mutix.org> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Received-SPF: pass client-ip=194.163.141.236; envelope-from=cdo@mutix.org; helo=mutix.org X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Tue, 16 Jan 2024 06:45:41 -0500 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/evhz.scm (evhz): New file and variable. Change-Id: I9708ec7bd72d2fc2f42350321f045068a5135ee2 --- gnu/packages/evhz.scm | 85 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 gnu/packages/evhz.scm base-commit: 162d6a2fdd6af13272967c77347a54934ecb45e6 diff --git a/gnu/packages/evhz.scm b/gnu/packages/evhz.scm new file mode 100644 index 0000000000..7c59c645d9 --- /dev/null +++ b/gnu/packages/evhz.scm @@ -0,0 +1,85 @@ +;;; GNU Guix --- Functional package management for GNU +;;; Copyright © 2024 Christina O'Donnell +;;; +;;; This file is part of GNU Guix. +;;; +;;; GNU Guix is free software; you can redistribute it and/or modify it +;;; under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3 of the License, or (at +;;; your option) any later version. +;;; +;;; GNU Guix is distributed in the hope that it will be useful, but +;;; WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;; GNU General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with GNU Guix. If not, see . + +(define-module (gnu packages evhz) + #:use-module (guix gexp) + #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix packages) + #:use-module (guix git-download) + #:use-module (guix build-system trivial) + #:use-module (guix utils) + #:use-module (gnu packages) + #:use-module (gnu packages base) + #:use-module (gnu packages commencement) + #:use-module (gnu packages gcc) + #:use-module (gnu packages glib) + #:use-module (gnu packages linux)) + +(define-public evhz + (let ((commit "35b7526e0655522bbdf92f6384f4e9dff74f38a0") + (revision "1")) + (package + (name "evhz") + (version (git-version "0.0.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://git.sr.ht/~iank/evhz") + (commit commit))) + (sha256 + (base32 "1m2m60sh12jzc8f38g7g67b3avx2vg8ff0lai891jmjqvxw04bcl")))) + (build-system trivial-build-system) + (arguments + `(#:modules ((guix build utils)) + #:builder (begin + (use-modules (guix build utils)) + (let ((source (assoc-ref %build-inputs "source")) + (glibc (assoc-ref %build-inputs "glibc")) + (gcc (assoc-ref %build-inputs "gcc")) + (binutils (assoc-ref %build-inputs "binutils")) + (linux-libre-headers (assoc-ref %build-inputs + "linux-libre-headers")) + (output (assoc-ref %outputs "out"))) + (setenv "PATH" + (string-join (list (string-append gcc "/bin") + (string-append binutils + "/bin") + (getenv "PATH")) ":")) + (setenv "LIBRARY_PATH" + (string-join (list (string-append glibc "/lib")) + ":")) + (mkdir-p (string-append output "/bin")) + (invoke (string-append gcc "/bin/gcc") + "-o" + (string-append output "/bin/evhz") + "-I" + (string-append linux-libre-headers "/include") + (string-append source "/evhz.c")) #t)))) + (native-inputs (list binutils gcc gcc-toolchain glibc + linux-libre-headers)) + (home-page "https://git.sr.ht/~iank/evhz") + ;; TRANSLATORS: "evdev" should not be translated. + (synopsis "Show mouse polling rate using evdev") + (description + "A simple diagnostic utility to show mouse polling rate under evdev, a Linux +event interface. If you have invested in a high resolution mouse, adjusting the USB +polling rate is a common trick to utilize the added precision it brings. The polling +rate (or report rate) determines how often the mouse sends information to your +computer.") + (license license:apsl2))))