commit:     6bef3592397b1e52042ca088d0e15e8631a7ccbf
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Mon May  7 09:12:41 2018 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Mon May  7 09:12:57 2018 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6bef3592

games-arcade/openmortal: Use pkg-config to find freetype

Closes: https://bugs.gentoo.org/655036
Package-Manager: Portage-2.3.36, Repoman-2.3.9

 .../files/openmortal-0.7-freetype_pkgconfig.patch  | 24 ++++++++++++++++++++++
 games-arcade/openmortal/openmortal-0.7-r2.ebuild   |  8 +++++---
 2 files changed, 29 insertions(+), 3 deletions(-)

diff --git 
a/games-arcade/openmortal/files/openmortal-0.7-freetype_pkgconfig.patch 
b/games-arcade/openmortal/files/openmortal-0.7-freetype_pkgconfig.patch
new file mode 100644
index 00000000000..fe683899f2e
--- /dev/null
+++ b/games-arcade/openmortal/files/openmortal-0.7-freetype_pkgconfig.patch
@@ -0,0 +1,24 @@
+--- openmortal-0.7/configure.in
++++ openmortal-0.7/configure.in
+@@ -25,6 +25,7 @@
+ AC_C_CONST
+ AC_PROG_CXX
+ 
++PKG_PROG_PKG_CONFIG
+ 
+ dnl
+ dnl Switches
+@@ -122,11 +123,8 @@
+ 
+ dnl Check for Freetype 2 library
+ 
+-FT2_VERSION=2.1.0
+-AC_CHECK_FT2(
+-      $FT2_VERSION,
+-      :,
+-      AC_MSG_ERROR([*** FreeType 2 version $FT2_VERSION not found!])
++PKG_CHECK_MODULES(FT2, freetype2,,
++      AC_MSG_ERROR([*** FreeType2 not found!])
+ )
+ CXXFLAGS="$CXXFLAGS $FT2_CFLAGS"
+ LIBS="$LIBS $FT2_LIBS"

diff --git a/games-arcade/openmortal/openmortal-0.7-r2.ebuild 
b/games-arcade/openmortal/openmortal-0.7-r2.ebuild
index 025e21b639f..0153c5d051a 100644
--- a/games-arcade/openmortal/openmortal-0.7-r2.ebuild
+++ b/games-arcade/openmortal/openmortal-0.7-r2.ebuild
@@ -13,7 +13,7 @@ SLOT="0"
 KEYWORDS="~amd64 ~x86"
 IUSE=""
 
-DEPEND="media-libs/libsdl[video]
+RDEPEND="media-libs/libsdl[video]
        media-libs/sdl-image
        media-libs/sdl-mixer
        media-libs/sdl-ttf
@@ -21,13 +21,15 @@ DEPEND="media-libs/libsdl[video]
        >=media-libs/freetype-2.4.0:2
        dev-lang/perl
 "
-RDEPEND="${DEPEND}"
+DEPEND="${DEPEND}
+       virtual/pkgconfig"
 
 src_prepare() {
        default
        eapply \
                "${FILESDIR}/${P}"-gcc41.patch \
-               "${FILESDIR}/${P}"-freetype.patch
+               "${FILESDIR}/${P}"-freetype.patch \
+               "${FILESDIR}/${P}"-freetype_pkgconfig.patch
        mv configure.{in,ac} || die
        eautoreconf
 }

Reply via email to