diff --git a/check-version.sh b/check-version.sh index 5b30873..6286111 100644 --- a/check-version.sh +++ b/check-version.sh @@ -9,4 +9,7 @@ TAG_NAME=$(curl -s -L -H "X-GitHub-Api-Version: 2022-11-28" -H "Authorization: t # Trim 'v' character in TAG_NAME variable VERSION=$(echo "$TAG_NAME" | tr -d 'v') +# Replace '-' with 'p' +VERSION=${VERSION//-/p} + echo "$VERSION" diff --git a/info.yml b/info.yml index 134bf75..f1c16ac 100644 --- a/info.yml +++ b/info.yml @@ -1,7 +1,7 @@ name: python-rapidfuzz description: Rapid fuzzy string matching in Python using various string metrics -version: 3.14.5 -revision: 2 +version: 3.14.6p1 +revision: 1 url: https://github.com/rapidfuzz/RapidFuzz license: MIT maintainers: @@ -13,13 +13,15 @@ depends: - glibc - python3=3.14.* make_depends: + - git - python-build - python-cython - python-installer - python-scikit-build-core - rapidfuzz-cpp downloads: - - url: https://files.pythonhosted.org/packages/source/r/rapidfuzz/rapidfuzz-${BPM_PKG_VERSION}.tar.gz - extract_to: ${BPM_SOURCE} - extract_strip_components: 1 - checksum: ba10ac57884ce82112f7ed910b67e7fb6072d8ef2c06e30dc63c0f604a112e0e + - url: https://github.com/rapidfuzz/RapidFuzz.git + type: git + clone_to: ${BPM_SOURCE} + git_branch: v${BPM_PKG_VERSION//p/-} + checksum: 377d0c0ace35bbb4683180ebf110414dfff11abb diff --git a/recipe.sh b/recipe.sh index 9e8788b..70f11d0 100644 --- a/recipe.sh +++ b/recipe.sh @@ -2,6 +2,16 @@ # BPM Expects the source code to be extracted into the automatically created 'source' directory which can be accessed using $BPM_SOURCE # BPM Expects the output files to be present in the automatically created 'output' directory which can be accessed using $BPM_OUTPUT +# The prepare function is executed in the root of the temp directory +# This function is used for putting downloaded files to the correct location or applying patches +prepare() { + cd "$BPM_SOURCE" + + git submodule update --init --recursive + + git apply "$BPM_WORKDIR"/remove-version-constraints.patch +} + # The build function is executed in the source directory # This function is used to compile the source code build() { diff --git a/source-files/remove-version-constraints.patch b/source-files/remove-version-constraints.patch new file mode 100644 index 0000000..7fdf7b9 --- /dev/null +++ b/source-files/remove-version-constraints.patch @@ -0,0 +1,11 @@ +--- a/pyproject.toml ++++ b/pyproject.toml +@@ -1,7 +1,7 @@ + [build-system] + requires = [ + "scikit-build-core>=0.11", +- "Cython >=3.1.6, <3.3.0" ++ "Cython" + ] + build-backend = "scikit_build_core.build" +