This is a preparation before removing the dependency on Docker from our
Android build instructions (#1181).
With this commit running the 'update_deps.py' also downloads Android NDK
for macOS and Linux then extract it under third_party/ndk/.
This would enable us to fully control which version of Android NDK
should be used to build Android Library ('libmozc.so') in a subsequent
commit.
At this moment only the observable difference is that the Android NDK
will be extracted under third_party/ndk/. There must be no difference
in the final artifact yet.
PiperOrigin-RevId: 728118756
This follows up to my previous commit [1], which enabled build_qt.py to
build Qt6 for a CPU architecture other than the host architecture on
macOS environment.
Starting from Qt 6.8.0 it seems that Qt host tools need to be specified
via QT_HOST_PATH when running configure when cross compiling. To adopt
such a requirement, Qt6 will be built as follows with this commit.
1. Build Qt host tools first with statically linking to Qt libraries.
2. Build Qt for the target architecture with the above bootstrapping
Qt host tools.
3. Copy Qt host tools into third_party/qt/
Note that the above approach is not limited to macOS. In practice we can
now build Qt6 for non-host CPU architecture even on Windows.
There must be no behavior change in the final artifacts.
Closes#1121.
[1]: 2f68b502dd
PiperOrigin-RevId: 696781616
With this commit macOS build starts using Python virtual environment so
that our build steps can comply with PEP 668 [1].
This is only about the build procedure. There must be no behavior change
in the build artifacts.
#codehealth
[1]: https://peps.python.org/pep-0668/
PiperOrigin-RevId: 621123606
This is a preparation to enable C++20 for Windows (#769)
With this commit, Qt source code will be checked out into
src/third_party/qt_src
by updade_deps.py then build_qt.py will install Qt binaries (and debug
symbols) into
src/third_party/qt.
This way we can later delete src/third_party/qt_src to free up disk
space by 2GB or so, which is enough for us to compensate the increase
of disk usage in *.lib and *.obj when /std:c++20 is specified.
There must be no user observable behavior change.
PiperOrigin-RevId: 548523226
Currently `updade_deps.py` doesn't have any local cache mechanism, meaning that it downloads required files every time it is triggered. This is not only inefficient but also problematic because it can trigger rate limit if a developer (or CI) triggers `updade_deps.py` multiple times in a short period of time.
With this CL `updade_deps.py` starts using `src/third_party_cache/` as a cache directory.
The first run not only downloads archive files but also store downloaded files into `src/third_party_cache/`. Any further run simply use cache files under `src/third_party_cache/` instead of downloading the same files again.
There is no change in the actual build instructions. This is just an internal optimization behind the scene.
This is an important step towards enabling GitHub cache action (#749).
PiperOrigin-RevId: 536096666
This CL introduces `update_deps.py` as a helper script to set up OSS Mozc's build dependencies.
```
git clone https://github.com/google/mozc.git
cd mozc/src
python build_tools/update_deps.py
```
It the future we can probably rely on bazel (e.g. `http_archive`), but for now having this kind of script would be helpful, especially for cases like #722.
Here are what would happen by running this script.
* On all the platforms, `git submodule update --init --recursive` will be executed.
* On macOS, Qt will be extracted to `src/third_party/qt/`
* On Windows
- Qt will be extracted to `src/third_party/qt/`
- `jom.exe` will be extracted to `src/third_party/qt/`
- WiX will be extracted to `src/third_party/wix/`
This is also a preparation to support building installers for Windows (#723).
#codehealth
PiperOrigin-RevId: 525514758