public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Marek Szuba" <marecki@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-analyzer/suricata/
Date: Mon, 21 Jun 2021 16:03:49 +0000 (UTC)	[thread overview]
Message-ID: <1624291418.7a2e9ee518178d40409d8d27384ac0c84b2b3ae9.marecki@gentoo> (raw)

commit:     7a2e9ee518178d40409d8d27384ac0c84b2b3ae9
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Mon Jun 21 15:59:50 2021 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Mon Jun 21 16:03:38 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7a2e9ee5

net-analyzer/suricata: limit version of currently selected rust

While simply limiting the version of virtual/rust in dependencies is
likely enough for most users at present, if someone has got both rust
and rust-bin emerged the virtual will only affect the version of one of
them - and it is possible that the version currently set as active
by "eselect rust" is not a supported one.

Closes: https://bugs.gentoo.org/797370
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 net-analyzer/suricata/suricata-6.0.2.ebuild | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/net-analyzer/suricata/suricata-6.0.2.ebuild b/net-analyzer/suricata/suricata-6.0.2.ebuild
index 739d881823d..5a9b9a7ab1a 100644
--- a/net-analyzer/suricata/suricata-6.0.2.ebuild
+++ b/net-analyzer/suricata/suricata-6.0.2.ebuild
@@ -51,7 +51,7 @@ RDEPEND="${PYTHON_DEPS}
 	redis?      ( dev-libs/hiredis )"
 DEPEND="${RDEPEND}
 	>=sys-devel/autoconf-2.69-r5
-	<virtual/rust-1.53.0"  # Bug #797370. Hopefully to be fixed come next release.
+	<virtual/rust-1.53.0"  # Bug #797370 part one. Hopefully to be fixed come next release.
 
 PATCHES=(
 	"${FILESDIR}/${PN}-5.0.1_configure-no-lz4-automagic.patch"
@@ -60,6 +60,18 @@ PATCHES=(
 )
 
 pkg_pretend() {
+	# Bug #797370 part deux, needed to address the edge case of both rust and rust-bin being present
+	#  - in which case the version limit set on virtual/rust only affects one of them.
+	# Version-checking code shamelessly stolen from www-client/firefox.
+	local version_rust=$(rustc -Vv 2>/dev/null | grep -F -- 'release:' | awk '{ print $2 }')
+	[[ -z ${version_rust} ]] && die "Failed to read version from rustc!"
+	if ver_test "${version_rust}" -ge "1.53.0"; then
+		eerror "This version of ${PN} does not support Rust 1.53.0+. Please switch to an older version using"
+		eerror "    eselect rust"
+		eerror "before emerging ${PN}."
+		die "Unsupported version of Rust selected"
+	fi
+
 	if use bpf && use kernel_linux; then
 		if kernel_is -lt 4 15; then
 			ewarn "Kernel 4.15 or newer is necessary to use all XDP features like the CPU redirect map"


             reply	other threads:[~2021-06-21 16:03 UTC|newest]

Thread overview: 81+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-21 16:03 Marek Szuba [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-11-09 13:54 [gentoo-commits] repo/gentoo:master commit in: net-analyzer/suricata/ Sam James
2024-04-07  1:06 Marek Szuba
2024-01-23  5:07 Ionen Wolkens
2023-11-29 21:16 Petr Vaněk
2023-10-25 22:04 Marek Szuba
2023-10-25 22:04 Marek Szuba
2023-08-16 17:08 Marek Szuba
2023-08-16 17:08 Marek Szuba
2023-06-27 21:56 Marek Szuba
2023-05-11 12:03 Marek Szuba
2023-04-16 20:03 Marek Szuba
2023-03-22 23:43 Marek Szuba
2023-03-01 23:12 Marek Szuba
2023-02-01 10:51 Marek Szuba
2023-02-01 10:51 Marek Szuba
2022-12-02 10:00 Marek Szuba
2022-11-10  0:42 Marek Szuba
2022-11-01 13:10 Marek Szuba
2022-11-01  0:36 Marek Szuba
2022-10-04  0:53 Marek Szuba
2022-09-01 12:27 Marek Szuba
2022-08-24 15:36 Marek Szuba
2022-08-24 15:36 Marek Szuba
2022-07-27 23:54 Marek Szuba
2022-07-13 15:55 Marek Szuba
2022-07-13 15:55 Marek Szuba
2022-04-25 22:57 Marek Szuba
2022-04-25 22:57 Marek Szuba
2022-03-23  1:24 Sam James
2021-11-19 14:59 Marek Szuba
2021-11-19 14:59 Marek Szuba
2021-09-25 19:08 Sam James
2021-09-03 12:15 Marek Szuba
2021-09-03 12:15 Marek Szuba
2021-08-23 21:29 Marek Szuba
2021-07-25 20:58 Marek Szuba
2021-07-01  9:47 Marek Szuba
2021-07-01  9:47 Marek Szuba
2021-06-21 14:54 Marek Szuba
2021-06-21 14:54 Marek Szuba
2021-05-17 16:15 Marek Szuba
2021-04-03 19:53 Sam James
2021-03-04 14:47 Marek Szuba
2021-03-04 14:47 Marek Szuba
2021-01-25 17:38 Marek Szuba
2021-01-25 17:38 Marek Szuba
2020-12-06 22:02 Marek Szuba
2020-12-03 12:54 Marek Szuba
2020-10-14 14:44 Marek Szuba
2020-10-09 11:41 Marek Szuba
2020-07-17 20:10 Marek Szuba
2020-05-22 21:02 Marek Szuba
2020-04-23 21:11 Marek Szuba
2020-04-23 21:11 Marek Szuba
2020-03-04  9:46 Marek Szuba
2020-02-05 15:30 Marek Szuba
2019-12-20 10:18 Marek Szuba
2019-12-19 15:18 Marek Szuba
2019-12-16 16:05 Marek Szuba
2019-09-08 19:25 Slawek Lis
2018-06-11 14:04 Marek Szuba
2018-06-03 13:49 Aaron Bauman
2018-05-11  7:43 Slawek Lis
2018-03-26 19:33 Michał Górny
2018-01-24  7:00 Slawek Lis
2018-01-23  9:15 Slawek Lis
2017-07-24  8:30 Slawek Lis
2017-01-07 10:25 Slawek Lis
2016-12-28 13:25 Slawek Lis
2016-12-15  6:19 Slawek Lis
2016-11-29 12:05 Slawek Lis
2016-10-10 19:08 Slawek Lis
2016-06-30 19:03 Slawek Lis
2016-06-29  6:44 Slawek Lis
2016-04-26  6:18 Slawek Lis
2016-02-19 20:19 Slawek Lis
2016-02-19  5:59 Slawek Lis
2016-02-19  5:32 Slawek Lis
2015-12-28  5:53 Slawek Lis
2015-12-28  5:49 Slawek Lis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1624291418.7a2e9ee518178d40409d8d27384ac0c84b2b3ae9.marecki@gentoo \
    --to=marecki@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox