summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Müller <ulm@gentoo.org>2018-08-29 10:47:49 +0200
committerAkinori Hattori <hattya@gentoo.org>2018-08-29 22:33:27 +0900
commitcfe2bf058f9d2e61dd9ce39b46cc4df491a18ec9 (patch)
treec4bd1f3cf6d994d5990294dd25443f69a8d8f965 /dev-libs/m17n-lib
parentapp-office/libreoffice: Add missing DEPEND and build switch (diff)
downloadgentoo-cfe2bf058f9d2e61dd9ce39b46cc4df491a18ec9.tar.gz
gentoo-cfe2bf058f9d2e61dd9ce39b46cc4df491a18ec9.tar.bz2
gentoo-cfe2bf058f9d2e61dd9ce39b46cc4df491a18ec9.zip
dev-libs/m17n-lib: use pkg-config to find freetype
Closes: https://bugs.gentoo.org/664818 Package-Manager: Portage-2.3.40, Repoman-2.3.9
Diffstat (limited to 'dev-libs/m17n-lib')
-rw-r--r--dev-libs/m17n-lib/files/m17n-lib-ftconfig.patch29
-rw-r--r--dev-libs/m17n-lib/m17n-lib-1.8.0.ebuild1
2 files changed, 30 insertions, 0 deletions
diff --git a/dev-libs/m17n-lib/files/m17n-lib-ftconfig.patch b/dev-libs/m17n-lib/files/m17n-lib-ftconfig.patch
new file mode 100644
index 000000000000..203f836bf942
--- /dev/null
+++ b/dev-libs/m17n-lib/files/m17n-lib-ftconfig.patch
@@ -0,0 +1,29 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -210,21 +210,20 @@
+ dnl Check for Freetype2 usability.
+ AC_ARG_WITH(freetype,
+ AS_HELP_STRING([--with-freetype],[enable Freetype support]))
+-AC_CHECK_PROG(HAVE_FREETYPE_CONFIG, freetype-config, yes)
+-if test "x$with_freetype" != "xno" -a "x$HAVE_FREETYPE_CONFIG" = "xyes"; then
+- FREETYPE_INC=`freetype-config --cflags`
++if test "x$with_freetype" != "xno"; then
++ PKG_CHECK_MODULES([FT2], [freetype2])
+ save_CPPFLAGS="$CPPFLAGS"
+- CPPFLAGS="$CPPFLAGS $FREETYPE_INC"
++ CPPFLAGS="$CPPFLAGS $FT2_CFLAGS"
+ AC_CHECK_HEADER(ft2build.h, HAVE_FREETYPE=yes,
+ HAVE_FREETYPE=no CPPFLAGS="$save_CPPFLAGS")
+ if test "x$HAVE_FREETYPE" = "xyes" ; then
+ save_LIBS="$LIBS"
+- LIBS="$LIBS `freetype-config --libs`"
++ LIBS="$LIBS $FT2_LIBS"
+ AC_CHECK_LIB(freetype, FT_Init_FreeType, HAVE_FREETYPE=yes,
+ HAVE_FREETYPE=no)
+ LIBS="$save_LIBS"
+ if test "x$HAVE_FREETYPE" = "xyes"; then
+- FREETYPE_LD_FLAGS=`freetype-config --libs`
++ FREETYPE_LD_FLAGS=$FT2_LIBS
+ AC_DEFINE(HAVE_FREETYPE, 1,
+ [Define to 1 if you have FreeType library and header file.])
+ M17N_EXT_LIBS="$M17N_EXT_LIBS freetype"
diff --git a/dev-libs/m17n-lib/m17n-lib-1.8.0.ebuild b/dev-libs/m17n-lib/m17n-lib-1.8.0.ebuild
index c98449bc3429..767f8eabe5f1 100644
--- a/dev-libs/m17n-lib/m17n-lib-1.8.0.ebuild
+++ b/dev-libs/m17n-lib/m17n-lib-1.8.0.ebuild
@@ -36,6 +36,7 @@ DEPEND="${RDEPEND}
PATCHES=(
"${FILESDIR}"/${PN}-configure.patch
"${FILESDIR}"/${PN}-freetype.patch
+ "${FILESDIR}"/${PN}-ftconfig.patch
"${FILESDIR}"/${PN}-ispell.patch
"${FILESDIR}"/${PN}-parallel-make.patch
"${FILESDIR}"/${PN}-pkg-config.patch