diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8e6e51195..e0630f4a8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,7 +16,7 @@ jobs: build: strategy: matrix: - os: [ubuntu-latest, windows-latest, macos-latest] + os: [ubuntu-latest, windows-latest, macos-latest, macos-14] preset: - rust-release - rust-with-sqlite-release @@ -30,7 +30,7 @@ jobs: - if: ${{ matrix.os == 'ubuntu-latest' }} run: sudo apt-get install ninja-build - - if: ${{ matrix.os == 'macos-latest' }} + - if: ${{ matrix.os == 'macos-latest' || matrix.os == 'macos-14' }} run: brew install ninja - if: ${{ matrix.os == 'windows-latest' }} run: choco install ninja diff --git a/NEWS b/NEWS index ab14bffd6..d1a6df0c9 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,9 @@ +What's New in libchewing 0.8.1 (May 15, 2024) +--------------------------------------------------------- + +* Buf fixed + - Fail to build on aarch64 due to type mismatch. (introduced in v0.8.0) + What's New in libchewing 0.8.0 (May 14, 2024) --------------------------------------------------------- diff --git a/capi/src/io.rs b/capi/src/io.rs index 7cbcaacec..db5706621 100644 --- a/capi/src/io.rs +++ b/capi/src/io.rs @@ -89,7 +89,7 @@ unsafe fn slice_from_ptr_with_nul<'a>(ptr: *const c_char) -> Option<&'a [c_char] unsafe fn str_from_ptr_with_nul<'a>(ptr: *const c_char) -> Option<&'a str> { unsafe { slice_from_ptr_with_nul(ptr) } - .and_then(|data| str::from_utf8(unsafe { mem::transmute::<&[i8], &[u8]>(data) }).ok()) + .and_then(|data| str::from_utf8(unsafe { mem::transmute::<&[c_char], &[u8]>(data) }).ok()) } #[no_mangle] diff --git a/tests/testhelper/src/path.rs b/tests/testhelper/src/path.rs index ed413961e..b94e044b7 100644 --- a/tests/testhelper/src/path.rs +++ b/tests/testhelper/src/path.rs @@ -83,7 +83,7 @@ pub unsafe extern "C" fn find_path_by_files( -1 } -unsafe fn files_ptr_to_slice(files: *const *const i8) -> Vec> { +unsafe fn files_ptr_to_slice(files: *const *const c_char) -> Vec> { let len = { let mut i = 0; while unsafe { !files.add(i).read().is_null() } {