[librsvg/librsvg-2.48] tests/test-utils.c: Fix build without PangoFT2



commit adc291a499ecd643d4fe068cecca6d2453bb2236
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Wed Mar 25 12:42:59 2020 +0800

    tests/test-utils.c: Fix build without PangoFT2
    
    PangoFT2's headers included the FreeType2 headers for us, but builds without
    PangoFT2 had to include them explicitly.  So do so here if we don't have
    PangoFT2.  Also, if we are building against Pango that is before 1.44.0,
    include the HarfBuzz headers explicitly, since Pango core only included that
    for us since 1.44.0.

 tests/test-utils.c | 6 ++++++
 1 file changed, 6 insertions(+)
---
diff --git a/tests/test-utils.c b/tests/test-utils.c
index 847703b5..e7fd3fc0 100644
--- a/tests/test-utils.c
+++ b/tests/test-utils.c
@@ -9,6 +9,12 @@
 #include <pango/pangocairo.h>
 #ifdef HAVE_PANGOFT2
 #include <pango/pangofc-fontmap.h>
+#else
+# if !PANGO_VERSION_CHECK (1, 44, 0)
+#  include <hb.h>
+# endif
+# include <ft2build.h>
+# include FT_FREETYPE_H
 #endif
 
 /* Compare two buffers, returning the number of pixels that are


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]