From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 0DF27158041 for ; Thu, 14 Mar 2024 06:40:28 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 395B2E2A16; Thu, 14 Mar 2024 06:40:26 +0000 (UTC) Received: from smtp.gentoo.org (mail.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)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id BD6FCE2A16 for ; Thu, 14 Mar 2024 06:40:25 +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 041CE33BE00 for ; Thu, 14 Mar 2024 06:40:25 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 00F85B29 for ; Thu, 14 Mar 2024 06:40:23 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1710398383.217dcaacf2d5fbcb9e5ed09a3cb4deee4c15791f.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-util/ruff/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-util/ruff/ruff-0.3.0-r1.ebuild dev-util/ruff/ruff-0.3.0.ebuild X-VCS-Directories: dev-util/ruff/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: 217dcaacf2d5fbcb9e5ed09a3cb4deee4c15791f X-VCS-Branch: master Date: Thu, 14 Mar 2024 06:40:23 +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: 6f312c29-1d47-495e-be49-2e8dc8d47be0 X-Archives-Hash: 1722477e6fe85f09cbc0bff5b23da2fa commit: 217dcaacf2d5fbcb9e5ed09a3cb4deee4c15791f Author: Eli Schwartz gmail com> AuthorDate: Fri Mar 1 03:05:11 2024 +0000 Commit: Sam James gentoo org> CommitDate: Thu Mar 14 06:39:43 2024 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=217dcaac dev-util/ruff: install as a standard cargo project The python module has no functionality. It can be used solely as: ``` python3.11 -m ruff ``` in which case it will check for sys.prefix + '/bin/ruff' and try to run it. The downside of trying to install it as a python project is that it: - adds fuzzy USE flags on python version - recompiles everything once per python impl, despite attempts at copying sources around - adds extra dependencies on e.g. maturin - generally complicates the ebuild We don't need any of that since this is just a cargo program. Signed-off-by: Eli Schwartz gmail.com> Signed-off-by: Sam James gentoo.org> .../{ruff-0.3.0.ebuild => ruff-0.3.0-r1.ebuild} | 25 +--------------------- 1 file changed, 1 insertion(+), 24 deletions(-) diff --git a/dev-util/ruff/ruff-0.3.0.ebuild b/dev-util/ruff/ruff-0.3.0-r1.ebuild similarity index 94% rename from dev-util/ruff/ruff-0.3.0.ebuild rename to dev-util/ruff/ruff-0.3.0-r1.ebuild index 919b754790e7..820d220acffd 100644 --- a/dev-util/ruff/ruff-0.3.0.ebuild +++ b/dev-util/ruff/ruff-0.3.0-r1.ebuild @@ -5,9 +5,6 @@ EAPI=8 -PYTHON_COMPAT=( python3_{10..12} ) -DISTUTILS_USE_PEP517=maturin - CRATES=" Inflector@0.11.4 adler@1.0.2 @@ -363,7 +360,7 @@ CRATES=" zeroize@1.7.0 " -inherit distutils-r1 cargo +inherit cargo DESCRIPTION="An extremely fast Python linter, written in Rust" HOMEPAGE=" @@ -418,18 +415,6 @@ DOCS=( docs ) -src_prepare() { - sed -r 's:(strip[[:space:]]*=[[:space:]]*)true:\1false:' \ - -i pyproject.toml || die - - default - - # python_copy_sources is called in src_compile after cargo_src_compile - # to avoid rebuilding rust code for each python impl - - rm -rf docs/{.overrides,gitignore} || die -} - src_configure() { export RUSTFLAGS="${RUSTFLAGS}" cargo_src_configure @@ -438,9 +423,6 @@ src_configure() { src_compile() { cargo_src_compile - python_copy_sources - distutils-r1_src_compile - local solib releasedir releasedir=target/$(usex 'debug' 'debug' 'release') @@ -453,12 +435,7 @@ src_test() { cargo_src_test } -# placeholder to silence QA warning, tests are in rust -python_test() { :; } - src_install() { - distutils-r1_src_install - local releasedir=target/$(usex 'debug' 'debug' 'release') dobin ${releasedir}/ruff{,_{dev,python_formatter,shrinking}}