Gentoo Archives: gentoo-commits

From: Craig Andrews <candrews@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-analyzer/netdata/
Date: Wed, 26 Jan 2022 17:43:22
Message-Id: 1643218993.ad1f03b0aa9a5067d0fbfb4b5a14df3000508cab.candrews@gentoo
1 commit: ad1f03b0aa9a5067d0fbfb4b5a14df3000508cab
2 Author: Craig Andrews <candrews <AT> gentoo <DOT> org>
3 AuthorDate: Wed Jan 26 17:43:04 2022 +0000
4 Commit: Craig Andrews <candrews <AT> gentoo <DOT> org>
5 CommitDate: Wed Jan 26 17:43:13 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ad1f03b0
7
8 net-analyzer/netdata: 1.33.0 version bump
9
10 Package-Manager: Portage-3.0.30, Repoman-3.0.3
11 Signed-off-by: Craig Andrews <candrews <AT> gentoo.org>
12
13 net-analyzer/netdata/Manifest | 1 +
14 net-analyzer/netdata/netdata-1.33.0.ebuild | 158 +++++++++++++++++++++++++++++
15 2 files changed, 159 insertions(+)
16
17 diff --git a/net-analyzer/netdata/Manifest b/net-analyzer/netdata/Manifest
18 index cae8b2df3199..f75ce82a3ef3 100644
19 --- a/net-analyzer/netdata/Manifest
20 +++ b/net-analyzer/netdata/Manifest
21 @@ -1 +1,2 @@
22 DIST netdata-1.32.1.tar.gz 22472431 BLAKE2B e05e4f29930493ad0c31373dabff57a3fd4f178730848fe4153aebb6219055ef0edda59577fe0c6cc9bd5cf3444b055e8330744f75581804f316f343fc692710 SHA512 869829eadcec4dd9c05cc6b6279830691b6cf9345cdcc0834e90d71f3bbee508c658d16bd379c51ce470c4e735e7c8d607dc045f45a60da2aa3dac36f37b5757
23 +DIST netdata-1.33.0.tar.gz 22470692 BLAKE2B fc0feed8a93876ca7ec304d8ff95312de19f81fccb5ec564e324751488fe6bb10033c815d456238503bcefdd31ec213d61191e21a5ee6671e23183aec7f298d9 SHA512 31b7ce97a3e756fddc358501d98b5ccf056dbe8d22585628873753f30041533d8926b8549a6f1c795c20b33952ec24df2a3ccdce85d6b1da984964bf08a5a66d
24
25 diff --git a/net-analyzer/netdata/netdata-1.33.0.ebuild b/net-analyzer/netdata/netdata-1.33.0.ebuild
26 new file mode 100644
27 index 000000000000..47d000a08d67
28 --- /dev/null
29 +++ b/net-analyzer/netdata/netdata-1.33.0.ebuild
30 @@ -0,0 +1,158 @@
31 +# Copyright 1999-2022 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=7
35 +PYTHON_COMPAT=( python{3_8,3_9,3_10} )
36 +
37 +inherit autotools fcaps flag-o-matic linux-info python-single-r1 systemd toolchain-funcs
38 +
39 +if [[ ${PV} == *9999 ]] ; then
40 + EGIT_REPO_URI="https://github.com/netdata/${PN}.git"
41 + inherit git-r3
42 +else
43 + SRC_URI="https://github.com/netdata/${PN}/releases/download/v${PV}/${PN}-v${PV}.tar.gz -> ${P}.tar.gz"
44 + S="${WORKDIR}/${PN}-v${PV}"
45 + KEYWORDS="~amd64 ~ppc64 ~x86"
46 +fi
47 +
48 +DESCRIPTION="Linux real time system monitoring, done right!"
49 +HOMEPAGE="https://github.com/netdata/netdata https://my-netdata.io/"
50 +
51 +LICENSE="GPL-3+ MIT BSD"
52 +SLOT="0"
53 +IUSE="caps cloud +compression cpu_flags_x86_sse2 cups +dbengine ipmi +jsonc kinesis +lto mongodb mysql nfacct nodejs postgres prometheus +python tor xen"
54 +REQUIRED_USE="
55 + mysql? ( python )
56 + python? ( ${PYTHON_REQUIRED_USE} )
57 + tor? ( python )"
58 +
59 +# most unconditional dependencies are for plugins.d/charts.d.plugin:
60 +RDEPEND="
61 + acct-group/netdata
62 + acct-user/netdata
63 + app-misc/jq
64 + >=app-shells/bash-4:0
65 + || (
66 + net-analyzer/openbsd-netcat
67 + net-analyzer/netcat
68 + )
69 + net-libs/libwebsockets
70 + net-misc/curl
71 + net-misc/wget
72 + sys-apps/util-linux
73 + virtual/awk
74 + caps? ( sys-libs/libcap )
75 + cups? ( net-print/cups )
76 + dbengine? (
77 + app-arch/lz4
78 + dev-libs/judy
79 + dev-libs/openssl:=
80 + )
81 + dev-libs/libuv
82 + compression? ( sys-libs/zlib )
83 + ipmi? ( sys-libs/freeipmi )
84 + jsonc? ( dev-libs/json-c:= )
85 + kinesis? ( dev-libs/aws-sdk-cpp[kinesis] )
86 + mongodb? ( dev-libs/mongo-c-driver )
87 + nfacct? (
88 + net-firewall/nfacct
89 + net-libs/libmnl
90 + )
91 + nodejs? ( net-libs/nodejs )
92 + prometheus? (
93 + dev-libs/protobuf:=
94 + app-arch/snappy
95 + )
96 + python? (
97 + ${PYTHON_DEPS}
98 + $(python_gen_cond_dep 'dev-python/pyyaml[${PYTHON_USEDEP}]')
99 + mysql? ( $(python_gen_cond_dep 'dev-python/mysqlclient[${PYTHON_USEDEP}]') )
100 + postgres? ( $(python_gen_cond_dep 'dev-python/psycopg:2[${PYTHON_USEDEP}]') )
101 + tor? ( $(python_gen_cond_dep 'net-libs/stem[${PYTHON_USEDEP}]') )
102 + )
103 + xen? (
104 + app-emulation/xen-tools
105 + dev-libs/yajl
106 + )"
107 +DEPEND="${RDEPEND}
108 + virtual/pkgconfig"
109 +
110 +FILECAPS=(
111 + 'cap_dac_read_search,cap_sys_ptrace+ep' 'usr/libexec/netdata/plugins.d/apps.plugin'
112 +)
113 +
114 +pkg_setup() {
115 + use python && python-single-r1_pkg_setup
116 + linux-info_pkg_setup
117 +}
118 +
119 +src_prepare() {
120 + default
121 + eautoreconf
122 +}
123 +
124 +src_configure() {
125 + if use ppc64; then
126 + # bundled dlib does not support vsx on big-endian
127 + # https://github.com/davisking/dlib/issues/397
128 + [[ $(tc-endian) == big ]] && append-flags -mno-vsx
129 + fi
130 +
131 + econf \
132 + --localstatedir="${EPREFIX}"/var \
133 + --with-user=netdata \
134 + $(use_enable cloud) \
135 + $(use_with cloud aclk-ng) \
136 + $(use_enable jsonc) \
137 + $(use_enable cups plugin-cups) \
138 + $(use_enable dbengine) \
139 + $(use_enable nfacct plugin-nfacct) \
140 + $(use_enable ipmi plugin-freeipmi) \
141 + $(use_enable kinesis backend-kinesis) \
142 + $(use_enable lto lto) \
143 + $(use_enable mongodb backend-mongodb) \
144 + $(use_enable prometheus backend-prometheus-remote-write) \
145 + $(use_enable xen plugin-xenstat) \
146 + $(use_enable cpu_flags_x86_sse2 x86-sse) \
147 + $(use_with compression zlib)
148 +}
149 +
150 +src_compile() {
151 + emake clean
152 + default
153 +}
154 +
155 +src_install() {
156 + default
157 +
158 + rm -rf "${D}/var/cache" || die
159 +
160 + keepdir /var/log/netdata
161 + fowners -Rc netdata:netdata /var/log/netdata
162 + keepdir /var/lib/netdata
163 + keepdir /var/lib/netdata/registry
164 + fowners -Rc netdata:netdata /var/lib/netdata
165 +
166 + fowners -Rc root:netdata /usr/share/${PN}
167 +
168 + newinitd system/netdata-openrc ${PN}
169 + systemd_dounit system/netdata.service
170 + insinto /etc/netdata
171 + doins system/netdata.conf
172 +}
173 +
174 +pkg_postinst() {
175 + fcaps_pkg_postinst
176 +
177 + if use nfacct ; then
178 + fcaps 'cap_net_admin' 'usr/libexec/netdata/plugins.d/nfacct.plugin'
179 + fi
180 +
181 + if use xen ; then
182 + fcaps 'cap_dac_override' 'usr/libexec/netdata/plugins.d/xenstat.plugin'
183 + fi
184 +
185 + if use ipmi ; then
186 + fcaps 'cap_dac_override' 'usr/libexec/netdata/plugins.d/freeipmi.plugin'
187 + fi
188 +}