commit:     a66cc3b2b94ae6044fb06edcfffa4c5379d7c9dd
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Mon Aug 25 19:18:39 2025 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Mon Aug 25 19:19:22 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a66cc3b2

app-i18n/mozc: Fix build w/ IUSE fcitx5

Thanks-to: Guillaume Lespinasse
Closes: https://bugs.gentoo.org/960019
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 app-i18n/mozc/files/mozc-2.28.5029.102-cxx20.patch | 23 ++++++++++++++++++++++
 app-i18n/mozc/mozc-2.28.5029.102-r5.ebuild         | 17 ++++++++--------
 2 files changed, 32 insertions(+), 8 deletions(-)

diff --git a/app-i18n/mozc/files/mozc-2.28.5029.102-cxx20.patch 
b/app-i18n/mozc/files/mozc-2.28.5029.102-cxx20.patch
new file mode 100644
index 000000000000..e8bb1f04b8df
--- /dev/null
+++ b/app-i18n/mozc/files/mozc-2.28.5029.102-cxx20.patch
@@ -0,0 +1,23 @@
+Gentoo-bug: https://bugs.gentoo.org/960019
+Thanks-to: Guillaume Lespinasse
+
+--- a/src/gyp/common.gypi
++++ b/src/gyp/common.gypi
+@@ -219,7 +219,7 @@
+           }],
+           ['compiler_target=="clang" or compiler_target=="gcc"', {
+             'cflags_cc': [
+-              '-std=c++17',
++              '-std=c++20',
+             ],
+           }],
+         ],
+@@ -239,7 +239,7 @@
+           }],
+           ['compiler_host=="clang" or compiler_host=="gcc"', {
+             'cflags_cc': [
+-              '-std=c++17',
++              '-std=c++20',
+             ],
+           }],
+         ],

diff --git a/app-i18n/mozc/mozc-2.28.5029.102-r5.ebuild 
b/app-i18n/mozc/mozc-2.28.5029.102-r5.ebuild
index 416bb547677b..d2f662e41434 100644
--- a/app-i18n/mozc/mozc-2.28.5029.102-r5.ebuild
+++ b/app-i18n/mozc/mozc-2.28.5029.102-r5.ebuild
@@ -121,12 +121,13 @@ S="${WORKDIR}/${P}/src"
 SITEFILE="50${PN}-gentoo.el"
 
 PATCHES=(
-       "${WORKDIR}"/mozc-2.28.5029.102-patches
-       "${FILESDIR}"/mozc-2.28.5029.102-abseil.patch
-       "${FILESDIR}"/mozc-2.28.5029.102-abseil-20230802.0.patch
-       "${FILESDIR}"/mozc-2.28.5029.102-abseil-20240116.patch
-       "${FILESDIR}"/mozc-2.28.5029.102-abseil-20250127.patch
-       "${FILESDIR}"/mozc-2.28.5029.102-abseil-20250512.patch
+       "${WORKDIR}/${P}-patches"
+       "${FILESDIR}/${P}-abseil.patch"
+       "${FILESDIR}/${P}-abseil-20230802.0.patch"
+       "${FILESDIR}/${P}-abseil-20240116.patch"
+       "${FILESDIR}/${P}-abseil-20250127.patch"
+       "${FILESDIR}/${P}-abseil-20250512.patch"
+       "${FILESDIR}/${P}-cxx20.patch" # bug 960019
 )
 
 python_check_deps() {
@@ -147,7 +148,7 @@ src_unpack() {
                unpack ${PN}-${PV%%_p*}-${MOZC_DATE}.tar.gz
                mv mozc-${MOZC_GIT_REVISION} ${P} || die
 
-               unpack ${PN}-2.28.5029.102-patches.tar.xz
+               unpack ${P}-patches.tar.xz
 
                unpack 
japanese-usage-dictionary-${JAPANESE_USAGE_DICTIONARY_DATE}.tar.gz
                cp -p 
japanese-usage-dictionary-${JAPANESE_USAGE_DICTIONARY_GIT_REVISION}/usage_dict.txt
 ${P}/src/third_party/japanese_usage_dictionary || die
@@ -163,7 +164,7 @@ src_unpack() {
 src_prepare() {
        if use fcitx5; then
                cp -pr "${WORKDIR}/fcitx5-mozc/src/unix/fcitx5" unix || die
-               PATCHES+=( 
"${FILESDIR}"/mozc-2.28.5029.102-abseil-20230802.0-fcitx5.patch )
+               PATCHES+=( "${FILESDIR}/${P}-abseil-20230802.0-fcitx5.patch" )
        fi
 
        pushd "${WORKDIR}/${P}" > /dev/null || die

Reply via email to