Gentoo Archives: gentoo-commits

From: Patrick McLean <chutzpah@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-apps/nvme-cli/files/, sys-apps/nvme-cli/
Date: Mon, 31 Oct 2022 17:50:41
Message-Id: 1667238628.326b97370a9222e59502b3bbb1f59507bac6fb39.chutzpah@gentoo
1 commit: 326b97370a9222e59502b3bbb1f59507bac6fb39
2 Author: Patrick McLean <chutzpah <AT> gentoo <DOT> org>
3 AuthorDate: Mon Oct 31 17:50:21 2022 +0000
4 Commit: Patrick McLean <chutzpah <AT> gentoo <DOT> org>
5 CommitDate: Mon Oct 31 17:50:28 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=326b9737
7
8 sys-apps/nvme-cli: add 2.2
9
10 Signed-off-by: Patrick McLean <chutzpah <AT> gentoo.org>
11
12 sys-apps/nvme-cli/Manifest | 1 +
13 sys-apps/nvme-cli/files/nvme-cli-2.2-docdir.patch | 13 ++++++
14 sys-apps/nvme-cli/nvme-cli-2.2.ebuild | 49 +++++++++++++++++++++++
15 3 files changed, 63 insertions(+)
16
17 diff --git a/sys-apps/nvme-cli/Manifest b/sys-apps/nvme-cli/Manifest
18 index 8af04fe51003..f1f4bab98471 100644
19 --- a/sys-apps/nvme-cli/Manifest
20 +++ b/sys-apps/nvme-cli/Manifest
21 @@ -2,3 +2,4 @@ DIST nvme-cli-1.16.tar.gz 598246 BLAKE2B 8aef6ae82ec9a2c67de6c69addd72c87ade6554
22 DIST nvme-cli-2.0.tar.gz 646320 BLAKE2B 81a8161091071be4e98d4feb78b3f3edaed07262212a8950c1882e3b46f38cd82d8cd8bfec62b3971feda6e82d297338e5541c8eda33c8b6f714d3b3ce000c25 SHA512 24a00ee8e0fc963c1757797413ff5725cec18f821a714d6bbbf37906010d72934d6fdd7b466c085f13716a5279d1a7bd3254ee474e37a0ecd00a85ef23e12417
23 DIST nvme-cli-2.1.1.tar.gz 674354 BLAKE2B 2cb995195328a9c91644ff32676eb3a6d9f1927a004ed75d2be0a746f45050b8ae927924a1095a787ea10618bd600133237852f56116c1db25c4eaa03ea9dab5 SHA512 61a8e7c0ae8da082ac0cda2fdf61ffe8d83ed5d4ee31640bde89fde929ba3fe6d788950bd232630af2c7fc5f3563f05f47f350e005c8556691e5aede73c88d74
24 DIST nvme-cli-2.1.2.tar.gz 674414 BLAKE2B e71e32a371c2cebfd7f66539490baa8e8074c5bd21afa2470e73c763c752318ca5abc1fe1a4d3f346137dcdbb604889a23955269f209222384a629e8d6817d6a SHA512 2162a6967a221a4ae7e0261748c26a10ff43d5b592039e29578d8310cf176428d528c2d510c0b58419b70bd6d28f4d2c77f0cd27606d87079c64289d5d14f930
25 +DIST nvme-cli-2.2.gh.tar.gz 706243 BLAKE2B ad06296484b9a1a8e53a904cb5f28f93a25c2882186ddcc2fca1f7762af0f7bedc1775d094d566fca3917419018d87c41b7a78378758a9e0b65c161a8188517e SHA512 a3f572bb1bbd4ba56eb3a4c1e1aa95c4ed5e7bc1d5adb80125fe54a894c470838cad5457a0420692deb39f4302cefc4fc1eab92c08c134faabe03a654b9542f4
26
27 diff --git a/sys-apps/nvme-cli/files/nvme-cli-2.2-docdir.patch b/sys-apps/nvme-cli/files/nvme-cli-2.2-docdir.patch
28 new file mode 100644
29 index 000000000000..92a1c51b11f7
30 --- /dev/null
31 +++ b/sys-apps/nvme-cli/files/nvme-cli-2.2-docdir.patch
32 @@ -0,0 +1,13 @@
33 +diff --git a/Documentation/meson.build b/Documentation/meson.build
34 +index bb0c9724..519c4bfc 100644
35 +--- a/Documentation/meson.build
36 ++++ b/Documentation/meson.build
37 +@@ -187,7 +187,7 @@ want_docs = get_option('docs')
38 + want_docs_build = get_option('docs-build')
39 + if want_docs != 'false'
40 + mandir = join_paths(get_option('mandir'), 'man1')
41 +- htmldir = join_paths(get_option('htmldir'), 'nvme')
42 ++ htmldir = get_option('htmldir')
43 +
44 + asciidoctor = find_program('asciidoc', required: get_option('docs-build'))
45 + if want_docs_build and asciidoctor.found()
46
47 diff --git a/sys-apps/nvme-cli/nvme-cli-2.2.ebuild b/sys-apps/nvme-cli/nvme-cli-2.2.ebuild
48 new file mode 100644
49 index 000000000000..e306a3a8eb3b
50 --- /dev/null
51 +++ b/sys-apps/nvme-cli/nvme-cli-2.2.ebuild
52 @@ -0,0 +1,49 @@
53 +# Copyright 1999-2022 Gentoo Authors
54 +# Distributed under the terms of the GNU General Public License v2
55 +
56 +EAPI=8
57 +
58 +inherit meson systemd udev
59 +
60 +DESCRIPTION="NVM-Express user space tooling for Linux"
61 +HOMEPAGE="https://github.com/linux-nvme/nvme-cli"
62 +SRC_URI="https://github.com/linux-nvme/nvme-cli/archive/v${PV}.tar.gz -> ${P}.gh.tar.gz"
63 +RESTRICT="test"
64 +
65 +LICENSE="GPL-2 GPL-2+"
66 +SLOT="0"
67 +KEYWORDS="~amd64 ~arm64 ~loong ~ppc64 ~riscv ~x86"
68 +IUSE="hugepages +json"
69 +
70 +RDEPEND="
71 + >=sys-libs/libnvme-1.2:=[json=]
72 + hugepages? ( sys-libs/libhugetlbfs:= )
73 + json? ( dev-libs/json-c:= )
74 + sys-libs/zlib:=
75 +"
76 +
77 +DEPEND="
78 + ${RDEPEND}
79 +"
80 +BDEPEND="
81 + virtual/pkgconfig
82 +"
83 +
84 +PATCHES=(
85 + "${FILESDIR}/nvme-cli-2.2-docdir.patch"
86 +)
87 +
88 +src_configure() {
89 + local unitdir="$(systemd_get_systemunitdir)"
90 + local emesonargs=(
91 + -Ddocs=all
92 + -Dhtmldir="${EPREFIX}/usr/share/doc/${P}/html"
93 + -Dsystemddir="${unitdir%/system}"
94 + -Dudevrulesdir="${EPREFIX}$(get_udevdir)"
95 + )
96 + meson_src_configure
97 +}
98 +
99 +src_install() {
100 + meson_src_install
101 +}