git: 19cbb11ea491 - main - japanese/*mozc3*: New port: Mozc Japanese Input Method ver 3.x

From: Kousuke Kannagi <mce_at_FreeBSD.org>
Date: Sat, 17 Oct 2026 10:03:43 UTC
The branch main has been updated by mce:

URL: https://cgit.FreeBSD.org/ports/commit/?id=19cbb11ea49150c9c2394566efd127beec65ca0b

commit 19cbb11ea49150c9c2394566efd127beec65ca0b
Author:     Kousuke Kannagi <mce@FreeBSD.org>
AuthorDate: 2026-10-17 09:37:52 +0000
Commit:     Kousuke Kannagi <mce@FreeBSD.org>
CommitDate: 2026-10-17 10:02:38 +0000

    japanese/*mozc3*: New port: Mozc Japanese Input Method ver 3.x
    
    PR:             295074
    Approved by:    osa, fluffy (mentors, implicit)
---
 japanese/Makefile                                  |   6 +
 japanese/fcitx5-mozc3/Makefile                     |  11 +
 japanese/ibus-mozc3/Makefile                       |  11 +
 japanese/mozc-server/Makefile                      |   8 +
 japanese/mozc3-el/Makefile                         |  10 +
 japanese/mozc3-el/pkg-message                      |  12 +
 japanese/mozc3-server/Makefile                     | 618 +++++++++++++++++++++
 japanese/mozc3-server/Makefile.MASTER_SITES        |  82 +++
 ....jawiki_latest_pages_articles_multistream_index |   2 +
 japanese/mozc3-server/distinfo                     | 115 ++++
 .../files/extra-patch-merge_dictionaries.py        | 163 ++++++
 ...ra-patch-rules__buf+_buf_internal_toolchain.bzl |  75 +++
 .../extra-patch-rules__go+_go_private_sdk.bzl      |  40 ++
 ...tra-patch-rules__rust+_rust_platform_triple.bzl |  21 +
 .../files/extra-patch-src_MODULE.bazel             |  16 +
 .../files/extra-patch-src_data_symbol_symbol.tsv   |  10 +
 .../files/extra-patch-src_unix_emacs_mozc.el       |  39 ++
 .../files/extra-patch-src_unix_uim_BUILD.bazel     |  94 ++++
 .../extra-patch-src_unix_uim_key__translator.cc    |  56 ++
 .../extra-patch-src_unix_uim_key__translator.h     |  34 ++
 .../files/extra-patch-src_unix_uim_mozc.cc         |  73 +++
 japanese/mozc3-server/files/leim-list.el           |  28 +
 japanese/mozc3-server/files/mozc.in                |  75 +++
 japanese/mozc3-server/files/mozc_tool.in           |  18 +
 japanese/mozc3-server/files/patch-src_MODULE.bazel | 118 ++++
 .../files/patch-src_base_init__mozc.cc             |  21 +
 .../patch-src_bazel_pkg__config__repository.bzl    |  46 ++
 .../files/patch-src_build__tools_util.py           |  11 +
 .../mozc3-server/files/patch-src_ipc_BUILD.bazel   |  12 +
 .../files/patch-src_ipc_ipc__path__manager.cc      |  73 +++
 .../mozc3-server/files/patch-src_ipc_unix__ipc.cc  |  73 +++
 .../mozc3-server/files/patch-src_unix_BUILD.bazel  |  25 +
 japanese/mozc3-server/files/pkg-message            |   9 +
 japanese/mozc3-server/pkg-descr                    |   3 +
 japanese/mozc3-tool/Makefile                       |   9 +
 japanese/uim-mozc3/Makefile                        |  12 +
 japanese/uim-mozc3/files/pkg-message.in            |  15 +
 37 files changed, 2044 insertions(+)

diff --git a/japanese/Makefile b/japanese/Makefile
index bc1fbe8dade3..de6f08e8eafb 100644
--- a/japanese/Makefile
+++ b/japanese/Makefile
@@ -54,6 +54,7 @@
     SUBDIR += fcitx5-cskk
     SUBDIR += fcitx5-hazkey
     SUBDIR += fcitx5-karukan
+    SUBDIR += fcitx5-mozc3
     SUBDIR += fcitx5-skk
     SUBDIR += flower-fpw
     SUBDIR += foldoc-fpw
@@ -129,6 +130,7 @@
     SUBDIR += hns
     SUBDIR += ibus-anthy
     SUBDIR += ibus-mozc
+    SUBDIR += ibus-mozc3
     SUBDIR += ibus-skk
     SUBDIR += icanna
     SUBDIR += ipadic
@@ -175,9 +177,12 @@
     SUBDIR += migemo.el
     SUBDIR += mime_pls
     SUBDIR += mozc-el
+    SUBDIR += mozc3-el
     SUBDIR += mozc-modeless
     SUBDIR += mozc-server
+    SUBDIR += mozc3-server
     SUBDIR += mozc-tool
+    SUBDIR += mozc3-tool
     SUBDIR += multiskkserv
     SUBDIR += mypaedia-fpw-package
     SUBDIR += namazu2
@@ -282,6 +287,7 @@
     SUBDIR += tomoe
     SUBDIR += uim-anthy-unicode
     SUBDIR += uim-mozc
+    SUBDIR += uim-mozc3
     SUBDIR += uim-tomoe-gtk
     SUBDIR += unidic-to-mozc
     SUBDIR += vera-fpw
diff --git a/japanese/fcitx5-mozc3/Makefile b/japanese/fcitx5-mozc3/Makefile
new file mode 100644
index 000000000000..a1db9d626b3d
--- /dev/null
+++ b/japanese/fcitx5-mozc3/Makefile
@@ -0,0 +1,11 @@
+PKGNAMEPREFIX=	ja-fcitx5-
+
+COMMENT=	Mozc engine for Fcitx5
+
+DATADIR=	${PREFIX}/share/fcitx5/${PORTNAME}
+
+MASTERDIR=	${.CURDIR}/../../japanese/mozc3-server
+
+BUILD_MOZC_LIST=	fcitx5_mozc
+
+.include "${MASTERDIR}/Makefile"
diff --git a/japanese/ibus-mozc3/Makefile b/japanese/ibus-mozc3/Makefile
new file mode 100644
index 000000000000..2b8a31fb7625
--- /dev/null
+++ b/japanese/ibus-mozc3/Makefile
@@ -0,0 +1,11 @@
+PKGNAMEPREFIX=	ja-ibus-
+
+COMMENT=	Mozc engine for IBus
+
+DATADIR=	${PREFIX}/share/ibus-${PORTNAME}
+
+MASTERDIR=	${.CURDIR}/../../japanese/mozc3-server
+
+BUILD_MOZC_LIST=	ibus_mozc
+
+.include "${MASTERDIR}/Makefile"
diff --git a/japanese/mozc-server/Makefile b/japanese/mozc-server/Makefile
index 599817606b44..0ed19a6e7c01 100644
--- a/japanese/mozc-server/Makefile
+++ b/japanese/mozc-server/Makefile
@@ -35,6 +35,8 @@ BUILD_MOZC_LIST?=	mozc_server
 PKGNAMEPREFIX=	ja-
 PKGNAMESUFFIX=	-server
 
+CONFLICTS_INSTALL=	ja-mozc3-server
+
 LICENSE=		BSD3CLAUSE NAISTL
 LICENSE_COMB=		multi
 LICENSE_FILE_BSD3CLAUSE=	${WRKSRC}/LICENSE
@@ -48,12 +50,14 @@ USES+=		qt:6 gnome
 USE_GNOME=	glib20 gtk20
 USE_QT=		base tools:build
 EXTRA_PATCHES=	${PATCHDIR}/qt6
+CONFLICTS_INSTALL=	ja-mozc3-tool
 .elif ${BUILD_MOZC_LIST:Mibus_mozc} == "ibus_mozc"
 USES+=		gettext-runtime gnome xorg
 USE_XORG=	xcb
 USE_GNOME=	cairo gdkpixbuf glib20 gtk20
 LIB_DEPENDS+=	libfontconfig.so:x11-fonts/fontconfig \
 		libfreetype.so:print/freetype2
+CONFLICTS_INSTALL=	ja-ibus-mozc3
 .elif ${BUILD_MOZC_LIST:Mmozc_el} == "mozc_el"
 USES+=		emacs
 .elif ${BUILD_MOZC_LIST:Mfcitx_mozc}
@@ -267,6 +271,8 @@ LIB_DEPENDS+=	libuim.so:textproc/uim
 RUN_DEPENDS+=	mozc_server:japanese/mozc-server \
 		mozc_tool:japanese/mozc-tool
 
+CONFLICTS_INSTALL=	ja-uim-mozc3
+
 EXTRA_PATCHES=	${PATCHDIR}/extra-patch-src-unix-uim-mozc.cc \
 		${PATCHDIR}/extra-patch-src-unix-uim-uim.gyp \
 		${PATCHDIR}/extra-patch-src-unix-uim-key_translator.h \
@@ -377,6 +383,8 @@ do-install-fcitx_mozc:
 CATEGORIES+=	elisp
 RUN_DEPENDS+=	mozc_server:japanese/mozc-server
 
+CONFLICTS_INSTALL=	ja-mozc3-el
+
 NO_ARCH=	yes
 PLIST_FILES+=	${EMACS_SITE_LISPDIR}/mozc/mozc.el.gz \
 		${EMACS_SITE_LISPDIR}/mozc/leim-list.el
diff --git a/japanese/mozc3-el/Makefile b/japanese/mozc3-el/Makefile
new file mode 100644
index 000000000000..94a185e9b911
--- /dev/null
+++ b/japanese/mozc3-el/Makefile
@@ -0,0 +1,10 @@
+PKGNAMESUFFIX=	-el
+
+COMMENT=	Emacs input method for Mozc
+
+MASTERDIR=	${.CURDIR}/../../japanese/mozc3-server
+PKGMESSAGE=	${.CURDIR}/pkg-message
+
+BUILD_MOZC_LIST=mozc_el
+
+.include "${MASTERDIR}/Makefile"
diff --git a/japanese/mozc3-el/pkg-message b/japanese/mozc3-el/pkg-message
new file mode 100644
index 000000000000..436907c15637
--- /dev/null
+++ b/japanese/mozc3-el/pkg-message
@@ -0,0 +1,12 @@
+[
+{ type: install
+  message: <<EOM
+To activate mozc, you will need to add the following lines to
+your Emacs configuration:
+
+(set-language-environment "Japanese")
+(setq default-input-method "japanese-mozc")
+(global-set-key (kbd "C-o") 'toggle-input-method)
+EOM
+}
+]
diff --git a/japanese/mozc3-server/Makefile b/japanese/mozc3-server/Makefile
new file mode 100644
index 000000000000..b2bf2c6dcbf2
--- /dev/null
+++ b/japanese/mozc3-server/Makefile
@@ -0,0 +1,618 @@
+PORTNAME=	mozc3
+DISTVERSION=	3.34.6345.102
+PORTREVISION?=	0
+CATEGORIES=	japanese
+MASTER_SITES=	https://github.com/bats-core/bats-core/archive/:bats_core
+DISTFILES=	v1.10.0.tar.gz:bats_core
+#MASTER_SITES+=	https://go.dev/dl/?mode=json&include=all&file=versions.json/:versions_json
+#DISTFILES+=	versions.json:versions_json
+
+.include "Makefile.MASTER_SITES"
+
+DIST_SUBDIR=	${PORTNAME}
+
+EXTRACT_ONLY=	${_DISTFILES:Mbazelbuild-*} \
+		${_DISTFILES:Me-kato-*} \
+		${_DISTFILES:Mfcitx-*} \
+		${_DISTFILES:Mhiroyuki-komatsu-*} \
+		${_DISTFILES:Mutuhiro78-*}
+
+MAINTAINER=	kdeguchi@sz.tokoha-u.ac.jp
+COMMENT?=	Mozc Japanese Input Method, Server
+WWW=		https://github.com/google/mozc
+
+LICENSE=		BSD3CLAUSE NAISTL
+LICENSE_COMB=		multi
+LICENSE_NAME_NAISTL=	Nara Institute of Science and Technology License
+LICENSE_FILE_BSD3CLAUSE=${WRKSRC}/LICENSE
+LICENSE_FILE_NAISTL=	${WRKSRC}/src/data/dictionary_oss/README.txt
+LICENSE_PERMS_NAISTL=	dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
+LICENSE_DISTFILES_BSD3CLAUSE=	${DISTNAME}${EXTRACT_SUFX}
+LICENSE_DISTFILES_NAISTL=	${DISTNAME}${EXTRACT_SUFX}
+
+BUILD_DEPENDS=	bash:shells/bash \
+		bazel:devel/bazel9
+RUN_DEPENDS=	xdg-open:devel/xdg-utils
+
+USES=	compiler:c++20-lang gmake java:build localbase pkgconfig \
+	python:patch,build shebangfix tar:bzip2
+
+USE_GITHUB=	yes
+GH_TUPLE=	fcitx:mozc:13ef96d
+GH_TUPLE+=	bazelbuild:bazel-central-registry:9d03419:bcr
+
+JAVA_VERSION=	21
+JAVA_VENDOR=	openjdk
+
+BINARY_ALIAS=	python3=${PYTHON_CMD}
+
+BUILD_MOZC_LIST?=	mozc_server
+
+BUILD_MOZC_CMD=	${SETENV} JAVA_HOME=${JAVA_HOME} \
+	bazel ${BAZEL_BOOT} build \
+		${BAZEL_COMMON_OPTS} \
+		--action_env=PATH=${JAVA_HOME}/bin:${PATH} \
+		--host_action_env=PATH=${JAVA_HOME}/bin:${PATH} \
+		--action_env=TMPDIR=${WRKDIR}/bazel_tmp \
+		--host_action_env=TMPDIR=${WRKDIR}/bazel_tmp \
+		-c opt --copt=-fPIC \
+		--cxxopt=-Wno-uninitialized \
+		--host_cxxopt=-Wno-uninitialized \
+		--linkopt=-lm --host_linkopt=-lm \
+		--jobs=${MAKE_JOBS_NUMBER} \
+		--java_language_version=${JAVA_PORT_VERSION} \
+		--tool_java_language_version=${JAVA_PORT_VERSION} \
+		--sandbox_debug \
+		--verbose_failures \
+		--config oss_linux \
+		--define server=1
+
+BAZEL_BCR_LOCAL=	${WRKSRC_bcr}
+
+BAZEL_BOOT=	--server_javabase=${JAVA_HOME} \
+		--output_base=${WRKDIR}/bazel_base \
+		--output_user_root=${WRKDIR}/bazel_user_root
+
+BAZEL_COMMON_OPTS=	--distdir=${DISTDIR}/${DIST_SUBDIR} \
+		--registry="file://${BAZEL_BCR_LOCAL}"
+
+BAZEL_WRKSRC=	${WRKSRC}/src
+
+.if ${BUILD_MOZC_LIST:Mmozc_server} == "mozc_server"
+
+CONFLICTS_INSTALL=	ja-mozc-server-*
+
+PKGNAMESUFFIX=	-server
+PKGMESSAGE=	${FILESDIR}/pkg-message
+
+# zip code
+GH_TUPLE+=	hiroyuki-komatsu:japanpost_zipcode:77f10d9:zipcode/src/japanpost_zipcode
+
+# usage dictionary
+GH_TUPLE+=	hiroyuki-komatsu:japanese-usage-dictionary:38d3462:udic/src/japanese_usage_dictionary
+
+OPTIONS_DEFINE=	ADDTILDE
+OPTIONS_GROUP=	UTDIC
+OPTIONS_GROUP_UTDIC=	ALTCANNADIC EDICT2 JAWIKI NEOLOGD PERSONALNAME \
+		PLACENAME SKKJISYO SUDACHIDICT
+OPTIONS_DEFAULT=	JAWIKI PERSONALNAME PLACENAME SUDACHIDICT
+
+ADDTILDE_DESC=	Add FULLWIDTH TILDE
+ADDTILDE_EXTRA_PATCHES=	${PATCHDIR}/extra-patch-src_data_symbol_symbol.tsv
+
+ALTCANNADIC_DESC=	Dictionary from Alt-Cannadic
+EDICT2_DESC=		Dictionary from EDICT2
+JAWIKI_DESC=		Dictionary from Japanese Wikipedia
+NEOLOGD_DESC=		Dictionary from NEologd
+PERSONALNAME_DESC=	Personal Name Dictionary
+PLACENAME_DESC=		Place Name Dictionary
+SKKJISYO_DESC=		Dictionary from from SKK-JISYO
+SUDACHIDICT_DESC=	Dictionary from SudachiDict
+UTDIC_DESC=		Additional UT Dictionaries
+
+# GPLv2
+ALTCANNADIC_GH_TUPLE=	utuhiro78:mozcdic-ut-alt-cannadic:0e23741:altcannadic
+# CC-BY-SA-4.0
+EDICT2_GH_TUPLE=	utuhiro78:mozcdic-ut-edict2:8fe8f79:edict2
+JAWIKI_GH_TUPLE=	utuhiro78:mozcdic-ut-jawiki:57af6ad:jawiki
+# APACHE20
+NEOLOGD_GH_TUPLE=	utuhiro78:mozcdic-ut-neologd:e33ac4c:neologd
+# APACHE20
+PERSONALNAME_GH_TUPLE=	utuhiro78:mozcdic-ut-personal-names:b557dd4:personal
+# APACHE20
+PLACENAME_GH_TUPLE=	utuhiro78:mozcdic-ut-place-names:98cf8e9:place
+# APACHE20 GPLv2
+SKKJISYO_GH_TUPLE=	utuhiro78:mozcdic-ut-skk-jisyo:384ad92:skkjisyo
+# APACHE20
+SUDACHIDICT_GH_TUPLE=	utuhiro78:mozcdic-ut-sudachidict:c686771:sudachi
+
+.include "Makefile.jawiki_latest_pages_articles_multistream_index"
+
+.elif ${BUILD_MOZC_LIST:Mmozc_tool} == "mozc_tool"
+
+CONFLICTS_INSTALL=	ja-mozc-tool-*
+
+BUILD_DEPENDS+=	libglvnd>0:graphics/libglvnd
+RUN_DEPENDS+=	mozc:japanese/mozc3-server
+
+USES+=		qt:6
+USE_QT=		base
+
+.elif ${BUILD_MOZC_LIST:Mibus_mozc} == "ibus_mozc"
+
+CONFLICTS_INSTALL=	ja-ibus-mozc-*
+
+BUILD_DEPENDS+=	libglvnd>0:graphics/libglvnd
+LIB_DEPENDS+=	libibus-1.0.so:textproc/ibus
+RUN_DEPENDS+=	mozc:japanese/mozc3-server \
+		mozc_tool:japanese/mozc3-tool
+
+USES+=		gettext-runtime gnome qt:6
+USE_GNOME=	glib20
+USE_QT=		base
+
+.elif ${BUILD_MOZC_LIST:Muim_mozc} == "uim_mozc"
+
+CONFLICTS_INSTALL=	ja-uim-mozc-*
+
+LICENSE_FILE+=	${BAZEL_WRKSRC}/src/unix/uim/LICENSE
+
+LIB_DEPENDS+=	libuim.so:textproc/uim
+RUN_DEPENDS+=	mozc:japanese/mozc3-server \
+		mozc_tool:japanese/mozc3-tool
+
+.elif ${BUILD_MOZC_LIST:Mmozc_el} == "mozc_el"
+
+CONFLICTS_INSTALL=	ja-mozc-el-*
+
+CATEGORIES+=	elisp
+RUN_DEPENDS+=	mozc:japanese/mozc3-server
+
+USES+=		emacs:build
+
+.elif ${BUILD_MOZC_LIST:Mfcitx5_mozc}
+
+LIB_DEPENDS+=	libFcitx5Core.so:textproc/fcitx5
+RUN_DEPENDS+=	mozc:japanese/mozc3-server \
+		mozc_tool:japanese/mozc3-tool
+
+USES+=		gettext-tools
+
+.endif
+
+# Use GCC only when the stock clang does not have libc++.so.
+.if exists(/usr/bin/clang) && exists(/usr/lib/libc++.so)
+_CCTYPE=	clang
+.else
+USE_GCC=	yes
+_CCTYPE=	gcc
+.endif
+
+.include <bsd.port.pre.mk>
+
+post-patch:
+	@${FIND} ${BAZEL_WRKSRC} -type f \
+		\( -name 'BUILD' -o -name '*.bzl' -o -name '*.cc' -o -name '*.h' -o -name MODULE.bazel \) \
+		-exec ${REINPLACE_CMD} -E -e "s,'python','${PYTHON_CMD}',g;" \
+			-e 's,/usr/bin/xdg-open,${PREFIX}/bin/xdg-open,g;' \
+			-e 's,/usr/lib/mozc,${PREFIX}/libexec,g;' \
+			-e 's,LINUX_MOZC_SERVER_DIR \+ "/documents","${DATADIR}",g;' \
+			-e 's,/usr/lib/mozc/documents,${DATADIR},g;' \
+			-e 's,/usr/share,${PREFIX}/share,g;' \
+			-e 's,/usr/lib,${PREFIX}/lib,g;' \
+			-e 's,%%LOCALBASE%%,${LOCALBASE},g;' \
+			-e 's,OS=="linux",OS=="linux" or OS=="freebsd",g;' \
+			-e 's,target_platform=="Linux",target_platform=="Linux" or target_platform=="FreeBSD",g;' \
+			-e 's,defined\(__linux__\),defined(__linux__) || defined(__FreeBSD__),g;' \
+			-e 's,^#ifdef __linux__$$,#if defined(__linux__) || defined(__FreeBSD__),;' \
+			-e 's,^#ifdef __linux$$,#if defined(__linux__) || defined(__FreeBSD__),;' \
+			-e 's,ByteSize\(,ByteSizeLong\(,g;' {} \;
+	@${CP} ${PATCHDIR}/extra-patch-rules__buf+_buf_internal_toolchain.bzl \
+		${BAZEL_WRKSRC}/rules_buf.patch
+	@${CP} ${PATCHDIR}/extra-patch-rules__rust+_rust_platform_triple.bzl \
+		${BAZEL_WRKSRC}/rules_rust.patch
+	#@${CP} ${PATCHDIR}/extra-patch-rules__go+_go_private_sdk.bzl \
+		${BAZEL_WRKSRC}/rules_go.patch
+	#@${REINPLACE_CMD} -e 's@%%BAZEL_WRKSRC%%@${BAZEL_WRKSRC}@' ${BAZEL_WRKSRC}/rules_go.patch
+	#@${CP} ${DISTDIR}/${DIST_SUBDIR}/versions.json ${BAZEL_WRKSRC}
+
+.if ${BUILD_MOZC_LIST:Mfcitx5_mozc} == "fcitx5_mozc"
+	@${CP} ${BAZEL_WRKSRC}/unix/fcitx/gen_fcitx_mozc_i18n.sh ${BAZEL_WRKSRC}/unix/fcitx5/
+	@${REINPLACE_CMD} 's,/po/mo},%po}mo,g' \
+		${BAZEL_WRKSRC}/unix/fcitx5/gen_fcitx_mozc_i18n.sh
+.endif
+
+.if ${BUILD_MOZC_LIST:Mmozc_server} == "mozc_server" || make(makesum)
+
+PLIST_FILES+=	bin/mozc \
+		libexec/mozc_server
+SUB_FILES+=	mozc
+
+_UTDIC=	0
+.for utopt in ${OPTIONS_GROUP_UTDIC}
+. if ${PORT_OPTIONS:M${utopt}}
+_UTDIC=	1
+. endif
+.endfor
+
+.if ${_UTDIC} == 1
+GH_TUPLE+=	utuhiro78:merge-ut-dictionaries:6239884:ut
+MASTER_SITES+=	${UTDIC_MASTER_SITES}
+DISTFILES+=	${UTDIC_DISTFILES}
+.endif
+
+.if ${PORT_OPTIONS:MNEOLOGD} || ${PORT_OPTIONS:MPERSONALNAME} || \
+	${PORT_OPTIONS:MPLACENAME} || ${PORT_OPTIONS:MSUDACHIDICT}
+LICENSE+=	APACHE20
+LICENSE_DISTFILES_APACHE20=	${DISTFILES:M*\:ut:C@\:ut@@} \
+		${DISTFILES:M*\:neologd:C@\:neologd@@} \
+		${DISTFILES:M*\:personal:C@\:personal@@} \
+		${DISTFILES:M*\:place:C@\:place@@}
+.endif
+.if ${PORT_OPTIONS:MEDICT2} || ${PORT_OPTIONS:MJAWIKI}
+LICENSE+=	CC-BY-SA-4.0
+LICENSE_DISTFILES_CC-BY-SA-4.0=	${DISTFILES:M*\:edict2:C@\:edict2@@} \
+		${DISTFILES:M*\:jawiki:C@\:jawiki@@}
+.endif
+.if ${PORT_OPTIONS:MALTCANNADIC} || ${PORT_OPTIONS:MSKKJISYO}
+LICENSE+=	GPLv2
+LICENSE_DISTFILES_GPLv2=	${DISTFILES:M*\:altcannadic:C@\:altcannadic@@} \
+		${DISTFILES:M*\:skkjisyo:C@\:skkjisyo@@}
+.endif
+
+post-extract-mozc_server:
+	@cd ${WRKSRC_zipcode} && \
+		${UNZIP_NATIVE_CMD} -q jigyosyo.zip && \
+		${UNZIP_NATIVE_CMD} -q ken_all.zip
+
+post-patch-mozc_server:
+.if ${_UTDIC} == 1
+	@${ECHO_MSG} "===> Creating mozcdic-ut.txt for UT Dictionary. It takes a long time!"
+	@cd ${WRKSRC_ut}/src/merge && \
+		${PATCH} < ${PATCHDIR}/extra-patch-merge_dictionaries.py && \
+		${REINPLACE_CMD} -e 's@%%WRKSRC%%@${WRKSRC}@' merge_dictionaries.py && \
+		${RLN} ${BAZEL_WRKSRC}/data/dictionary_oss/id.def . && \
+		${CP} ${DISTDIR}/${DIST_SUBDIR}/${UTDIC_DISTFILES:M*\:jawiki_latest_pages_articles_multistream_index:C@\:jawiki_latest_pages_articles_multistream_index@@} jawiki-latest-pages-articles-multistream-index.txt.bz2 && \
+		${BZCAT} ../../../mozcdic-ut-*/mozcdic-ut-*.txt.bz2 > mozcdic-ut.txt && \
+		${PYTHON_CMD} merge_dictionaries.py mozcdic-ut.txt && \
+		${CAT} mozcdic-ut.txt \
+			>> ${BAZEL_WRKSRC}/data/dictionary_oss/dictionary00.txt
+.endif
+
+post-extract: post-extract-mozc_server
+
+post-patch: post-patch-mozc_server
+
+do-build-mozc_server:
+	cd ${BAZEL_WRKSRC} && \
+		${BUILD_MOZC_CMD} //server:mozc_server
+
+do-install-mozc_server:
+	${INSTALL_PROGRAM} \
+		${BAZEL_WRKSRC}/bazel-bin/server/mozc_server \
+		${STAGEDIR}${PREFIX}/libexec
+	${INSTALL_SCRIPT} \
+		${WRKDIR}/mozc ${STAGEDIR}/${PREFIX}/bin
+.endif
+
+.if ${BUILD_MOZC_LIST:Mmozc_tool} == "mozc_tool" || make(makesum)
+
+PLIST_FILES+=	libexec/mozc_tool \
+		bin/mozc_tool \
+		%%DATADIR%%/credits_en.html \
+		%%DATADIR%%/icons/product_logo.png \
+		%%DATADIR%%/icons/update_uptodate.png
+
+SUB_FILES+=	mozc_tool
+
+do-build-mozc_tool:
+	cd ${BAZEL_WRKSRC} && \
+		${BUILD_MOZC_CMD} //gui/tool:mozc_tool
+
+do-install-mozc_tool:
+	${INSTALL_PROGRAM} \
+		${BAZEL_WRKSRC}/bazel-out/freebsd-opt/bin/gui/tool/mozc_tool \
+		${STAGEDIR}${PREFIX}/libexec
+	${INSTALL_SCRIPT} ${WRKDIR}/mozc_tool ${STAGEDIR}${PREFIX}/bin
+	@${MKDIR} ${STAGEDIR}${DATADIR}/icons
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/unix/ime_product_icon_opensource-32.png \
+		${STAGEDIR}${DATADIR}/icons/product_logo.png
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/unix/ime_product_icon_opensource-32.png \
+		${STAGEDIR}${DATADIR}/icons/update_uptodate.png
+	${INSTALL_DATA} ${BAZEL_WRKSRC}/data/installer/credits_en.html \
+		${STAGEDIR}${DATADIR}
+.endif
+
+.if ${BUILD_MOZC_LIST:Mibus_mozc} == "ibus_mozc"
+
+PLIST_FILES+=	libexec/mozc_renderer \
+		libexec/ibus-engine-mozc \
+		%%DATADIR%%/alpha_full.png \
+		%%DATADIR%%/alpha_half.png \
+		%%DATADIR%%/dictionary.png \
+		%%DATADIR%%/direct.png \
+		%%DATADIR%%/hiragana.png \
+		%%DATADIR%%/katakana_full.png \
+		%%DATADIR%%/katakana_half.png \
+		%%DATADIR%%/product_icon.png \
+		%%DATADIR%%/properties.png \
+		%%DATADIR%%/tool.png \
+		share/ibus/component/mozc.xml
+PLIST_DIRS+=	${DATADIR_REL}
+
+post-patch-ibus_mozc:
+	${REINPLACE_CMD} -e 's@ ulong @ unsigned long @;' \
+		-e 's@ulong id@unsigned long id@;' -e 's@, ulong>@, unsigned long>@;' \
+		${BAZEL_WRKSRC}/unix/ibus/ibus_wrapper.*
+
+post-patch: post-patch-ibus_mozc
+
+do-build-ibus_mozc:
+	cd ${BAZEL_WRKSRC} && \
+		${BUILD_MOZC_CMD} //unix/ibus:ibus_mozc \
+			//unix/ibus:gen_mozc_xml \
+			//renderer/qt:mozc_renderer
+
+do-install-ibus_mozc:
+	${INSTALL_PROGRAM} \
+		${BAZEL_WRKSRC}/bazel-out/freebsd-opt/bin/renderer/qt/mozc_renderer \
+		${STAGEDIR}${PREFIX}/libexec/mozc_renderer
+	${INSTALL_PROGRAM} \
+		${BAZEL_WRKSRC}/bazel-out/freebsd-opt/bin/unix/ibus/ibus_mozc \
+		${STAGEDIR}${PREFIX}/libexec/ibus-engine-mozc
+	@${MKDIR} ${STAGEDIR}${PREFIX}/share/ibus/component
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/bazel-out/freebsd-opt/bin/unix/ibus/mozc.xml \
+		${STAGEDIR}${PREFIX}/share/ibus/component/mozc.xml
+	@${MKDIR} ${STAGEDIR}${DATADIR}
+.for F in ui-alpha_full ui-alpha_half ui-dictionary ui-direct \
+	ui-hiragana ui-katakana_full ui-katakana_half ui-properties ui-tool
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/unix/${F}.png \
+		${STAGEDIR}${DATADIR}/${F:S/^ui-//}.png
+.endfor
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/unix/ime_product_icon_opensource-32.png \
+		${STAGEDIR}${DATADIR}/product_icon.png
+.endif
+
+.if ${BUILD_MOZC_LIST:Muim_mozc} == "uim_mozc" || make(makesum)
+
+GH_TUPLE+=	e-kato:macuim:7beac7b:MU
+
+# These patches are from https://github.com/femshima/uim-mozc
+# Modified to support the latest mozc.
+EXTRA_PATCHES=	${PATCHDIR}/extra-patch-src_MODULE.bazel \
+		${PATCHDIR}/extra-patch-src_unix_uim_BUILD.bazel \
+		${PATCHDIR}/extra-patch-src_unix_uim_key__translator.cc \
+		${PATCHDIR}/extra-patch-src_unix_uim_key__translator.h \
+		${PATCHDIR}/extra-patch-src_unix_uim_mozc.cc
+
+PLIST_FILES+=	lib/uim/plugin/libuim-mozc.so \
+		%%DATADIR%%/mozc.scm \
+		%%DATADIR%%/mozc-custom.scm \
+		%%DATADIR%%/mozc-key-custom.scm \
+		%%DATADIR%%/pixmaps/mozc.png \
+		%%DATADIR%%/pixmaps/mozc_tool_config_dialog.png \
+		%%DATADIR%%/pixmaps/mozc_tool_dictionary_tool.png \
+		%%DATADIR%%/pixmaps/mozc_tool_selector.png \
+		"@postexec ${SETENV} MOZC_NOLOG=true ${LOCALBASE}/bin/uim-module-manager --register mozc" \
+		"@preunexec ${LOCALBASE}/bin/uim-module-manager --unregister mozc"
+
+post-extract-uim_mozc:
+	${RLN} ${WRKSRC_MU}/Mozc/uim ${BAZEL_WRKSRC}/unix
+
+post-extract: post-extract-uim_mozc
+
+post-patch-uim_mozc:
+	${REINPLACE_CMD} -e "s,/usr/lib/mozc,${LOCALBASE}/libexec," \
+		${WRKSRC_MU}/Mozc/scm/mozc-custom.scm
+	${REINPLACE_CMD} -e "s,SWITCH_INPUT_MODE,SWITCH_COMPOSITION_MODE,g" \
+		${BAZEL_WRKSRC}/unix/uim/mozc.cc
+	${HEAD} --lines 32 ${BAZEL_WRKSRC}/unix/uim/mozc.cc > ${BAZEL_WRKSRC}/unix/uim/LICENSE
+
+post-patch: post-patch-uim_mozc
+
+do-build-uim_mozc:
+	cd ${BAZEL_WRKSRC}&& \
+		${BUILD_MOZC_CMD} //unix/uim:uim-mozc
+
+do-install-uim_mozc:
+	@${MKDIR} ${STAGEDIR}${PREFIX}/lib/uim/plugin
+	${INSTALL_LIB} \
+		${BAZEL_WRKSRC}/bazel-out/freebsd-opt/bin/unix/uim/libuim-mozc.so \
+		${STAGEDIR}${PREFIX}/lib/uim/plugin
+	@${MKDIR} ${STAGEDIR}${DATADIR}
+	cd ${WRKSRC_MU}/Mozc/scm && \
+		${INSTALL_DATA} mozc.scm mozc-custom.scm mozc-key-custom.scm \
+		${STAGEDIR}${DATADIR}
+	@${MKDIR} ${STAGEDIR}${DATADIR}/pixmaps
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/product_icon_32bpp-128.png \
+		${STAGEDIR}${DATADIR}/pixmaps/mozc.png
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/unix/ui-properties.png \
+		${STAGEDIR}${DATADIR}/pixmaps/mozc_tool_config_dialog.png
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/unix/ui-dictionary.png \
+		${STAGEDIR}${DATADIR}/pixmaps/mozc_tool_dictionary_tool.png
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/unix/ui-tool.png \
+		${STAGEDIR}${DATADIR}/pixmaps/mozc_tool_selector.png
+.endif
+
+.if ${BUILD_MOZC_LIST:Mfcitx5_mozc} == "fcitx5_mozc" || make(makesum)
+
+PLIST_FILES+=	lib/fcitx5/fcitx5-mozc.so \
+		share/fcitx5/addon/mozc.conf \
+		share/fcitx5/inputmethod/mozc.conf \
+		share/icons/hicolor/128x128/apps/fcitx_mozc.png \
+		share/icons/hicolor/32x32/apps/fcitx_mozc.png \
+		share/icons/hicolor/48x48/apps/fcitx_mozc_alpha_full.png \
+		share/icons/hicolor/48x48/apps/fcitx_mozc_alpha_half.png \
+		share/icons/hicolor/48x48/apps/fcitx_mozc_direct.png \
+		share/icons/hicolor/48x48/apps/fcitx_mozc_hiragana.png \
+		share/icons/hicolor/48x48/apps/fcitx_mozc_katakana_full.png \
+		share/icons/hicolor/48x48/apps/fcitx_mozc_katakana_half.png \
+		share/icons/hicolor/48x48/apps/fcitx_mozc_dictionary.png \
+		share/icons/hicolor/48x48/apps/fcitx_mozc_properties.png \
+		share/icons/hicolor/48x48/apps/fcitx_mozc_tool.png \
+		share/locale/ca/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/da/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/de/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/fr/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/he/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/ja/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/ka/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/ko/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/ru/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/sv/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/tr/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/vi/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/zh_CN/LC_MESSAGES/fcitx5-mozc.mo \
+		share/locale/zh_TW/LC_MESSAGES/fcitx5-mozc.mo \
+		share/metainfo/org.fcitx.Fcitx5.Addon.Mozc.metainfo.xml
+
+do-build-fcitx5_mozc:
+	cd ${BAZEL_WRKSRC} && \
+		${BUILD_MOZC_CMD} //unix/fcitx5:fcitx5-mozc.so; \
+		msgfmt --xml -d unix/fcitx5/po/ \
+			--template unix/fcitx5/org.fcitx.Fcitx5.Addon.Mozc.metainfo.xml.in \
+			-o unix/fcitx5/org.fcitx.Fcitx5.Addon.Mozc.metainfo.xml
+	cd ${BAZEL_WRKSRC}/unix/fcitx5 && ${SH} gen_fcitx_mozc_i18n.sh ./po
+
+do-install-fcitx5_mozc:
+	@${MKDIR} ${STAGEDIR}${PREFIX}/lib/fcitx5 \
+		${STAGEDIR}${PREFIX}/share/fcitx5/addon \
+		${STAGEDIR}${PREFIX}/share/fcitx5/inputmethod \
+		${STAGEDIR}${PREFIX}/share/icons/hicolor/128x128/apps \
+		${STAGEDIR}${PREFIX}/share/icons/hicolor/32x32/apps \
+		${STAGEDIR}${PREFIX}/share/icons/hicolor/48x48/apps \
+		${STAGEDIR}${PREFIX}/share/metainfo
+	${INSTALL_PROGRAM} \
+		${BAZEL_WRKSRC}/bazel-out/freebsd-opt/bin/unix/fcitx5/fcitx5-mozc.so \
+			${STAGEDIR}${PREFIX}/lib/fcitx5
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/unix/fcitx5/mozc-addon.conf \
+			${STAGEDIR}${PREFIX}/share/fcitx5/addon/mozc.conf
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/unix/fcitx5/mozc.conf \
+			${STAGEDIR}${PREFIX}/share/fcitx5/inputmethod/mozc.conf
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/product_icon_32bpp-128.png \
+			${STAGEDIR}${PREFIX}/share/icons/hicolor/128x128/apps/fcitx_mozc.png
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/data/images/unix/ime_product_icon_opensource-32.png \
+			${STAGEDIR}${PREFIX}/share/icons/hicolor/32x32/apps/fcitx_mozc.png
+.for F in ui-alpha_full ui-alpha_half ui-dictionary ui-direct \
+	ui-hiragana ui-katakana_full ui-katakana_half ui-properties ui-tool
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/../scripts/icons/${F}.png \
+			${STAGEDIR}${PREFIX}/share/icons/hicolor/48x48/apps/${F:S,^ui-,fcitx_mozc_,}.png
+.endfor
+	cd ${BAZEL_WRKSRC} && \
+		for mofile in unix/fcitx5/po/*.mo; do \
+			locale=$${mofile##*/}; \
+			locale=$${locale%.mo}; \
+			${INSTALL_DATA} ${BAZEL_WRKSRC}/$${mofile} \
+				${STAGEDIR}${PREFIX}/share/locale/$${locale}/LC_MESSAGES/fcitx5-mozc.mo; \
+		done
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/unix/fcitx5/org.fcitx.Fcitx5.Addon.Mozc.metainfo.xml \
+			${STAGEDIR}${PREFIX}/share/metainfo
+.endif #fcitx5_mozc
+
+.if ${BUILD_MOZC_LIST:Mmozc_el} == "mozc_el" || make(makesum)
+
+EXTRA_PATCHES=	${PATCHDIR}/extra-patch-src_unix_emacs_mozc.el
+
+PLIST_FILES+=	${EMACS_SITE_LISPDIR}/mozc/mozc.el.gz \
+		${EMACS_SITE_LISPDIR}/mozc/leim-list.el \
+		libexec/mozc_emacs_helper
+PLIST_DIRS+=	${EMACS_SITE_LISPDIR}/mozc
+
+post-patch-mozc_el:
+	${REINPLACE_CMD} "s,%%PREFIX%%,${PREFIX}," \
+		${BAZEL_WRKSRC}/unix/emacs/mozc.el
+
+post-patch: post-patch-mozc_el
+
+do-build-mozc_el:
+	cd ${BAZEL_WRKSRC} && \
+		${BUILD_MOZC_CMD} //unix/emacs:mozc_emacs_helper
+	cd ${BAZEL_WRKSRC}/unix/emacs && ${GZIP_CMD} mozc.el
+
+do-install-mozc_el:
+	@${MKDIR} ${STAGEDIR}${PREFIX}/${EMACS_SITE_LISPDIR}/mozc
+	${INSTALL_PROGRAM} \
+		${BAZEL_WRKSRC}/bazel-out/freebsd-opt/bin/unix/emacs/mozc_emacs_helper \
+		${STAGEDIR}${PREFIX}/libexec
+	${INSTALL_DATA} \
+		${BAZEL_WRKSRC}/unix/emacs/mozc.el.gz \
+		${FILESDIR}/leim-list.el \
+		${STAGEDIR}${PREFIX}/${EMACS_SITE_LISPDIR}/mozc/
+
+.endif
+
+pre-build:
+	@${MKDIR} ${WRKDIR}/bazel_tmp
+
+do-build: ${BUILD_MOZC_LIST:S/^/do-build-/}
+do-install: ${BUILD_MOZC_LIST:S/^/do-install-/}
+
+post-build:
+	cd ${BAZEL_WRKSRC} && bazel ${BAZEL_BOOT} shutdown
+
+bazel-mod: configure
+	@cd ${BAZEL_WRKSRC} && \
+		bazel ${BAZEL_BOOT} mod graph \
+			--output text --charset ascii \
+			${BAZEL_COMMON_OPTS} | \
+		${SED} -E 's/[^[:alnum:]]+//;s/ .*//;' | \
+		${GREP} '@[0-9]' | ${SORT} -u
+
+bazel-modules: configure
+	@cd ${BAZEL_WRKSRC} && \
+		bazel ${BAZEL_BOOT} mod show_repo \
+			$$( bazel ${BAZEL_BOOT} mod graph \
+					--output text --charset ascii \
+					${BAZEL_COMMON_OPTS} | \
+				${SED} -E 's/[^[:alnum:]]+//;s/ .*//;' | \
+				${GREP} '@[0-9]' | ${SORT} -u ) \
+			--output text --charset ascii \
+			${BAZEL_COMMON_OPTS} | \
+		${AWK} ' / name = / \
+			{ name=$$0; sub(/.* name = "/, "", name); sub(/\+*",/, "", name); gsub(/[-.]/, "_", name); } \
+			/ urls = / \
+			{ url=$$0; sub(/.* urls = \["/, "", url); sub(/"\],/, "", url); \
+				file=url; sub(/.*\//, "", file); sub(/\/[^\/]+$$/, "/", url); \
+			printf("MASTER_SITES+=\t%s:%s\nDISTFILES+=\t%s:%s\n", url, name, file, name); \
+			} ' > ${MASTERDIR}/Makefile.MASTER_SITES
+
+print-bazel-modules: configure
+	cd ${BAZEL_WRKSRC} && \
+		bazel ${BAZEL_BOOT} mod show_repo \
+			$$( bazel ${BAZEL_BOOT} mod graph \
+			--output text --charset ascii \
+			${BAZEL_COMMON_OPTS} | \
+		${SED} -E 's/[^[:alnum:]]+//;s/ .*//;' | \
+		${GREP} '@[0-9]' | ${SORT} -u) \
+			--output text --charset ascii \
+			${BAZEL_COMMON_OPTS}
+
+update-jawiki:
+	@${FETCH_CMD} -q \
+		https://dumps.wikimedia.org/jawiki/latest/jawiki-latest-pages-articles-multistream-index.txt.bz2-rss.xml -o - | \
+		${AWK} ' / href="/ \
+			{ sub(/.* href="/,""); sub(/".*/, ""); \
+			url=$$0; file=$$0; sub(/\/[^\/]+$$/, "/", url); sub(/.*\//, "", file); \
+			printf("UTDIC_MASTER_SITES+=\t%s:jawiki_latest_pages_articles_multistream_index\nUTDIC_DISTFILES+=\t%s:jawiki_latest_pages_articles_multistream_index\n", url, file); \
+			} ' > ${MASTERDIR}/Makefile.jawiki_latest_pages_articles_multistream_index
+
+renew-makesum:
+	@${MAKE} makesum bazel-modules update-jawiki
+	@${MAKE} makesum
+
+.include <bsd.port.post.mk>
diff --git a/japanese/mozc3-server/Makefile.MASTER_SITES b/japanese/mozc3-server/Makefile.MASTER_SITES
new file mode 100644
index 000000000000..c34f64fb244e
--- /dev/null
+++ b/japanese/mozc3-server/Makefile.MASTER_SITES
@@ -0,0 +1,82 @@
+MASTER_SITES+=	https://github.com/abseil/abseil-cpp/releases/download/20260107.1/:abseil_cpp
+DISTFILES+=	abseil-cpp-20260107.1.tar.gz:abseil_cpp
+MASTER_SITES+=	https://github.com/abseil/abseil-py/archive/refs/tags/:abseil_py
+DISTFILES+=	v2.1.0.tar.gz:abseil_py
+MASTER_SITES+=	https://github.com/bazelbuild/apple_support/releases/download/2.5.2/:apple_support
+DISTFILES+=	apple_support.2.5.2.tar.gz:apple_support
+MASTER_SITES+=	https://github.com/bazel-contrib/bazel-lib/releases/download/v2.22.5/:aspect_bazel_lib
+DISTFILES+=	bazel-lib-v2.22.5.tar.gz:aspect_bazel_lib
+MASTER_SITES+=	https://github.com/bazel-contrib/bazel_features/releases/download/v1.42.1/:bazel_features
+DISTFILES+=	bazel_features-v1.42.1.tar.gz:bazel_features
+MASTER_SITES+=	https://github.com/bazel-contrib/bazel-lib/releases/download/v3.0.0/:bazel_lib
+DISTFILES+=	bazel-lib-v3.0.0.tar.gz:bazel_lib
+MASTER_SITES+=	https://github.com/bazelbuild/bazel-skylib/releases/download/1.9.0/:bazel_skylib
+DISTFILES+=	bazel-skylib-1.9.0.tar.gz:bazel_skylib
+MASTER_SITES+=	https://github.com/bazelbuild/bazel-worker-api/releases/download/v0.0.8/:bazel_worker_api
+DISTFILES+=	bazel-worker-api-v0.0.8.tar.gz:bazel_worker_api
+MASTER_SITES+=	https://ftp.gnu.org/gnu/gawk/:gawk
+DISTFILES+=	gawk-5.3.2.tar.xz:gawk
+MASTER_SITES+=	https://github.com/bazel-contrib/bazel-gazelle/releases/download/v0.48.0/:gazelle
+DISTFILES+=	bazel-gazelle-v0.48.0.tar.gz:gazelle
+MASTER_SITES+=	https://github.com/google/benchmark/archive/refs/tags/:google_benchmark
+DISTFILES+=	v1.9.5.tar.gz:google_benchmark
+MASTER_SITES+=	https://github.com/google/googletest/releases/download/v1.17.0/:googletest
+DISTFILES+=	googletest-1.17.0.tar.gz:googletest
+MASTER_SITES+=	https://github.com/bazel-contrib/jq.bzl/releases/download/v0.1.0/:jq_bzl
+DISTFILES+=	jq.bzl-v0.1.0.tar.gz:jq_bzl
+MASTER_SITES+=	https://github.com/open-source-parsers/jsoncpp/archive/refs/tags/:jsoncpp
+DISTFILES+=	1.9.6.tar.gz:jsoncpp
+MASTER_SITES+=	https://twds.dl.sourceforge.net/project/perfmon2/libpfm4/:libpfm
+DISTFILES+=	libpfm-4.11.0.tar.gz:libpfm
+MASTER_SITES+=	https://github.com/nlohmann/json/releases/download/v3.12.0/:nlohmann_json
+DISTFILES+=	include.zip:nlohmann_json
+MASTER_SITES+=	https://github.com/bazel-contrib/supply-chain/releases/download/v0.0.5/:package_metadata
+DISTFILES+=	supply-chain-v0.0.5.tar.gz:package_metadata
+MASTER_SITES+=	https://github.com/bazelbuild/platforms/releases/download/1.0.0/:platforms
+DISTFILES+=	platforms-1.0.0.tar.gz:platforms
+MASTER_SITES+=	https://github.com/protocolbuffers/protobuf/releases/download/v34.1/:protobuf
+DISTFILES+=	protobuf-34.1.bazel.tar.gz:protobuf
+MASTER_SITES+=	https://github.com/pybind/pybind11_bazel/releases/download/v2.13.6/:pybind11_bazel
+DISTFILES+=	pybind11_bazel-2.13.6.tar.gz:pybind11_bazel
+MASTER_SITES+=	https://github.com/google/re2/releases/download/2025-08-12/:re2
+DISTFILES+=	re2-2025-08-12.zip:re2
+MASTER_SITES+=	https://github.com/bazelbuild/rules_android/releases/download/v0.7.1/:rules_android
+DISTFILES+=	rules_android-v0.7.1.tar.gz:rules_android
+MASTER_SITES+=	https://github.com/bazelbuild/rules_android_ndk/releases/download/v0.1.5/:rules_android_ndk
+DISTFILES+=	rules_android_ndk-v0.1.5.tar.gz:rules_android_ndk
+MASTER_SITES+=	https://github.com/bazelbuild/rules_apple/releases/download/4.5.2/:rules_apple
+DISTFILES+=	rules_apple.4.5.2.tar.gz:rules_apple
+MASTER_SITES+=	https://github.com/bazelbuild/rules_cc/releases/download/0.2.17/:rules_cc
+DISTFILES+=	rules_cc-0.2.17.tar.gz:rules_cc
+MASTER_SITES+=	https://github.com/bazel-contrib/rules_go/releases/download/v0.60.0/:rules_go
+DISTFILES+=	rules_go-v0.60.0.zip:rules_go
+MASTER_SITES+=	https://github.com/bazelbuild/rules_java/releases/download/9.3.0/:rules_java
+DISTFILES+=	rules_java-9.3.0.tar.gz:rules_java
+MASTER_SITES+=	https://github.com/bazel-contrib/rules_jvm_external/releases/download/6.9/:rules_jvm_external
+DISTFILES+=	rules_jvm_external-6.9.tar.gz:rules_jvm_external
+MASTER_SITES+=	https://github.com/bazelbuild/rules_kotlin/releases/download/v2.2.2/:rules_kotlin
+DISTFILES+=	rules_kotlin-v2.2.2.tar.gz:rules_kotlin
+MASTER_SITES+=	https://github.com/bazelbuild/rules_license/releases/download/1.0.0/:rules_license
+DISTFILES+=	rules_license-1.0.0.tar.gz:rules_license
+MASTER_SITES+=	https://github.com/bazelbuild/rules_pkg/releases/download/1.2.0/:rules_pkg
+DISTFILES+=	rules_pkg-1.2.0.tar.gz:rules_pkg
+MASTER_SITES+=	https://github.com/bazelbuild/rules_proto/releases/download/7.1.0/:rules_proto
+DISTFILES+=	rules_proto-7.1.0.tar.gz:rules_proto
+MASTER_SITES+=	https://github.com/bazel-contrib/rules_python/releases/download/1.9.0/:rules_python
+DISTFILES+=	rules_python-1.9.0.tar.gz:rules_python
+MASTER_SITES+=	https://github.com/robolectric/robolectric-bazel/releases/download/4.14.1.2/:rules_robolectric
+DISTFILES+=	robolectric-bazel-4.14.1.2.tar.gz:rules_robolectric
+MASTER_SITES+=	https://github.com/bazelbuild/rules_shell/releases/download/v0.6.1/:rules_shell
+DISTFILES+=	rules_shell-v0.6.1.tar.gz:rules_shell
+MASTER_SITES+=	https://github.com/bazelbuild/rules_swift/releases/download/3.5.0/:rules_swift
+DISTFILES+=	rules_swift.3.5.0.tar.gz:rules_swift
+MASTER_SITES+=	https://github.com/bazelbuild/stardoc/releases/download/0.7.2/:stardoc
+DISTFILES+=	stardoc-0.7.2.tar.gz:stardoc
+MASTER_SITES+=	https://github.com/apple/swift-argument-parser/archive/refs/tags/:swift_argument_parser
+DISTFILES+=	1.3.1.tar.gz:swift_argument_parser
+MASTER_SITES+=	https://github.com/bazel-contrib/tar.bzl/releases/download/v0.5.1/:tar_bzl
+DISTFILES+=	tar.bzl-v0.5.1.tar.gz:tar_bzl
+MASTER_SITES+=	https://github.com/bazel-contrib/yq.bzl/releases/download/v0.1.1/:yq_bzl
+DISTFILES+=	yq.bzl-v0.1.1.tar.gz:yq_bzl
+MASTER_SITES+=	https://github.com/madler/zlib/releases/download/v1.3.1/:zlib
+DISTFILES+=	zlib-1.3.1.tar.gz:zlib
diff --git a/japanese/mozc3-server/Makefile.jawiki_latest_pages_articles_multistream_index b/japanese/mozc3-server/Makefile.jawiki_latest_pages_articles_multistream_index
new file mode 100644
index 000000000000..0b5e245a535e
--- /dev/null
+++ b/japanese/mozc3-server/Makefile.jawiki_latest_pages_articles_multistream_index
@@ -0,0 +1,2 @@
+UTDIC_MASTER_SITES+=	http://download.wikimedia.org/jawiki/20261001/:jawiki_latest_pages_articles_multistream_index
+UTDIC_DISTFILES+=	jawiki-20261001-pages-articles-multistream-index.txt.bz2:jawiki_latest_pages_articles_multistream_index
diff --git a/japanese/mozc3-server/distinfo b/japanese/mozc3-server/distinfo
new file mode 100644
index 000000000000..39050ad37626
--- /dev/null
+++ b/japanese/mozc3-server/distinfo
@@ -0,0 +1,115 @@
+TIMESTAMP = 1792101078
+SHA256 (mozc3/v1.10.0.tar.gz) = a1a9f7875aa4b6a9480ca384d5865f1ccf1b0b1faead6b47aa47d79709a5c5fd
+SIZE (mozc3/v1.10.0.tar.gz) = 159353
+SHA256 (mozc3/abseil-cpp-20260107.1.tar.gz) = 4314e2a7cbac89cac25a2f2322870f343d81579756ceff7f431803c2c9090195
+SIZE (mozc3/abseil-cpp-20260107.1.tar.gz) = 2301097
+SHA256 (mozc3/v2.1.0.tar.gz) = 8a3d0830e4eb4f66c4fa907c06edf6ce1c719ced811a12e26d9d3162f8471758
+SIZE (mozc3/v2.1.0.tar.gz) = 235261
+SHA256 (mozc3/apple_support.2.5.2.tar.gz) = ce4fc3e360c151af7c142da190abd4cfb49ca90aa833291d136afa05e94ba4ea
+SIZE (mozc3/apple_support.2.5.2.tar.gz) = 116707
+SHA256 (mozc3/bazel-lib-v2.22.5.tar.gz) = 94e192033ca8027f26de71c9000a67ef9c73695c2b88e2c559045170917ead0c
+SIZE (mozc3/bazel-lib-v2.22.5.tar.gz) = 167962
+SHA256 (mozc3/bazel_features-v1.42.1.tar.gz) = 8189bac9a6bf9cc155a854c4cbebfebf58b9ca7a2d0a67645f7d0c1f83c523ac
+SIZE (mozc3/bazel_features-v1.42.1.tar.gz) = 18078
+SHA256 (mozc3/bazel-lib-v3.0.0.tar.gz) = 6fd3b1e1a38ca744f9664be4627ced80895c7d2ee353891c172f1ab61309c933
+SIZE (mozc3/bazel-lib-v3.0.0.tar.gz) = 112873
+SHA256 (mozc3/bazel-skylib-1.9.0.tar.gz) = 3b5b49006181f5f8ff626ef8ddceaa95e9bb8ad294f7b5d7b11ea9f7ddaf8c59
+SIZE (mozc3/bazel-skylib-1.9.0.tar.gz) = 44790
+SHA256 (mozc3/bazel-worker-api-v0.0.8.tar.gz) = a58c8c1e53aec7d66498168b0525bfd87add4d3cfd18e3ed03d5bed929dd68fc
+SIZE (mozc3/bazel-worker-api-v0.0.8.tar.gz) = 30813
+SHA256 (mozc3/gawk-5.3.2.tar.xz) = f8c3486509de705192138b00ef2c00bbbdd0e84c30d5c07d23fc73a9dc4cc9cc
+SIZE (mozc3/gawk-5.3.2.tar.xz) = 3749260
+SHA256 (mozc3/bazel-gazelle-v0.48.0.tar.gz) = 6549aff70998217292406776024d6da91b4e764c679d180ea072c557c70dacf2
+SIZE (mozc3/bazel-gazelle-v0.48.0.tar.gz) = 2256849
+SHA256 (mozc3/v1.9.5.tar.gz) = 9631341c82bac4a288bef951f8b26b41f69021794184ece969f8473977eaa340
+SIZE (mozc3/v1.9.5.tar.gz) = 267155
+SHA256 (mozc3/googletest-1.17.0.tar.gz) = 65fab701d9829d38cb77c14acdc431d2108bfdbf8979e40eb8ae567edf10b27c
+SIZE (mozc3/googletest-1.17.0.tar.gz) = 885595
+SHA256 (mozc3/jq.bzl-v0.1.0.tar.gz) = 7b63435aa19cc6a0cfd1a82fbdf2c7a2f0a94db1a79ff7a4469ffa94286261ab
+SIZE (mozc3/jq.bzl-v0.1.0.tar.gz) = 44874
+SHA256 (mozc3/1.9.6.tar.gz) = f93b6dd7ce796b13d02c108bc9f79812245a82e577581c4c9aabe57075c90ea2
+SIZE (mozc3/1.9.6.tar.gz) = 212682
+SHA256 (mozc3/libpfm-4.11.0.tar.gz) = 5da5f8872bde14b3634c9688d980f68bda28b510268723cc12973eedbab9fecc
+SIZE (mozc3/libpfm-4.11.0.tar.gz) = 1043686
+SHA256 (mozc3/include.zip) = b8cb0ef2dd7f57f18933997c9934bb1fa962594f701cd5a8d3c2c80541559372
+SIZE (mozc3/include.zip) = 309160
+SHA256 (mozc3/supply-chain-v0.0.5.tar.gz) = 49ed11e5d6b752c55fa539cbb10b2736974f347b081d7bd500a80dacb7dbec06
+SIZE (mozc3/supply-chain-v0.0.5.tar.gz) = 38614
+SHA256 (mozc3/platforms-1.0.0.tar.gz) = 3384eb1c30762704fbe38e440204e114154086c8fc8a8c2e3e28441028c019a8
+SIZE (mozc3/platforms-1.0.0.tar.gz) = 7879
+SHA256 (mozc3/protobuf-34.1.bazel.tar.gz) = 9f0933ad12abb0a8957b3b64aefc34774ccbe57f77f890c66cb4067519bb83c1
+SIZE (mozc3/protobuf-34.1.bazel.tar.gz) = 7038508
+SHA256 (mozc3/pybind11_bazel-2.13.6.tar.gz) = cae680670bfa6e82703c03f2a3c995408cdcbf43616d7bdd198ef45d3c327731
+SIZE (mozc3/pybind11_bazel-2.13.6.tar.gz) = 6156
+SHA256 (mozc3/re2-2025-08-12.zip) = 817a073d6cbb1bc6fb91a4267375998a361437470d11bd27dea6f00d5b963990
+SIZE (mozc3/re2-2025-08-12.zip) = 457821
+SHA256 (mozc3/rules_android-v0.7.1.tar.gz) = 7c45b6aaa837fb6f2f23ad11387638cb00fa9f839a04ec564caac70a543a9cd5
+SIZE (mozc3/rules_android-v0.7.1.tar.gz) = 1308711
+SHA256 (mozc3/rules_android_ndk-v0.1.5.tar.gz) = 07e7a2777113bb3d0a432265d1c78cfaa140a5bc4c82be4c8cd988b34382ec90
+SIZE (mozc3/rules_android_ndk-v0.1.5.tar.gz) = 25604
+SHA256 (mozc3/rules_apple.4.5.2.tar.gz) = bdac384944a8a7b555f403e10fecb25de6096ff340722e090847bfb562c0ce89
+SIZE (mozc3/rules_apple.4.5.2.tar.gz) = 2481952
+SHA256 (mozc3/rules_cc-0.2.17.tar.gz) = 283fa1cdaaf172337898749cf4b9b1ef5ea269da59540954e51fba0e7b8f277a
*** 1394 LINES SKIPPED ***