commit: 70424ac996300d8e59596f4b7da81566201d2520 Author: Cristian Othón Martínez Vera <cfuga <AT> cfuga <DOT> mx> AuthorDate: Tue Jun 3 17:19:25 2025 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Sun Jun 8 05:05:13 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=70424ac9
net-analyzer/testssl: fix DNS tools dependencies testssl.sh could use dig, host or nslookup from net-dns/bind, or drill from net-libs/ldns. Closes: https://bugs.gentoo.org/952934 Signed-off-by: Cristian Othón Martínez Vera <cfuga <AT> cfuga.mx> Part-of: https://github.com/gentoo/gentoo/pull/42426 Closes: https://github.com/gentoo/gentoo/pull/42426 Signed-off-by: Sam James <sam <AT> gentoo.org> net-analyzer/testssl/testssl-3.0.9-r1.ebuild | 76 ++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) diff --git a/net-analyzer/testssl/testssl-3.0.9-r1.ebuild b/net-analyzer/testssl/testssl-3.0.9-r1.ebuild new file mode 100644 index 000000000000..e92d15a3b3bd --- /dev/null +++ b/net-analyzer/testssl/testssl-3.0.9-r1.ebuild @@ -0,0 +1,76 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +MY_PN="${PN}.sh" +MY_PV="${PV/_p/-}" + +DESCRIPTION="Tool to check TLS/SSL cipher support" +HOMEPAGE="https://testssl.sh/" +SRC_URI="https://github.com/drwetter/${MY_PN}/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz" +S=${WORKDIR}/${MY_PN}-${MY_PV} + +LICENSE="GPL-2 bundled-openssl? ( openssl )" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86" +IUSE="bundled-openssl kerberos" + +RDEPEND=" + app-shells/bash[net] + sys-apps/util-linux + sys-libs/ncurses:0 + sys-process/procps + || ( + net-dns/bind + net-libs/ldns + ) + bundled-openssl? ( + kerberos? ( + sys-libs/zlib + virtual/krb5 + ) + ) + !bundled-openssl? ( dev-libs/openssl:0 ) +" + +QA_PREBUILT="opt/${PN}/*" + +pkg_setup() { + if use amd64; then + if use kerberos; then + BUNDLED_OPENSSL="openssl.Linux.x86_64.krb" + else + BUNDLED_OPENSSL="openssl.Linux.x86_64" + fi + elif use x86; then + BUNDLED_OPENSSL="openssl.Linux.i686" + fi +} + +src_prepare() { + default + sed -i ${PN}.sh \ + -e 's|TESTSSL_INSTALL_DIR="${TESTSSL_INSTALL_DIR:-""}"|TESTSSL_INSTALL_DIR="/"|' \ + -e 's|$TESTSSL_INSTALL_DIR/etc/|&testssl/|g' || die + + if use bundled-openssl; then + sed -i ${PN}.sh \ + -e "/find_openssl_binary()/a OPENSSL=\"/opt/${PN}/${BUNDLED_OPENSSL}\"" || die + fi +} + +src_install() { + dodoc CHANGELOG.md CREDITS.md Readme.md + dodoc openssl-iana.mapping.html + + dobin ${PN}.sh + + insinto /etc/${PN} + doins etc/* + + if use bundled-openssl; then + exeinto /opt/${PN} + use amd64 && doexe bin/${BUNDLED_OPENSSL} + fi +}
