From 5e2c1c13fa388533d075554da87d3641019aa739 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Sat, 9 Nov 2019 15:49:20 +0000 Subject: [PATCH] media-libs/harfbuzz: fux current stable against gcc-9 Fix build failure on gcc-9. It's a slightly less invasive version of upstream's commit 2dce85ed06a8cc7ca ("[icu] Remove HB_ICU_STMT (#1993)") Package-Manager: Portage-2.3.78, Repoman-2.3.17 Signed-off-by: Sergei Trofimovich --- .../harfbuzz/files/harfbuzz-2.6.1-gcc-9.patch | 14 ++++++++++++++ media-libs/harfbuzz/harfbuzz-2.6.1.ebuild | 4 ++++ 2 files changed, 18 insertions(+) create mode 100644 media-libs/harfbuzz/files/harfbuzz-2.6.1-gcc-9.patch diff --git a/media-libs/harfbuzz/files/harfbuzz-2.6.1-gcc-9.patch b/media-libs/harfbuzz/files/harfbuzz-2.6.1-gcc-9.patch new file mode 100644 index 000000000000..c16fedd6d9d6 --- /dev/null +++ b/media-libs/harfbuzz/files/harfbuzz-2.6.1-gcc-9.patch @@ -0,0 +1,14 @@ +Fix build failure on gcc-9. It's a slightly less invasive +version of upstream's commit 2dce85ed06a8cc7ca +("[icu] Remove HB_ICU_STMT (#1993)") +--- a/src/hb-icu.cc ++++ b/src/hb-icu.cc +@@ -53,7 +53,7 @@ + + /* ICU doesn't do-while(0) around their statements. Ugh! + * https://unicode-org.atlassian.net/browse/CLDR-13027 */ +-#define HB_ICU_STMT(S) do { S } while (0) ++#define HB_ICU_STMT(S) do { S; } while (0) + + hb_script_t + hb_icu_script_to_script (UScriptCode script) diff --git a/media-libs/harfbuzz/harfbuzz-2.6.1.ebuild b/media-libs/harfbuzz/harfbuzz-2.6.1.ebuild index d8eb3a9c8943..87e7095493c9 100644 --- a/media-libs/harfbuzz/harfbuzz-2.6.1.ebuild +++ b/media-libs/harfbuzz/harfbuzz-2.6.1.ebuild @@ -48,6 +48,10 @@ if [[ ${PV} = 9999 ]] ; then " fi +PATCHES=( + "${FILESDIR}"/${P}-gcc-9.patch +) + pkg_setup() { use test && python-any-r1_pkg_setup if ! use debug ; then -- 2.26.2