From 05ff2e65f136ca2bb0ac4d6cfc703c590e6184fc Mon Sep 17 00:00:00 2001 From: Kalev Lember Date: Sun, 9 Jun 2013 13:19:52 +0200 Subject: [PATCH] Update to 0.9.18 --- .gitignore | 1 + GetProcAddress_Script_OpenType.diff | 81 -------------------------- harfbuzz-0.9.9-fix-build-failure.patch | 11 ---- mingw-harfbuzz.spec | 22 +++---- sources | 2 +- 5 files changed, 14 insertions(+), 103 deletions(-) delete mode 100644 GetProcAddress_Script_OpenType.diff delete mode 100644 harfbuzz-0.9.9-fix-build-failure.patch diff --git a/.gitignore b/.gitignore index a4edd26..f86a71d 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ /harfbuzz-0.9.9.tar.bz2 /harfbuzz-0.9.14.tar.bz2 /harfbuzz-0.9.16.tar.bz2 +/harfbuzz-0.9.18.tar.bz2 diff --git a/GetProcAddress_Script_OpenType.diff b/GetProcAddress_Script_OpenType.diff deleted file mode 100644 index 3c87a70..0000000 --- a/GetProcAddress_Script_OpenType.diff +++ /dev/null @@ -1,81 +0,0 @@ -diff --git a/src/hb-uniscribe.cc b/src/hb-uniscribe.cc -index 2f01c28..93bce52 100644 ---- a/src/hb-uniscribe.cc -+++ b/src/hb-uniscribe.cc -@@ -240,6 +240,11 @@ _hb_uniscribe_shape (hb_shape_plan_t *shape_plan, - hb_face_t *face = font->face; - hb_uniscribe_shaper_face_data_t *face_data = HB_SHAPER_DATA_GET (face); - hb_uniscribe_shaper_font_data_t *font_data = HB_SHAPER_DATA_GET (font); -+ SIOT siot; -+ SSOT ssot; -+ SPOT spot; -+ HINSTANCE hinstLib = LoadLibrary("usp10.dll"); -+ - - #define FAIL(...) \ - HB_STMT_START { \ -@@ -249,6 +254,21 @@ _hb_uniscribe_shape (hb_shape_plan_t *shape_plan, - - HRESULT hr; - -+ if (hinstLib == NULL) -+ FAIL ("LoadLibrary(\"usp10.dll\") failed:", NULL); -+ -+ siot = (SIOT)GetProcAddress(hinstLib, "ScriptItemizeOpenType"); -+ if (siot == NULL) -+ FAIL ("GetProcAddress(\"ScriptItemizeOpenType\") failed:", NULL); -+ -+ ssot = (SSOT)GetProcAddress(hinstLib, "ScriptShapeOpenType"); -+ if (ssot == NULL) -+ FAIL ("GetProcAddress(\"ScriptShapeOpenType\") failed:", NULL); -+ -+ spot = (SPOT)GetProcAddress(hinstLib, "ScriptPlaceOpenType"); -+ if (ssot == NULL) -+ FAIL ("GetProcAddress(\"ScriptPlaceOpenType\") failed:", NULL); -+ - retry: - - unsigned int scratch_size; -@@ -312,7 +332,7 @@ retry: - bidi_state.uBidiLevel = HB_DIRECTION_IS_FORWARD (buffer->props.direction) ? 0 : 1; - bidi_state.fOverrideDirection = 1; - -- hr = ScriptItemizeOpenType (wchars, -+ hr = siot (wchars, - chars_len, - MAX_ITEMS, - &bidi_control, -@@ -344,7 +364,7 @@ retry: - unsigned int item_chars_len = items[i + 1].iCharPos - chars_offset; - - retry_shape: -- hr = ScriptShapeOpenType (font_data->hdc, -+ hr = ssot (font_data->hdc, - &font_data->script_cache, - &items[i].a, - script_tags[i], -@@ -386,7 +406,7 @@ retry: - for (unsigned int j = chars_offset; j < chars_offset + item_chars_len; j++) - log_clusters[j] += glyphs_offset; - -- hr = ScriptPlaceOpenType (font_data->hdc, -+ hr = spot (font_data->hdc, - &font_data->script_cache, - &items[i].a, - script_tags[i], -diff --git a/src/hb-uniscribe.h b/src/hb-uniscribe.h -index 51887c8..b7e55e2 100644 ---- a/src/hb-uniscribe.h -+++ b/src/hb-uniscribe.h -@@ -33,6 +33,11 @@ - #define _WIN32_WINNT 0x0600 - #endif - #include -+#include -+ -+typedef HRESULT WINAPI (*SIOT)(const WCHAR*,int,int,const SCRIPT_CONTROL*,const SCRIPT_STATE*,SCRIPT_ITEM*,OPENTYPE_TAG*,int*); -+typedef HRESULT WINAPI (*SSOT)(HDC,SCRIPT_CACHE*,SCRIPT_ANALYSIS*,OPENTYPE_TAG,OPENTYPE_TAG,int*,TEXTRANGE_PROPERTIES**,int,const WCHAR*,int,int,WORD*,SCRIPT_CHARPROP*,WORD*,SCRIPT_GLYPHPROP*,int*); -+typedef HRESULT WINAPI (*SPOT)(HDC,SCRIPT_CACHE*,SCRIPT_ANALYSIS*,OPENTYPE_TAG,OPENTYPE_TAG,int*,TEXTRANGE_PROPERTIES**,int,const WCHAR*,const WORD*,const SCRIPT_CHARPROP*,int,const WORD*,const SCRIPT_GLYPHPROP*,int,int*,GOFFSET*,ABC*); - - HB_BEGIN_DECLS - diff --git a/harfbuzz-0.9.9-fix-build-failure.patch b/harfbuzz-0.9.9-fix-build-failure.patch deleted file mode 100644 index 8d73228..0000000 --- a/harfbuzz-0.9.9-fix-build-failure.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- harfbuzz-0.9.9/src/hb-uniscribe.h.orig 2012-12-24 14:28:27.539246473 +0100 -+++ harfbuzz-0.9.9/src/hb-uniscribe.h 2012-12-24 14:28:49.002338096 +0100 -@@ -29,7 +29,7 @@ - - #include "hb.h" - --#ifndef _WIN32_WINNT -+#if !defined(_WIN32_WINNT) || _WIN32_WINNT < 0x0600 - #define _WIN32_WINNT 0x0600 - #endif - #include diff --git a/mingw-harfbuzz.spec b/mingw-harfbuzz.spec index 2dda4f1..7fff3fb 100644 --- a/mingw-harfbuzz.spec +++ b/mingw-harfbuzz.spec @@ -1,7 +1,7 @@ %{?mingw_package_header} Name: mingw-harfbuzz -Version: 0.9.16 +Version: 0.9.18 Release: 1%{?dist} Summary: MinGW Windows Harfbuzz library @@ -26,13 +26,6 @@ BuildRequires: mingw64-freetype BuildRequires: mingw64-cairo BuildRequires: mingw64-icu -# https://bugs.freedesktop.org/show_bug.cgi?id=55494 -Patch0: GetProcAddress_Script_OpenType.diff - -# Fix build failure in harfbuzz 0.9.9. Is related to the bug above -Patch1: harfbuzz-0.9.9-fix-build-failure.patch - - %description HarfBuzz is an implementation of the OpenType Layout engine. @@ -73,8 +66,6 @@ Static version of the MinGW Windows Harfbuzz library. %prep %setup -q -n harfbuzz-%{version} -%patch0 -p1 -%patch1 -p1 %build @@ -96,12 +87,16 @@ find $RPM_BUILD_ROOT -name "*.la" -delete %{mingw32_bindir}/hb-shape.exe %{mingw32_bindir}/hb-view.exe %{mingw32_bindir}/libharfbuzz-0.dll +%{mingw32_bindir}/libharfbuzz-icu-0.dll %{mingw32_includedir}/harfbuzz/ %{mingw32_libdir}/libharfbuzz.dll.a +%{mingw32_libdir}/libharfbuzz-icu.dll.a %{mingw32_libdir}/pkgconfig/harfbuzz.pc +%{mingw32_libdir}/pkgconfig/harfbuzz-icu.pc %files -n mingw32-harfbuzz-static %{mingw32_libdir}/libharfbuzz.a +%{mingw32_libdir}/libharfbuzz-icu.a # Win64 %files -n mingw64-harfbuzz @@ -110,15 +105,22 @@ find $RPM_BUILD_ROOT -name "*.la" -delete %{mingw64_bindir}/hb-shape.exe %{mingw64_bindir}/hb-view.exe %{mingw64_bindir}/libharfbuzz-0.dll +%{mingw64_bindir}/libharfbuzz-icu-0.dll %{mingw64_includedir}/harfbuzz/ %{mingw64_libdir}/libharfbuzz.dll.a +%{mingw64_libdir}/libharfbuzz-icu.dll.a %{mingw64_libdir}/pkgconfig/harfbuzz.pc +%{mingw64_libdir}/pkgconfig/harfbuzz-icu.pc %files -n mingw64-harfbuzz-static %{mingw64_libdir}/libharfbuzz.a +%{mingw64_libdir}/libharfbuzz-icu.a %changelog +* Sun Jun 09 2013 Kalev Lember - 0.9.18-1 +- Update to 0.9.18 + * Thu May 9 2013 Erik van Pienbroek - 0.9.16-1 - Update to 0.9.16 diff --git a/sources b/sources index 5e2097f..f5d249a 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -90855e670c790c1fec4592908be3c0b8 harfbuzz-0.9.16.tar.bz2 +0bff05fafef4894031b2b64a65ac1899 harfbuzz-0.9.18.tar.bz2