Libre Japanese Input is a WIP restoration and continuation of the standalone Google Japanese Input/mozc app which has been discontinued in favor of the monolithic gBoard app which requires an internet connection. Unfortunately, its most recent, several-year old build has become increasingly incompatible with recent devices and versions of Android, motivating the creation of this project.
This project is not affiliated with Google.
- Software text entry. Kana input and henkan work.
- Lots of layout issues. Keyboard key text sizes are either too small or too big in some places. Occasional tofus rendered.
- Included emoji/emoticon sets are outdated. Emoji and symbol history are not saved.
- Cannot import or export user dictionaries.
- Hardware keyboard input needs testing.
First, ensure you have initialized all submodules.
git submodule update --init --recursive
The Libre Japanese Input dev environment is provided as a Nix flake and is very easy to build with Nix.
nix develop
./gradlew installDebug
The best way to do this is via the Docker setup described in the mozc
repo.
Libre Japanese Input depends on the exact revision
ddd9730b068387631e3b4d212314ef0ed93befe0
. Specific instructions are provided
below.
# Clone and setup Libre Japanese Input.
git clone https://github.com/elizagamedev/android-libre-japanese-input.git
cd android-libre-japanese-input
git submodule update --init --recursive
# Create Docker image.
cd third_party/mozc/docker/ubuntu22.04
docker build --rm --tag mozc_ubuntu22.04 .
docker create --interactive --tty --name mozc_build mozc_ubuntu22.04
# Build everything.
docker start mozc_build
docker exec -it mozc_build bash
# Check out the exact version of mozc that LJI uses.
git checkout ddd9730b068387631e3b4d212314ef0ed93befe0
git submodule deinit -f .
git submodule update --init --recursive
bazel build package --config oss_android -c opt
bazel build //data_manager/oss:mozc_dataset_for_oss --config linux
exit
# Extract artifacts.
cd ../../../../app/src/main
docker cp mozc_build:/home/mozc_builder/work/mozc/src/bazel-bin/android/jni/native_libs.zip .
docker cp mozc_build:/home/mozc_builder/work/mozc/src/bazel-bin/data_manager/oss/mozc.data assets
ln -s jniLibs lib
unzip native_libs.zip
rm -f lib native_libs.zip
# Clean up Docker.
docker stop mozc_build
docker rm mozc_build
docker image rm mozc_ubuntu22.04