I tried building freetype 2.9 today on a Solaris machine with harfbuzz 1.0.6 installed. (I know, that's old and should be fixed, but let me finish this first...)
It detected harfbuzz was present at a version higher than the minimum defined in builds/unix/configure.ac, which is currently: "harfbuzz >= 0.9.21" but the build failed to compile src/autofit/autofit.c giving the errors: In file included from freetype2/src/autofit/autofit.c:35:0: reetype2/src/autofit/afscript.h:35:11: error: ‘HB_SCRIPT_ADLAM’ undeclared here (not in a function) HB_SCRIPT_ADLAM, ^ freetype2/src/autofit/afshaper.c:90:38: note: in definition of macro ‘SCRIPT’ #define SCRIPT( s, S, d, h, H, ss ) h, ^ freetype2/src/autofit/afscript.h:278:11: error: ‘HB_SCRIPT_OSAGE’ undeclared here (not in a function) HB_SCRIPT_OSAGE, ^ freetype2/src/autofit/afshaper.c:90:38: note: in definition of macro ‘SCRIPT’ #define SCRIPT( s, S, d, h, H, ss ) h, ^ gmake: *** [freetype2/src/autofit/rules.mk:74: freetype2/objs/autofit.lo] Error 1 Looking at HarfBuzz, those two scripts were first defined in HarfBuzz 1.3.0: https://github.com/harfbuzz/harfbuzz/commit/691086f131cb6c9d97e98730c27673484bf93f87 The attached patch to map them to HB_SCRIPT_INVALID if they weren't defined let the compile finish with the old HarfBuzz, but I don't know how to test how well the resulting code works. The alternative would be to just raise the minimum required harfbuzz version in builds/unix/configure.ac from 0.9.21 to 1.3.0. -- -Alan Coopersmith- alan.coopersm...@oracle.com Oracle Solaris Engineering - https://blogs.oracle.com/alanc
From 7c5e239af3283e4e5784cdca4e2278ef0583b51e Mon Sep 17 00:00:00 2001 From: Alan Coopersmith <alan.coopersm...@oracle.com> Date: Thu, 22 Feb 2018 16:51:29 -0800 Subject: [PATCH] Fix builds with HarfBuzz versions older than 1.3.0 HB_SCRIPT_ADLAM & HB_SCRIPT_OSAGE weren't defined in older releases Signed-off-by: Alan Coopersmith <alan.coopersm...@oracle.com> --- src/autofit/afscript.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/autofit/afscript.h b/src/autofit/afscript.h index 6ac193f6a..76ebc7da8 100644 --- a/src/autofit/afscript.h +++ b/src/autofit/afscript.h @@ -30,6 +30,9 @@ /* use `HB_SCRIPT_INVALID' as the HarfBuzz script name tag for */ /* them. */ +#ifndef HB_SCRIPT_ADLAM /* added in HarfBuzz 1.3.0 */ +# define HB_SCRIPT_ADLAM HB_SCRIPT_INVALID +#endif SCRIPT( adlm, ADLM, "Adlam", HB_SCRIPT_ADLAM, @@ -273,6 +276,9 @@ HINTING_BOTTOM_TO_TOP, "\xF0\x90\xB0\x97" ) /* ð° */ +#ifndef HB_SCRIPT_OSAGE /* added in HarfBuzz 1.3.0 */ +# define HB_SCRIPT_OSAGE HB_SCRIPT_INVALID +#endif SCRIPT( osge, OSGE, "Osage", HB_SCRIPT_OSAGE, -- 2.15.0
_______________________________________________ Freetype-devel mailing list Freetype-devel@nongnu.org https://lists.nongnu.org/mailman/listinfo/freetype-devel