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.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id F2DFB158F56 for ; Tue, 17 Aug 2021 10:23:29 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E810BE0837; Tue, 17 Aug 2021 10:23:28 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id BDF87E0837 for ; Tue, 17 Aug 2021 10:23:28 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 416A3335D9D for ; Tue, 17 Aug 2021 10:23:25 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id AC37C857 for ; Tue, 17 Aug 2021 10:23:23 +0000 (UTC) From: "Marek Szuba" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Marek Szuba" Message-ID: <1629195793.19ecf04f943e610dce9bfebf786249ac6979f52b.marecki@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-apps/rng-tools/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-apps/rng-tools/metadata.xml sys-apps/rng-tools/rng-tools-6.14-r1.ebuild X-VCS-Directories: sys-apps/rng-tools/ X-VCS-Committer: marecki X-VCS-Committer-Name: Marek Szuba X-VCS-Revision: 19ecf04f943e610dce9bfebf786249ac6979f52b X-VCS-Branch: master Date: Tue, 17 Aug 2021 10:23: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: dc7c03cf-3734-43a4-b4cf-40c627b63ce2 X-Archives-Hash: f226cb9d962ea8c0982f27b6e739669f commit: 19ecf04f943e610dce9bfebf786249ac6979f52b Author: Marek Szuba gentoo org> AuthorDate: Tue Aug 17 10:05:49 2021 +0000 Commit: Marek Szuba gentoo org> CommitDate: Tue Aug 17 10:23:13 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=19ecf04f sys-apps/rng-tools: add support for rtlsdr entropy source Closes: https://bugs.gentoo.org/803101 Signed-off-by: Marek Szuba gentoo.org> sys-apps/rng-tools/metadata.xml | 3 ++ sys-apps/rng-tools/rng-tools-6.14-r1.ebuild | 69 +++++++++++++++++++++++++++++ 2 files changed, 72 insertions(+) diff --git a/sys-apps/rng-tools/metadata.xml b/sys-apps/rng-tools/metadata.xml index 69907447109..73b2fae1636 100644 --- a/sys-apps/rng-tools/metadata.xml +++ b/sys-apps/rng-tools/metadata.xml @@ -19,6 +19,9 @@ Enable PKCS11 entropy support + + Enable atmospheric-static entropy support with net-wireless/rtl-sdr + nhorman/rng-tools diff --git a/sys-apps/rng-tools/rng-tools-6.14-r1.ebuild b/sys-apps/rng-tools/rng-tools-6.14-r1.ebuild new file mode 100644 index 00000000000..36f8eebe105 --- /dev/null +++ b/sys-apps/rng-tools/rng-tools-6.14-r1.ebuild @@ -0,0 +1,69 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit autotools systemd readme.gentoo-r1 toolchain-funcs + +DESCRIPTION="Daemon to use hardware random number generators" +HOMEPAGE="https://github.com/nhorman/rng-tools" +SRC_URI="https://github.com/nhorman/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~mips ~ppc ~ppc64 ~riscv ~x86" +IUSE="jitterentropy nistbeacon pkcs11 rtlsdr selinux" + +DEPEND=" + dev-libs/openssl:0= + jitterentropy? ( app-crypt/jitterentropy:= ) + nistbeacon? ( + dev-libs/jansson + dev-libs/libxml2:2= + net-misc/curl[ssl] + ) + pkcs11? ( dev-libs/libp11:= ) + rtlsdr? ( net-wireless/rtl-sdr ) + elibc_musl? ( sys-libs/argp-standalone )" +RDEPEND="${DEPEND} + selinux? ( sec-policy/selinux-rngd )" +BDEPEND="virtual/pkgconfig" + +src_prepare() { + default + eautoreconf +} + +src_configure() { + local myeconfargs=( + $(use_enable jitterentropy) + $(use_with nistbeacon) + $(use_with pkcs11) + $(use_with rtlsdr) + ) + + econf "${myeconfargs[@]}" +} + +src_install() { + default + + newinitd "${FILESDIR}"/rngd-initd-6.11 rngd + newconfd "${FILESDIR}"/rngd-confd-6.11 rngd + systemd_dounit rngd.service + + if use pkcs11; then + local DISABLE_AUTOFORMATTING=1 + local DOC_CONTENTS=" +The PKCS11 entropy source may require extra packages (e.g. 'dev-libs/opensc') +to support various smartcard readers. Make sure 'PKCS11_OPTIONS' in: + '${EPREFIX}/etc/conf.d/rngd' +reflects the correct PKCS11 engine path to be used by rngd. +" + readme.gentoo_create_doc + fi +} + +pkg_postinst() { + use pkcs11 && readme.gentoo_print_elog +}