summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Sandall2014-12-31 20:09:21 +0000
committerEric Sandall2015-01-01 05:57:51 +0000
commitdcfa46ad55c9b24e9990d424f521006a25687174 (patch)
treee6bdafb221bdbb65679b7c367723630667d57454
parentc960ee3f2698212779ad8d977e032ee216ece77d (diff)
freetype2: harfbuzz is optional and requires freetype2 already installed
If harfbuzz support is requested, but harfbuzz was not built with freetype support, disable harfbuzz since it'll fail. harfbuzz is optional, and freetype2 needs harfbuzz built with freetype support to work, so how can it be required?!
-rwxr-xr-xgraphics-libs/freetype2/BUILD9
-rwxr-xr-xgraphics-libs/freetype2/DEPENDS17
-rw-r--r--graphics-libs/freetype2/HISTORY6
3 files changed, 28 insertions, 4 deletions
diff --git a/graphics-libs/freetype2/BUILD b/graphics-libs/freetype2/BUILD
new file mode 100755
index 0000000000..78ceee22e7
--- /dev/null
+++ b/graphics-libs/freetype2/BUILD
@@ -0,0 +1,9 @@
+# Fix freetype2 casting for the first time
+# freetype2 with harfbuzz support requires harfbuzz built with freetype2...
+# see http://wiki.linuxfromscratch.org/blfs/ticket/5331#comment:2
+if is_depends_enabled harfbuzz ${SPELL} && ! spell_ok ${SPELL}; then
+ message "${WARNING_COLOR}Disabling harfbuzz for first cast${DEFAULT_COLOR}" &&
+ list_remove OPTS '--with-harfbuzz=yes' &&
+ OPTS="--with-harfbuzz=no ${OPTS}"
+fi
+default_build
diff --git a/graphics-libs/freetype2/DEPENDS b/graphics-libs/freetype2/DEPENDS
index 6dd5042a4d..7a36fa6625 100755
--- a/graphics-libs/freetype2/DEPENDS
+++ b/graphics-libs/freetype2/DEPENDS
@@ -1,4 +1,13 @@
-depends glib2 &&
-depends harfbuzz &&
-depends libpng &&
-depends pcre
+depends glib2 &&
+depends libpng &&
+depends pcre &&
+
+# freetype2 with harfbuzz requires harfbuzz built against freetype2 first
+if spell_ok ${SPELL}; then
+ optional_depends -sub 'FT' 'harfbuzz' \
+ '--with-harfbuzz=yes' \
+ '--with-harfbuzz=no' \
+ 'to improve auto-hinting of OpenType fonts'
+else
+ message "${PROBLEM_COLOR}harfbuzz optional dependency disabled until ${DEFAULT_COLOR}${SPELL_COLOR}${SPELL}${DEFAULT_COLOR}${PROBLEM_COLOR} is cast.${DEFAULT_COLOR}"
+fi
diff --git a/graphics-libs/freetype2/HISTORY b/graphics-libs/freetype2/HISTORY
index 3ef4b9cfdd..bf0023caf0 100644
--- a/graphics-libs/freetype2/HISTORY
+++ b/graphics-libs/freetype2/HISTORY
@@ -1,3 +1,9 @@
+2014-12-31 Eric Sandall <sandalle@sourcemage.org>
+ * BUILD: If harfbuzz support is requested, but harfbuzz was not built
+ with freetype support, disable harfbuzz since it'll fail.
+ * DEPENDS: harfbuzz is optional, and freetype2 needs harfbuzz built with
+ freetype support to work, so how can it be required?!
+
2014-12-07 Pol Vinogradov <vin.public@gmail.com>
* DETAILS: version 2.5.4, SECURITY_PATCH++,
yet another security fix for CVE-2014-2240