From a981d798eab41b6a7c6484776f04fe178bd536ba Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Sat, 10 Feb 2018 15:17:28 -0600 Subject: [PATCH] Fix more build issues Hopefully most bots come back with this... --- src/check-libstdc++.sh | 5 +++-- src/check-symbols.sh | 2 +- src/hb-buffer.h | 1 - src/hb-gobject-structs.h | 6 ++++++ src/hb-subset-plan.cc | 10 +++++++--- src/hb-subset.cc | 6 +++--- 6 files changed, 20 insertions(+), 10 deletions(-) diff --git a/src/check-libstdc++.sh b/src/check-libstdc++.sh index 653a56609..a7b4c495f 100755 --- a/src/check-libstdc++.sh +++ b/src/check-libstdc++.sh @@ -21,12 +21,13 @@ else fi tested=false -for soname in harfbuzz harfbuzz-icu harfbuzz-subset; do +# harfbuzz-icu links to libstdc++ because icu does. +for soname in harfbuzz harfbuzz-subset harfbuzz-gobject; do for suffix in so dylib; do so=$libs/lib$soname.$suffix if ! test -f "$so"; then continue; fi - echo "Checking that we are not linking to libstdc++ or libc++" + echo "Checking that we are not linking to libstdc++ or libc++ in $so" if $LDD $so | grep 'libstdc[+][+]\|libc[+][+]'; then echo "Ouch, linked to libstdc++ or libc++" stat=1 diff --git a/src/check-symbols.sh b/src/check-symbols.sh index 59b7439a2..af8af4416 100755 --- a/src/check-symbols.sh +++ b/src/check-symbols.sh @@ -17,7 +17,7 @@ fi echo "Checking that we are not exposing internal symbols" tested=false -for soname in harfbuzz harfbuzz-icu harfbuzz-subset; do +for soname in harfbuzz harfbuzz-subset harfbuzz-icu harfbuzz-gobject; do for suffix in so dylib; do so=$libs/lib$soname.$suffix if ! test -f "$so"; then continue; fi diff --git a/src/hb-buffer.h b/src/hb-buffer.h index c9de80298..8a2d3e869 100644 --- a/src/hb-buffer.h +++ b/src/hb-buffer.h @@ -92,7 +92,6 @@ typedef struct hb_glyph_info_t { typedef enum { /*< flags >*/ HB_GLYPH_FLAG_UNSAFE_TO_BREAK = 0x00000001, - /*< private >*/ HB_GLYPH_FLAG_DEFINED = 0x00000001 /* OR of all defined flags */ } hb_glyph_flags_t; diff --git a/src/hb-gobject-structs.h b/src/hb-gobject-structs.h index 1c303219b..3b057d561 100644 --- a/src/hb-gobject-structs.h +++ b/src/hb-gobject-structs.h @@ -111,6 +111,12 @@ HB_EXTERN GType hb_gobject_segment_properties_get_type (void); HB_EXTERN GType hb_gobject_user_data_key_get_type (void); #define HB_GOBJECT_TYPE_USER_DATA_KEY (hb_gobject_user_data_key_get_type ()) +HB_EXTERN GType hb_gobject_ot_math_glyph_variant_get_type (void); +#define HB_GOBJECT_TYPE_USER_DATA_KEY (hb_gobject_ot_math_glyph_variant_get_type ()) + +HB_EXTERN GType hb_gobject_ot_math_glyph_part_get_type (void); +#define HB_GOBJECT_TYPE_USER_DATA_KEY (hb_gobject_ot_math_glyph_part_get_type ()) + HB_END_DECLS diff --git a/src/hb-subset-plan.cc b/src/hb-subset-plan.cc index d9f348c63..830047f53 100644 --- a/src/hb-subset-plan.cc +++ b/src/hb-subset-plan.cc @@ -29,9 +29,13 @@ #include "hb-subset-plan.hh" #include "hb-ot-cmap-table.hh" -HB_INTERNAL int -_hb_codepoint_t_cmp (const void *l, const void *r) { - return *((hb_codepoint_t *) l) - *((hb_codepoint_t *) r); +static int +_hb_codepoint_t_cmp (const void *pa, const void *pb) +{ + hb_codepoint_t a = * (hb_codepoint_t *) pa; + hb_codepoint_t b = * (hb_codepoint_t *) pb; + + return a < b ? -1 : a > b ? +1 : 0; } hb_bool_t diff --git a/src/hb-subset.cc b/src/hb-subset.cc index 4a477f80a..cf26ee32a 100644 --- a/src/hb-subset.cc +++ b/src/hb-subset.cc @@ -251,7 +251,7 @@ hb_subset_face_add_table (hb_face_t *face, hb_tag_t tag, hb_blob_t *blob) return true; } -HB_INTERNAL bool +static bool _add_head_and_set_loca_version (hb_face_t *source, bool use_short_loca, hb_face_t *dest) { hb_blob_t *head_blob = OT::Sanitizer().sanitize (hb_face_reference_table (source, HB_OT_TAG_head)); @@ -278,7 +278,7 @@ _add_head_and_set_loca_version (hb_face_t *source, bool use_short_loca, hb_face_ return has_head; } -HB_INTERNAL bool +static bool _subset_glyf (hb_subset_plan_t *plan, hb_face_t *source, hb_face_t *dest) { hb_blob_t *glyf_prime = nullptr; @@ -300,7 +300,7 @@ _subset_glyf (hb_subset_plan_t *plan, hb_face_t *source, hb_face_t *dest) return success; } -HB_INTERNAL bool +static bool _subset_table (hb_subset_plan_t *plan, hb_face_t *source, hb_tag_t tag,