From 1c1b9c79324137e75705a1333e04c60633969d24 Mon Sep 17 00:00:00 2001 From: Akira TAGOH Date: May 29 2013 09:30:29 +0000 Subject: Disable feature tags support because f18 version of fontconfig doesn't provide that feature. --- diff --git a/libeasyfc-disable-feature-tags.patch b/libeasyfc-disable-feature-tags.patch new file mode 100644 index 0000000..dab6590 --- /dev/null +++ b/libeasyfc-disable-feature-tags.patch @@ -0,0 +1,78 @@ +diff -pruN libeasyfc-0.12.1.orig/libeasyfc/ezfc-font.c libeasyfc-0.12.1/libeasyfc/ezfc-font.c +--- libeasyfc-0.12.1.orig/libeasyfc/ezfc-font.c 2013-03-13 19:21:28.000000000 +0900 ++++ libeasyfc-0.12.1/libeasyfc/ezfc-font.c 2013-05-29 18:26:47.000000000 +0900 +@@ -1228,6 +1228,7 @@ gboolean + ezfc_font_add_feature(ezfc_font_t *font, + const gchar *feature) + { ++#ifdef FC_FONT_FEATURES + ezfc_font_private_t *priv = (ezfc_font_private_t *)font; + GList *l; + +@@ -1245,6 +1246,9 @@ ezfc_font_add_feature(ezfc_font_t *font, + g_list_free(l); + + return FcPatternAddString(priv->pattern, FC_FONT_FEATURES, (const FcChar8 *)feature); ++#else ++ return FALSE; ++#endif + } + + /** +@@ -1267,6 +1271,7 @@ ezfc_font_remove_feature(ezfc_font_t *fo + g_return_val_if_fail (font != NULL, FALSE); + g_return_val_if_fail (feature != NULL && feature[0] != 0, FALSE); + ++#ifdef FC_FONT_FEATURES + if (priv->pattern) { + int i; + FcChar8 *s; +@@ -1281,6 +1286,7 @@ ezfc_font_remove_feature(ezfc_font_t *fo + } + } + } ++#endif + + return FALSE; + } +@@ -1304,6 +1310,7 @@ ezfc_font_get_features(ezfc_font_t *font + + g_return_val_if_fail (font != NULL, NULL); + ++#ifdef FC_FONT_FEATURES + if (priv->pattern) { + int i; + FcChar8 *s; +@@ -1316,6 +1323,7 @@ ezfc_font_get_features(ezfc_font_t *font + retval = g_list_append(retval, s); + } + } ++#endif + + return retval; + } +@@ -1341,6 +1349,7 @@ ezfc_font_get_available_features(ezfc_fo + + g_return_val_if_fail (font != NULL, NULL); + ++#ifdef FC_FONT_FEATURES + if (priv->pattern) { + FcPattern *match = NULL; + FcResult result; +@@ -1372,6 +1381,7 @@ ezfc_font_get_available_features(ezfc_fo + FcPatternDestroy(match); + FT_Done_FreeType(ftlib); + } ++#endif + + return retval; + } +diff -pruN libeasyfc-0.12.1.orig/requires libeasyfc-0.12.1/requires +--- libeasyfc-0.12.1.orig/requires 2013-03-29 17:34:55.000000000 +0900 ++++ libeasyfc-0.12.1/requires 2013-05-29 18:24:25.000000000 +0900 +@@ -1,4 +1,4 @@ +-FONTCONFIG_REQUIRED=2.10.92 ++FONTCONFIG_REQUIRED=2.9.91 + FREETYPE_REQUIRED=2.4.4 + GLIB_REQUIRED=2.14.0 + GOBJECT_REQUIRED=2.0 diff --git a/libeasyfc.spec b/libeasyfc.spec index 2405461..d7afe05 100644 --- a/libeasyfc.spec +++ b/libeasyfc.spec @@ -7,6 +7,7 @@ Group: System Environment/Libraries License: LGPLv3+ URL: http://tagoh.bitbucket.org/libeasyfc/ Source0: https://bitbucket.org/tagoh/libeasyfc/downloads/%{name}-%{version}.tar.bz2 +Patch0: %{name}-disable-feature-tags.patch BuildRequires: glib2-devel gobject-introspection-devel libxml2-devel fontconfig-devel >= 2.10.92 harfbuzz-devel BuildRequires: gettext @@ -58,6 +59,7 @@ applications with libeasyfc-gobject. %prep %setup -q +%patch0 -p1 -b .0-tags %build