From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1263327-garchives=archives.gentoo.org@lists.gentoo.org>
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 378FD138239
	for <garchives@archives.gentoo.org>; Mon, 22 Mar 2021 08:59:16 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 8ADBFE0837;
	Mon, 22 Mar 2021 08:59:15 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183])
	(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 72BF1E0837
	for <gentoo-commits@lists.gentoo.org>; Mon, 22 Mar 2021 08:59:15 +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 9052433BED4
	for <gentoo-commits@lists.gentoo.org>; Mon, 22 Mar 2021 08:59:14 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 989D9612
	for <gentoo-commits@lists.gentoo.org>; Mon, 22 Mar 2021 08:59:11 +0000 (UTC)
From: "Lars Wendler" <polynomial-c@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Lars Wendler" <polynomial-c@gentoo.org>
Message-ID: <1616403465.18b0451c9ae2db037d996b0a5156ba41bf9d1f5a.polynomial-c@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-libs/zlib-ng/
X-VCS-Repository: repo/gentoo
X-VCS-Files: sys-libs/zlib-ng/zlib-ng-2.0.1-r1.ebuild
X-VCS-Directories: sys-libs/zlib-ng/
X-VCS-Committer: polynomial-c
X-VCS-Committer-Name: Lars Wendler
X-VCS-Revision: 18b0451c9ae2db037d996b0a5156ba41bf9d1f5a
X-VCS-Branch: master
Date: Mon, 22 Mar 2021 08:59:11 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: ec0e33a2-dc1a-49c1-af3a-d61ce23da872
X-Archives-Hash: 780a8b00e1e4ef004de937a6514f2d9e

commit:     18b0451c9ae2db037d996b0a5156ba41bf9d1f5a
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Mar 18 00:01:36 2021 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Mon Mar 22 08:57:45 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=18b0451c

sys-libs/zlib-ng: add blocker on sys-libs/zlib when using compat mode

Warn users if USE=compat is enabled and also include a link
to upstream's interpretation of what USE=compat provides.

Signed-off-by: Sam James <sam <AT> gentoo.org>
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>

 sys-libs/zlib-ng/zlib-ng-2.0.1-r1.ebuild | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/sys-libs/zlib-ng/zlib-ng-2.0.1-r1.ebuild b/sys-libs/zlib-ng/zlib-ng-2.0.1-r1.ebuild
index c00074bbf78..29181862229 100644
--- a/sys-libs/zlib-ng/zlib-ng-2.0.1-r1.ebuild
+++ b/sys-libs/zlib-ng/zlib-ng-2.0.1-r1.ebuild
@@ -18,6 +18,8 @@ IUSE="compat ${CPU_USE[@]} test"
 
 RESTRICT="!test? ( test )"
 
+RDEPEND="compat? ( !sys-libs/zlib )"
+
 src_prepare() {
 	cmake_src_prepare
 
@@ -67,3 +69,15 @@ src_configure() {
 
 	cmake_src_configure
 }
+
+src_install() {
+	cmake_src_install
+
+	if use compat ; then
+		ewarn "zlib-ng is experimental and replacing the system zlib is dangerous"
+		ewarn "Please be careful!"
+		ewarn
+		ewarn "The following link explains the guarantees (and what is NOT guaranteed):"
+		ewarn "https://github.com/zlib-ng/zlib-ng/blob/2.0.x/PORTING.md"
+	fi
+}