From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id B57721582EF for ; Sat, 15 Feb 2025 18:49:30 +0000 (UTC) Received: from lists.gentoo.org (bobolink.gentoo.org [140.211.166.189]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: relay-lists.gentoo.org@gentoo.org) by smtp.gentoo.org (Postfix) with ESMTPSA id 986783430D6 for ; Sat, 15 Feb 2025 18:49:30 +0000 (UTC) Received: from bobolink.gentoo.org (localhost [127.0.0.1]) by bobolink.gentoo.org (Postfix) with ESMTP id 81E101102CD; Sat, 15 Feb 2025 18:49:29 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bobolink.gentoo.org (Postfix) with ESMTPS id 750671102CD for ; Sat, 15 Feb 2025 18:49:29 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id F1E453430DB for ; Sat, 15 Feb 2025 18:49:28 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 4ADC316DF for ; Sat, 15 Feb 2025 18:49:27 +0000 (UTC) From: "Arthur Zamarin" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Arthur Zamarin" Message-ID: <1739645331.ace3dbbfdaafbf53d7e5c0e838f9b19c6d13e4af.arthurzam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-apps/razercfg/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-apps/razercfg/Manifest sys-apps/razercfg/razercfg-0.43.ebuild X-VCS-Directories: sys-apps/razercfg/ X-VCS-Committer: arthurzam X-VCS-Committer-Name: Arthur Zamarin X-VCS-Revision: ace3dbbfdaafbf53d7e5c0e838f9b19c6d13e4af X-VCS-Branch: master Date: Sat, 15 Feb 2025 18:49:27 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: a4bdd67d-e2e3-4891-a576-4d1c6a3471a3 X-Archives-Hash: 42a4ae3ace98fecfb8e5913909653e2c commit: ace3dbbfdaafbf53d7e5c0e838f9b19c6d13e4af Author: Arthur Zamarin gentoo org> AuthorDate: Sat Feb 15 18:48:51 2025 +0000 Commit: Arthur Zamarin gentoo org> CommitDate: Sat Feb 15 18:48:51 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ace3dbbf sys-apps/razercfg: add 0.43, enable py3.1{1,2,3}, cleanup Closes: https://bugs.gentoo.org/847499 Closes: https://bugs.gentoo.org/897262 Closes: https://bugs.gentoo.org/929820 Signed-off-by: Arthur Zamarin gentoo.org> sys-apps/razercfg/Manifest | 1 + sys-apps/razercfg/razercfg-0.43.ebuild | 93 ++++++++++++++++++++++++++++++++++ 2 files changed, 94 insertions(+) diff --git a/sys-apps/razercfg/Manifest b/sys-apps/razercfg/Manifest index 5699716bb14e..ae921fc5375c 100644 --- a/sys-apps/razercfg/Manifest +++ b/sys-apps/razercfg/Manifest @@ -1 +1,2 @@ DIST razercfg-0.42.tar.xz 103300 BLAKE2B 83f9432edf4deda78514dd1e2a65e04981d3646c543ebf3b74060f5d6ee5f9c3ddec5b0c544c11c9968c790172ae2bd4d4503adaf1428ca31337fdcd33d8545c SHA512 3856f4133b620fb639a46a5bb02fe8e6c47ae3928a04fe9d1bbef2792a44fdd4f5dff2efa43a1e43d75312025d3c65c626e331e723092e4e0b8d6622657fb197 +DIST razercfg-0.43.tar.xz 99096 BLAKE2B d51b175cd4efbe377322d0a4f31fdd992c1d23bd647d17746c620892d4dab7917969df98eca2f35856fbb58dc3e139526e8381cbc52200d10de8803b354e7ab0 SHA512 0d852c86846f14a5da64350e8c0de5288fc9ad6dbbaf4e35b8aea4c9e11eb43269240bc13deac3a49940557846c0e6d73ebefbc26dddc11a47bcc12a3691aca7 diff --git a/sys-apps/razercfg/razercfg-0.43.ebuild b/sys-apps/razercfg/razercfg-0.43.ebuild new file mode 100644 index 000000000000..d541939ffcdc --- /dev/null +++ b/sys-apps/razercfg/razercfg-0.43.ebuild @@ -0,0 +1,93 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) + +inherit cmake python-single-r1 systemd tmpfiles udev xdg + +DESCRIPTION="Utility for advanced configuration of Razer mice" +HOMEPAGE="https://bues.ch/cms/hacking/razercfg.html https://github.com/mbuesch/razer" +SRC_URI="https://bues.ch/${PN}/${P}.tar.xz" + +LICENSE="GPL-2+" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="gui" +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +DEPEND="${PYTHON_DEPS} + virtual/libusb:1 +" +RDEPEND="${DEPEND} + virtual/udev + gui? ( + $(python_gen_cond_dep ' + dev-python/pyqt5[${PYTHON_USEDEP}] + ') + ) +" +BDEPEND="virtual/pkgconfig" + +src_prepare() { + cmake_src_prepare + + # Don't clobber toolchain defaults + sed -i -e '/-D_FORTIFY_SOURCE=2/d' scripts/cmake.global || die + + sed -i CMakeLists.txt \ + -e "s@/etc/udev/rules.d@$(get_udevdir)@" \ + -e "s@/usr/lib/systemd/system@$(systemd_get_systemunitdir)@" || die + + sed -i librazer/CMakeLists.txt \ + -e '/ldconfig/{N;d}' \ + -e "s:DESTINATION lib:DESTINATION $(get_libdir):" \ + || die + + sed -i ui/razercfg.desktop.template \ + -e '/^Categories=/s/=.*$/=Qt;Settings/' \ + || die + + export RAZERCFG_PKG_BUILD=1 +} + +src_configure() { + local mycmakeargs=( + -DPYTHON="${PYTHON}" + ) + cmake_src_configure +} + +src_install() { + cmake_src_install + + python_optimize + + newinitd "${FILESDIR}"/razerd.init.d-r2 razerd + dodoc README.* HACKING.* razer.conf + + if ! use gui; then + rm "${D}"/usr/bin/qrazercfg{,-applet} || die + rm -r "${D}"/usr/share/{applications,icons} || die + fi + + # sys-power/pm-utils is deprecated, so we delete related files + # (they contain a hook for resume from suspend) + # TODO: test resume from suspend + rm -r "${D}/etc/pm" || die +} + +pkg_postinst() { + udevadm control --reload-rules + udevadm trigger --subsystem-match=usb + + xdg_pkg_postinst + + tmpfiles_process razerd.conf + + if [[ -e "${ROOT}/usr/bin/pyrazer.pyc" ]]; then + eerror "A stale ${ROOT}/usr/bin/pyrazer.pyc exists and will prevent" + eerror "the Python frontends from working until removed manually." + fi +}