Evas: fine tuned the harfbuzz checks to make sure harfbuzz was compiled with freetype...
authortasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Sun, 30 Jan 2011 10:36:24 +0000 (10:36 +0000)
committertasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Sun, 30 Jan 2011 10:36:24 +0000 (10:36 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@56454 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

configure.ac

index 29774a4..dc7dbc1 100644 (file)
@@ -305,6 +305,8 @@ fi
 
 # harfbuzz support
 have_harfbuzz="no"
+have_harfbuzz_glib="no"
+have_harfbuzz_ft="no"
 AC_ARG_ENABLE([harfbuzz],
    AC_HELP_STRING([--disable-harfbuzz],
       [disable complex text shaping and layouting support. @<:@default=enabled@:>@]),
@@ -329,6 +331,33 @@ if test "x${want_harfbuzz}" = "xyes" -o "x${want_harfbuzz}" = "xauto" ; then
           AC_MSG_ERROR([Harfbuzz not found (strict dependencies checking)])
        fi
       ])
+   if test "x$have_harfbuzz" = "xyes" ; then
+
+      CPPFLAGS_SAVE="$CPPFLAGS"
+      CPPFLAGS="$CPPFLAGS $HARFBUZZ_CFLAGS"
+# must have for usage with harfbuzz although harfbuzz may not have it.
+
+      AC_CHECK_HEADER(hb-ft.h,
+          [
+           have_harfbuzz_ft="yes"
+          ],
+          [
+           if test "x$want_harfbuzz" = "xyes" -a "x$use_strict" = "xyes" ; then
+              AC_MSG_ERROR([Harfbuzz-ft not found (strict dependencies checking)])
+           fi
+           have_harfbuzz="no"
+          ])
+# nice to have if harfbuzz has it
+      AC_CHECK_HEADER(hb-glib.h,
+          [
+           have_harfbuzz_glib="yes"
+           AC_DEFINE(HAVE_HARFBUZZ_GLIB, 1, [have harfbuzz glib support])
+          ],
+          [
+           have_harfbuzz_glib="no"
+          ])
+      CPPFLAGS="$CPPFLAGS_SAVE"
+   fi
 fi
 
 if test "x${have_harfbuzz}" = "xno"; then