diff --git a/.github/workflows/compare.yml b/.github/workflows/compare.yml index b5c1430..e841c5a 100644 --- a/.github/workflows/compare.yml +++ b/.github/workflows/compare.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Download artifact - uses: actions/download-artifact@v6 + uses: actions/download-artifact@v7 with: pattern: artifact-${{ inputs.platform }}* merge-multiple: true diff --git a/.github/workflows/debug.yml b/.github/workflows/debug.yml index 50d3f8b..d76fdda 100644 --- a/.github/workflows/debug.yml +++ b/.github/workflows/debug.yml @@ -35,7 +35,7 @@ jobs: DEBUG=1 python scripts/librime.py macos ${{ matrix.arch }} - name: Upload artifact - uses: actions/upload-artifact@v5 + uses: actions/upload-artifact@v6 with: name: artifact-librime-${{ matrix.arch }} path: | @@ -50,7 +50,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Download artifact - uses: actions/download-artifact@v6 + uses: actions/download-artifact@v7 with: pattern: artifact-librime* merge-multiple: true diff --git a/.github/workflows/harmony.yml b/.github/workflows/harmony.yml index 64c4a18..735756d 100644 --- a/.github/workflows/harmony.yml +++ b/.github/workflows/harmony.yml @@ -25,7 +25,7 @@ jobs: - name: Install dependencies run: | - sudo apt install -y ninja-build gettext + sudo apt update && sudo apt install -y ninja-build gettext pip install -r requirements.txt - name: Install OpenHarmony SDK @@ -42,7 +42,7 @@ jobs: run: python scripts/build.py harmony ${{ matrix.arch }} - name: Upload artifact - uses: actions/upload-artifact@v5 + uses: actions/upload-artifact@v6 with: name: artifact-harmony-${{ matrix.arch }} path: | @@ -68,7 +68,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Download artifact - uses: actions/download-artifact@v6 + uses: actions/download-artifact@v7 with: pattern: artifact-harmony* merge-multiple: true diff --git a/.github/workflows/ios.yml b/.github/workflows/ios.yml index e4a28da..602c472 100644 --- a/.github/workflows/ios.yml +++ b/.github/workflows/ios.yml @@ -53,7 +53,7 @@ jobs: run: python scripts/build.py ios ${{ matrix.platform }} - name: Upload artifact - uses: actions/upload-artifact@v5 + uses: actions/upload-artifact@v6 with: name: artifact-ios${{ matrix.postfix }} path: | @@ -79,7 +79,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Download artifact - uses: actions/download-artifact@v6 + uses: actions/download-artifact@v7 with: pattern: artifact-ios* merge-multiple: true diff --git a/.github/workflows/js.yml b/.github/workflows/js.yml index ee38e8f..3982321 100644 --- a/.github/workflows/js.yml +++ b/.github/workflows/js.yml @@ -36,7 +36,7 @@ jobs: - name: Install dependencies run: | - sudo apt install -y \ + sudo apt update && sudo apt install -y \ gettext autopoint valac pip install -r requirements.txt rustup target add wasm32-unknown-emscripten @@ -53,6 +53,7 @@ jobs: bison --version cmake --version valac --version + rustc --version - name: Build run: | @@ -60,7 +61,7 @@ jobs: python scripts/build.py js - name: Upload artifact - uses: actions/upload-artifact@v5 + uses: actions/upload-artifact@v6 with: name: artifact-js path: | diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index f8894a0..51e775c 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -52,12 +52,13 @@ jobs: clang --version cmake --version valac --version + rustc --version - name: Build run: python scripts/build.py macos ${{ matrix.arch }} - name: Upload artifact - uses: actions/upload-artifact@v5 + uses: actions/upload-artifact@v6 with: name: artifact-macos-${{ matrix.arch }} path: | @@ -83,7 +84,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Download artifact - uses: actions/download-artifact@v6 + uses: actions/download-artifact@v7 with: pattern: artifact-macos* merge-multiple: true diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 7d4663f..988ea34 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -34,7 +34,7 @@ jobs: run: python scripts/build.py windows ${{ matrix.platform }} - name: Upload artifact - uses: actions/upload-artifact@v5 + uses: actions/upload-artifact@v6 with: name: artifact-windows-${{ matrix.platform }} path: | @@ -61,7 +61,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Download artifact - uses: actions/download-artifact@v6 + uses: actions/download-artifact@v7 with: pattern: artifact-windows* merge-multiple: true diff --git a/libpinyin b/libpinyin index a9b614f..eea3ec4 160000 --- a/libpinyin +++ b/libpinyin @@ -1 +1 @@ -Subproject commit a9b614ff26b7216bef5695b8f50960a459b62d1a +Subproject commit eea3ec45f5fb685fd9d10a4125f7b91887bc3a56 diff --git a/patches/libpinyin.patch b/patches/libpinyin.patch index 8a897bc..90e7feb 100644 --- a/patches/libpinyin.patch +++ b/patches/libpinyin.patch @@ -1,29 +1,7 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index 4f62a9f..0942e6b 100644 +index aac36dfe..0942e6b5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -15,7 +15,7 @@ - ## Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - - ######## Project settings --cmake_minimum_required(VERSION 2.8) -+cmake_minimum_required(VERSION 3.5) - set (PACKAGE_NAME libpinyin) - project (${PACKAGE_NAME} CXX C) - enable_testing() -@@ -24,9 +24,9 @@ enable_testing() - set (PACKAGE_URL https://github.com/libpinyin/libpinyin) - set (PACKAGE_BUGREPORT https://github.com/libpinyin/libpinyin/issues) - set (LIBPINYIN_VERSION_MAJOR 2) --set (LIBPINYIN_VERSION_MINOR 1) --set (LIBPINYIN_VERSION_REVISION 0) --set (LIBPINYIN_BINARY_VERSION 13.0) -+set (LIBPINYIN_VERSION_MINOR 11) -+set (LIBPINYIN_VERSION_REVISION 91) -+set (LIBPINYIN_BINARY_VERSION 15.0) - - if (CMAKE_BUILD_TYPE MATCHES Debug) - set (version_suffix .Debug) @@ -79,14 +79,12 @@ endif (DB_FOUND) if (NOT HAVE_BERKELEY_DB) # DBM: Kyoto Cabinet @@ -68,7 +46,7 @@ index 4f62a9f..0942e6b 100644 -add_subdirectory(utils) -add_subdirectory(data) diff --git a/libzhuyin.pc.in b/libzhuyin.pc.in -index f248d1c..0e6b944 100644 +index f248d1c0..0e6b944f 100644 --- a/libzhuyin.pc.in +++ b/libzhuyin.pc.in @@ -11,5 +11,5 @@ Name: libzhuyin @@ -79,7 +57,7 @@ index f248d1c..0e6b944 100644 +Libs: -L${libdir} -lpinyin Cflags: -I${libzhuyinincludedir} diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index fe16a66..f8a496f 100644 +index fe16a668..f8a496fe 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -10,8 +10,8 @@ set( @@ -101,7 +79,7 @@ index fe16a66..f8a496f 100644 ${DIR_INCLUDE_LIBPINYIN} ) diff --git a/src/lookup/CMakeLists.txt b/src/lookup/CMakeLists.txt -index 767748c..77da8b1 100644 +index 767748c2..77da8b1c 100644 --- a/src/lookup/CMakeLists.txt +++ b/src/lookup/CMakeLists.txt @@ -12,7 +12,7 @@ set( @@ -114,7 +92,7 @@ index 767748c..77da8b1 100644 ) diff --git a/src/storage/CMakeLists.txt b/src/storage/CMakeLists.txt -index 26330e0..da215d7 100644 +index 26330e0f..da215d76 100644 --- a/src/storage/CMakeLists.txt +++ b/src/storage/CMakeLists.txt @@ -45,7 +45,7 @@ endif (HAVE_KYOTO_CABINET) @@ -135,7 +113,7 @@ index 26330e0..da215d7 100644 ${DIR_INCLUDE_LIBPINYIN} ) diff --git a/src/zhuyin.cpp b/src/zhuyin.cpp -index 1aeecf5..a4d868b 100644 +index 1aeecf58..a4d868b8 100644 --- a/src/zhuyin.cpp +++ b/src/zhuyin.cpp @@ -1127,7 +1127,7 @@ static gint compare_item_with_token(gconstpointer lhs, diff --git a/scripts/common.py b/scripts/common.py index 35a4445..1758792 100644 --- a/scripts/common.py +++ b/scripts/common.py @@ -361,6 +361,8 @@ def configure(self): command = './configure' if PLATFORM == 'js': command = f'emconfigure {command}' + if not os.path.exists('configure'): + ensure('autoreconf', ['-i']) ensure(command, [ '-C', f'--prefix={INSTALL_PREFIX}', diff --git a/scripts/libgee.py b/scripts/libgee.py index d65fcfb..90ce433 100644 --- a/scripts/libgee.py +++ b/scripts/libgee.py @@ -1,16 +1,7 @@ -import os - -from common import MakeBuilder, ensure, patch +from common import MakeBuilder, patch project = 'libgee' patch(project) -class LibgeeBuilder(MakeBuilder): - def configure(self): - if not os.path.exists('configure'): - os.environ['NOCONFIGURE'] = '1' - ensure('./autogen.sh', []) - super().configure() - -LibgeeBuilder(project).exec() +MakeBuilder(project).exec() diff --git a/scripts/libkkc.py b/scripts/libkkc.py index f77c301..54a999c 100644 --- a/scripts/libkkc.py +++ b/scripts/libkkc.py @@ -14,10 +14,4 @@ # valac uses it to locate gee-0.8.vapi os.environ['XDG_DATA_DIRS'] = XDG_DATA_DIRS -class LibkkcBuilder(MakeBuilder): - def configure(self): - if not os.path.exists('configure'): - ensure('autoreconf', ['-i']) - super().configure() - -LibkkcBuilder(project).exec() +MakeBuilder(project).exec() diff --git a/scripts/libskk.py b/scripts/libskk.py index d43c4ae..18e190f 100644 --- a/scripts/libskk.py +++ b/scripts/libskk.py @@ -1,6 +1,6 @@ import os -from common import MakeBuilder, XDG_DATA_DIRS, ensure, patch +from common import MakeBuilder, XDG_DATA_DIRS, patch project = 'libskk' @@ -10,10 +10,4 @@ # valac uses it to locate gee-0.8.vapi os.environ['XDG_DATA_DIRS'] = XDG_DATA_DIRS -class LibSkkBuilder(MakeBuilder): - def configure(self): - if not os.path.exists('configure'): - ensure('autoreconf', ['-i']) - super().configure() - -LibSkkBuilder(project, ['--disable-docs']).exec() +MakeBuilder(project, ['--disable-docs']).exec()