From 5428a8e6d9d51169de571b5e3883dea3ca31c27e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Vo=C5=99=C3=AD=C5=A1ek?= Date: Thu, 12 Feb 2026 10:41:40 +0100 Subject: [PATCH] impl UCD download --- .../unicode-character-database.sh | 19 +++++++++++++++++++ .github/workflows/verify-bundled-files.yml | 13 +++++++++++++ 2 files changed, 32 insertions(+) create mode 100755 .github/scripts/download-bundled/unicode-character-database.sh diff --git a/.github/scripts/download-bundled/unicode-character-database.sh b/.github/scripts/download-bundled/unicode-character-database.sh new file mode 100755 index 000000000000..805c0495c636 --- /dev/null +++ b/.github/scripts/download-bundled/unicode-character-database.sh @@ -0,0 +1,19 @@ +#!/bin/sh +set -ex +cd "$(dirname "$0")/../../.." + +tmp_dir=/tmp/php-src-download-bundled/unicode-character-database +rm -rf "$tmp_dir" + +version=17.0.0 + +mkdir -p "$tmp_dir" +curl --fail "https://www.unicode.org/Public/$version/ucd/UCD.zip" -o "$tmp_dir/data.zip" +unzip "$tmp_dir/data.zip" -d "$tmp_dir" + +cd ext/mbstring + +rm libmbfl/mbfl/eaw_table.h +rm unicode_data.h + +./ucgendat/ucgendat.php "$tmp_dir" diff --git a/.github/workflows/verify-bundled-files.yml b/.github/workflows/verify-bundled-files.yml index 473d6e2d8f4d..96a4e24d2940 100644 --- a/.github/workflows/verify-bundled-files.yml +++ b/.github/workflows/verify-bundled-files.yml @@ -5,6 +5,7 @@ on: paths: &paths - '.github/scripts/download-bundled/**' - 'Zend/asm/**' + - 'ext/mbstring/**' - 'ext/pcre/pcre2lib/**' - 'ext/uri/uriparser/**' pull_request: @@ -34,6 +35,9 @@ jobs: 'boost-context': - '.github/scripts/download-bundled/boost-context.*' - 'Zend/asm/**' + 'unicode-character-database': + - '.github/scripts/download-bundled/unicode-character-database.*' + - 'ext/mbstring/**' pcre2: - '.github/scripts/download-bundled/pcre2.*' - 'ext/pcre/pcre2lib/**' @@ -50,6 +54,15 @@ jobs: echo "::group::Verify files" .github/scripts/test-directory-unchanged.sh Zend/asm echo "::endgroup::" + - name: 'Unicode Character Database' + if: ${{ !cancelled() && (steps.changes.outputs.unicode-character-database == 'true' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') }} + run: | + echo "::group::Download" + .github/scripts/download-bundled/unicode-character-database.sh + echo "::endgroup::" + echo "::group::Verify files" + .github/scripts/test-directory-unchanged.sh 'ext/mbstring' + echo "::endgroup::" - name: PCRE2 if: ${{ !cancelled() && (steps.changes.outputs.pcre2 == 'true' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') }} run: |