From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1463132-garchives=archives.gentoo.org@lists.gentoo.org>
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 9EBC8158020
	for <garchives@archives.gentoo.org>; Sat,  3 Dec 2022 02:22:40 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id B5D01E0958;
	Sat,  3 Dec 2022 02:22:39 +0000 (UTC)
Received: from smtp.gentoo.org (dev.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 pigeon.gentoo.org (Postfix) with ESMTPS id 9C1A5E085E
	for <gentoo-commits@lists.gentoo.org>; Sat,  3 Dec 2022 02:22:39 +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 8690D341361
	for <gentoo-commits@lists.gentoo.org>; Sat,  3 Dec 2022 02:22:38 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id D8BB53A5
	for <gentoo-commits@lists.gentoo.org>; Sat,  3 Dec 2022 02:22:36 +0000 (UTC)
From: "Sam James" <sam@gentoo.org>
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" <sam@gentoo.org>
Message-ID: <1670033215.561f0898eeb3fed5befdac22d0da626913d3617c.sam@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-fs/btrfs-progs/
X-VCS-Repository: repo/gentoo
X-VCS-Files: sys-fs/btrfs-progs/Manifest sys-fs/btrfs-progs/btrfs-progs-6.0.2.ebuild
X-VCS-Directories: sys-fs/btrfs-progs/
X-VCS-Committer: sam
X-VCS-Committer-Name: Sam James
X-VCS-Revision: 561f0898eeb3fed5befdac22d0da626913d3617c
X-VCS-Branch: master
Date: Sat,  3 Dec 2022 02:22:36 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: e1a14390-5098-4a08-bd94-d62ec8f68925
X-Archives-Hash: 3fd3ca18b919b4d517671dc1a284a987

commit:     561f0898eeb3fed5befdac22d0da626913d3617c
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sat Dec  3 02:06:55 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Dec  3 02:06:55 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=561f0898

sys-fs/btrfs-progs: add 6.0.2

Signed-off-by: Sam James <sam <AT> gentoo.org>

 sys-fs/btrfs-progs/Manifest                 |   1 +
 sys-fs/btrfs-progs/btrfs-progs-6.0.2.ebuild | 150 ++++++++++++++++++++++++++++
 2 files changed, 151 insertions(+)

diff --git a/sys-fs/btrfs-progs/Manifest b/sys-fs/btrfs-progs/Manifest
index e2c2343e7d7b..f172ce5d3111 100644
--- a/sys-fs/btrfs-progs/Manifest
+++ b/sys-fs/btrfs-progs/Manifest
@@ -1,3 +1,4 @@
 DIST btrfs-progs-v5.15.1.tar.xz 2280796 BLAKE2B b460254a6261d3d04a2d265a3b4e05a89385888f7ea4f2b16ec5b73922646c7f47a546fc78ba7c009e65914125435cf38157eabffc74f5d00df2c21c844922e3 SHA512 68ed89e337ae857fdaf077eaa889e259e9f162ea2222bdaa03f4187783a8682c24d45c91b0559b901d81429ba2cd3f84087d032d354092d5512fb226bdf91549
 DIST btrfs-progs-v6.0.1.tar.xz 2318988 BLAKE2B a69dfcfe6c9aa057f118d5bfee2904b14a87facb08380146d35ba427a44f2ca3ed8dd323ddc3bc7eeb31deb5d7e6f8f8f6de4155ccac14457bf17c7fa63a288c SHA512 5ae2d05658719bd983374c62f8bf45f9a4cd5d1e86c8b0bc7df2194e7c308a64b5a7c5ef38cc5b359a84d4e3e8318d363ab831e3956088fd3ef5b66b7b7e6ea5
+DIST btrfs-progs-v6.0.2.tar.xz 2321220 BLAKE2B 391bd9dcc7ae2d40c339eb9b7fb466624c3f122149af640bc0ca73abfc85ca7bd076976d47ce2d4eab64fb3b9b1309e3446acdd78ba77e5cb583b939710f8b6c SHA512 8e01fa6e3373d95a8e8577003ceb94722e4dfdf24110bfea79191a9862daf5e6580d72e898fdea134b5e86beeda32948eed572072f7906226189c6f1ac8615e3
 DIST btrfs-progs-v6.0.tar.xz 2317272 BLAKE2B 0d81aefadafaaaf0e535bdb727a376c8476686f3b99b97061fdde75861272474bcc6d6dba3227ba23de621ef5c6afcb38fc8cd9fce32ee0fcb0de046f5dd07d8 SHA512 3ec532c7c96783da11d1c77619bfef87d9d52bf2f6df7bd89c200157052936a2bfd6c961c7e3519e7a12ec611e7b17fb4d6c3f192086bb1b4ebbf87c22cfe24a

diff --git a/sys-fs/btrfs-progs/btrfs-progs-6.0.2.ebuild b/sys-fs/btrfs-progs/btrfs-progs-6.0.2.ebuild
new file mode 100644
index 000000000000..73fcf46caa45
--- /dev/null
+++ b/sys-fs/btrfs-progs/btrfs-progs-6.0.2.ebuild
@@ -0,0 +1,150 @@
+# Copyright 2008-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+
+inherit bash-completion-r1 python-single-r1 udev
+
+libbtrfs_soname=0
+
+if [[ ${PV} != 9999 ]]; then
+	MY_PV="v${PV/_/-}"
+	SRC_URI="https://www.kernel.org/pub/linux/kernel/people/kdave/${PN}/${PN}-${MY_PV}.tar.xz"
+
+	if [[ ${PV} != *_rc* ]] ; then
+		KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
+	fi
+
+	S="${WORKDIR}"/${PN}-${MY_PV}
+else
+	EGIT_REPO_URI="https://github.com/kdave/btrfs-progs.git"
+	EGIT_BRANCH="devel"
+	WANT_LIBTOOL="none"
+	inherit autotools git-r3
+fi
+
+DESCRIPTION="Btrfs filesystem utilities"
+HOMEPAGE="https://btrfs.wiki.kernel.org https://btrfs.readthedocs.io/en/latest/"
+
+LICENSE="GPL-2"
+SLOT="0/${libbtrfs_soname}"
+IUSE="+convert python +man reiserfs static static-libs udev +zstd"
+# Could support it with just !systemd => eudev, see mdadm, but let's
+# see if someone asks for it first.
+REQUIRED_USE="static? ( !udev )"
+
+# Tries to mount repaired filesystems
+RESTRICT="test"
+
+RDEPEND="
+	dev-libs/lzo:2=
+	sys-apps/util-linux:=[static-libs(+)?]
+	sys-libs/zlib:=
+	convert? (
+		sys-fs/e2fsprogs:=
+		reiserfs? (
+			>=sys-fs/reiserfsprogs-3.6.27
+		)
+	)
+	python? ( ${PYTHON_DEPS} )
+	udev? ( virtual/libudev:= )
+	zstd? ( app-arch/zstd:= )
+"
+DEPEND="${RDEPEND}
+	>=sys-kernel/linux-headers-5.10
+	convert? ( sys-apps/acl )
+	python? (
+		$(python_gen_cond_dep '
+			dev-python/setuptools[${PYTHON_USEDEP}]
+		')
+	)
+	static? (
+		dev-libs/lzo:2[static-libs(+)]
+		sys-apps/util-linux:0[static-libs(+)]
+		sys-libs/zlib:0[static-libs(+)]
+		convert? (
+			sys-fs/e2fsprogs[static-libs(+)]
+			reiserfs? (
+				>=sys-fs/reiserfsprogs-3.6.27[static-libs(+)]
+			)
+		)
+		zstd? ( app-arch/zstd[static-libs(+)] )
+	)
+"
+BDEPEND="virtual/pkgconfig
+	man? ( dev-python/sphinx )"
+
+if [[ ${PV} == 9999 ]]; then
+	BDEPEND+=" sys-devel/gnuconfig"
+fi
+
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+
+pkg_setup() {
+	use python && python-single-r1_pkg_setup
+}
+
+src_prepare() {
+	default
+
+	if [[ ${PV} == 9999 ]]; then
+		AT_M4DIR="m4" eautoreconf
+
+		mkdir config || die
+		local automakedir="$(autotools_run_tool --at-output automake --print-libdir)"
+		[[ -e ${automakedir} ]] || die "Could not locate automake directory"
+
+		ln -s "${automakedir}"/install-sh config/install-sh || die
+		ln -s "${BROOT}"/usr/share/gnuconfig/config.guess config/config.guess || die
+		ln -s "${BROOT}"/usr/share/gnuconfig/config.sub config/config.sub || die
+	fi
+}
+
+src_configure() {
+	local myeconfargs=(
+		--bindir="${EPREFIX}"/sbin
+
+		--enable-lzo
+		--disable-experimental
+		$(use_enable convert)
+		$(use_enable man documentation)
+		$(use_enable elibc_glibc backtrace)
+		$(use_enable python)
+		$(use_enable static-libs static)
+		$(use_enable udev libudev)
+		$(use_enable zstd)
+
+		# Could support libgcrypt, libsodium, libkcapi
+		--with-crypto=builtin
+		--with-convert=ext2$(usex reiserfs ',reiserfs' '')
+	)
+
+	econf "${myeconfargs[@]}"
+}
+
+src_compile() {
+	emake V=1 all $(usev static)
+}
+
+src_install() {
+	local makeargs=(
+		$(usex python install_python '')
+		$(usex static install-static '')
+	)
+
+	emake V=1 DESTDIR="${D}" install "${makeargs[@]}"
+
+	newbashcomp btrfs-completion btrfs
+
+	use python && python_optimize
+}
+
+pkg_postinst() {
+	udev_reload
+}
+
+pkg_postrm() {
+	udev_reload
+}