commit:     8d8325d22be8b750083a2863c5382eaacf6d2a72
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Sat Feb 20 16:44:31 2021 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Tue Feb 23 19:52:25 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8d8325d2

games-board/chessx: Support build with >=dev-libs/quazip-1.0

Package-Manager: Portage-3.0.14, Repoman-3.0.2
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 games-board/chessx/chessx-1.5.4-r2.ebuild                        | 7 +++++++
 .../chessx/{chessx-1.5.4-r2.ebuild => chessx-1.5.4-r3.ebuild}    | 9 ++++++++-
 games-board/chessx/files/chessx-1.5.4-system-quazip.patch        | 2 +-
 3 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/games-board/chessx/chessx-1.5.4-r2.ebuild 
b/games-board/chessx/chessx-1.5.4-r2.ebuild
index f24f065884e..4e6ee73c879 100644
--- a/games-board/chessx/chessx-1.5.4-r2.ebuild
+++ b/games-board/chessx/chessx-1.5.4-r2.ebuild
@@ -41,6 +41,13 @@ PATCHES=(
        "${FILESDIR}"/${P}-install.patch
 )
 
+src_prepare() {
+       default
+       if has_version "<dev-libs/quazip-1.0"; then
+               sed -e "/^PKGCONFIG/s/quazip/quazip1-qt5/" -i chessx.pro || die
+       fi
+}
+
 src_configure() {
        eqmake5
 }

diff --git a/games-board/chessx/chessx-1.5.4-r2.ebuild 
b/games-board/chessx/chessx-1.5.4-r3.ebuild
similarity index 83%
copy from games-board/chessx/chessx-1.5.4-r2.ebuild
copy to games-board/chessx/chessx-1.5.4-r3.ebuild
index f24f065884e..b3e40f7c587 100644
--- a/games-board/chessx/chessx-1.5.4-r2.ebuild
+++ b/games-board/chessx/chessx-1.5.4-r3.ebuild
@@ -15,7 +15,7 @@ KEYWORDS="~amd64 ~x86"
 IUSE=""
 
 RDEPEND="
-       >=dev-libs/quazip-0.9.1:0
+       >=dev-libs/quazip-0.9.1:0=
        dev-qt/qtcore:5
        dev-qt/qtgui:5
        dev-qt/qtmultimedia:5
@@ -41,6 +41,13 @@ PATCHES=(
        "${FILESDIR}"/${P}-install.patch
 )
 
+src_prepare() {
+       xdg_src_prepare
+       if has_version "<dev-libs/quazip-1.0"; then
+               sed -e "/^PKGCONFIG/s/quazip1-qt5/quazip/" -i chessx.pro || die
+       fi
+}
+
 src_configure() {
        eqmake5
 }

diff --git a/games-board/chessx/files/chessx-1.5.4-system-quazip.patch 
b/games-board/chessx/files/chessx-1.5.4-system-quazip.patch
index b5e4cf8f435..6610d3c8e42 100644
--- a/games-board/chessx/files/chessx-1.5.4-system-quazip.patch
+++ b/games-board/chessx/files/chessx-1.5.4-system-quazip.patch
@@ -67,7 +67,7 @@ Index: chessx.pro
 -INCLUDEPATH += $$[QT_INSTALL_PREFIX]/src/3rdparty/zlib
 +
 +CONFIG += link_pkgconfig
-+PKGCONFIG += quazip
++PKGCONFIG += quazip1-qt5
  
  win32 {
      # DEFINES += ZLIB_WINAPI

Reply via email to