From 80d8a92931f8e47324302d490b26c38d4fae91ee Mon Sep 17 00:00:00 2001 From: shivansh-ibm Date: Mon, 7 Sep 2026 02:41:05 -0700 Subject: [PATCH 1/4] Added build script for utf8proc==2.11.3 for ubi 10.2 --- u/utf8proc/build_info.json | 9 ++- u/utf8proc/pyproject.toml | 4 +- u/utf8proc/utf8proc_ubi_10.2.sh | 116 ++++++++++++++++++++++++++++++++ 3 files changed, 124 insertions(+), 5 deletions(-) create mode 100644 u/utf8proc/utf8proc_ubi_10.2.sh diff --git a/u/utf8proc/build_info.json b/u/utf8proc/build_info.json index 52e1178043..3b97d62028 100644 --- a/u/utf8proc/build_info.json +++ b/u/utf8proc/build_info.json @@ -1,8 +1,8 @@ { - "maintainer": "kiranNukal", + "maintainer": "shivansh-ibm", "package_name": "utf8proc", "github_url": "https://github.com/JuliaStrings/utf8proc", - "version": "v2.6.1", + "version": "v2.11.3", "wheel_build" : true, "default_branch": "main", "package_dir": "u/utf8proc", @@ -11,6 +11,9 @@ "validate_build_script": true, "use_non_root_user": false, "*": { - "build_script": "utf8proc_ubi_9.3.sh" + "build_script": [ + "utf8proc_ubi_9.3.sh", + "utf8proc_ubi_10.2.sh" + ] } } diff --git a/u/utf8proc/pyproject.toml b/u/utf8proc/pyproject.toml index 012651a981..f134ec56b8 100644 --- a/u/utf8proc/pyproject.toml +++ b/u/utf8proc/pyproject.toml @@ -36,8 +36,8 @@ where = ["local"] #Package data to add bazel in wheel, this is needed as its not a .py file [tool.setuptools.package-data] -utf8proc = ["lib/*", "include/*"] +utf8proc = ["lib/*", "lib64/*", "include/*"] [tool.distutils.bdist_wheel] plat-name = "linux_ppc64le" # Explicitly set the platform tag -universal = false # Disable universal wheel (forces platform-specific build) \ No newline at end of file +universal = false # Disable universal wheel (forces platform-specific build) diff --git a/u/utf8proc/utf8proc_ubi_10.2.sh b/u/utf8proc/utf8proc_ubi_10.2.sh new file mode 100644 index 0000000000..6e2ebfada1 --- /dev/null +++ b/u/utf8proc/utf8proc_ubi_10.2.sh @@ -0,0 +1,116 @@ +#!/bin/bash -e +# ----------------------------------------------------------------------------- +# +# Package : utf8proc +# Version : 2.11.3 +# Source repo : https://github.com/JuliaStrings/utf8proc.git +# Tested on : UBI:10.2 +# Language : Python +# Ci-Check : True +# Script License: Apache License, Version 2 or later +# Maintainer : Shivansh Sharma +# +# Disclaimer: This script has been tested in root mode on the given +# platform using the mentioned version of the package. +# It may not work as expected with newer versions of the +# package and/or distribution. In such a case, please +# contact the "Maintainer" of this script. +# +# ----------------------------------------------------------------------------- + +# Exit immediately if a command exits with a non-zero status +set -e + +# Variables +PACKAGE_NAME=utf8proc +PACKAGE_VERSION=${1:-v2.11.3} +PACKAGE_URL=https://github.com/JuliaStrings/utf8proc.git +PACKAGE_DIR=utf8proc +WORK_DIR=$(pwd) + +# Install dependencies and tools +yum install -y wget git cmake python3.14-devel python3.14-pip +yum install gcc-toolset-15 gcc-toolset-15-gcc gcc-toolset-15-gcc-c++ -y + +# --------------------------------------------------------------------------- +# Activate GCC Toolset 15 (SCL removed in UBI 10 — use PATH export) +# --------------------------------------------------------------------------- +if [[ -f /opt/rh/gcc-toolset-15/enable ]]; then + source /opt/rh/gcc-toolset-15/enable +elif [[ -d /opt/rh/gcc-toolset-15/root/usr/bin ]]; then + export PATH="/opt/rh/gcc-toolset-15/root/usr/bin:$PATH" + export LD_LIBRARY_PATH="/opt/rh/gcc-toolset-15/root/usr/lib64:$LD_LIBRARY_PATH" +else + echo "ERROR: gcc-toolset-15 not found" + exit 1 +fi + +export PATH="/opt/rh/gcc-toolset-15/root/usr/bin:$PATH" +export LD_LIBRARY_PATH="/opt/rh/gcc-toolset-15/root/usr/lib64:${LD_LIBRARY_PATH:-}" + +export CC="/opt/rh/gcc-toolset-15/root/usr/bin/gcc" +export CXX="/opt/rh/gcc-toolset-15/root/usr/bin/g++" + +# Download the source package +echo "Cloning and installing..." +git clone $PACKAGE_URL +cd $PACKAGE_NAME + +# Initialize git submodules +git submodule update --init + +# Checkout the specified version +git checkout $PACKAGE_VERSION + +# Setup prefix for installation +mkdir prefix +export PREFIX=$(pwd)/prefix + +# Create build directory +mkdir build +cd build + +# Run cmake to configure the build +cmake -G "Unix Makefiles" \ + -DCMAKE_BUILD_TYPE="Release" \ + -DCMAKE_INSTALL_PREFIX="${PREFIX}" \ + -DCMAKE_POSITION_INDEPENDENT_CODE=1 \ + -DBUILD_SHARED_LIBS=1 \ + .. +# Build and install +cmake --build . +cmake --build . --target install +cd .. +python3.14 -m pip install setuptools wheel +wget https://raw.githubusercontent.com/ppc64le/build-scripts/refs/heads/master/u/utf8proc/pyproject.toml +sed -i s/{PACKAGE_VERSION}/$PACKAGE_VERSION/g pyproject.toml +mkdir -p local/$PACKAGE_NAME +# Copy the installation files to the local directory +cp -r prefix/* local/$PACKAGE_NAME/ +echo "Building wheel..." +python3.14 -m pip wheel --wheel-dir ${WORK_DIR} -vv --no-build-isolation --no-deps . + +# Install locally built wheel for validation + +WHEEL=$(find "${WORK_DIR}" -name "${PACKAGE}-*.whl" | head -1) +echo "Built wheel: ${WHEEL}" + +if ! python3.14 -m pip install "${WHEEL}" --no-deps; then + echo "------------------${PACKAGE}:Install_fails-------------------------------------" + echo "${PACKAGE} | ${PACKAGE_URL} | ${PACKAGE_VERSION} | GitHub | Fail | Install_Fails" + exit 1 +fi +SITE_PACKAGES=$(python3.14 -m pip show utf8proc | awk -F': ' '/^Location:/ {print $2}') +test -f "${SITE_PACKAGES}/utf8proc/include/utf8proc.h" || { + echo "ERROR: utf8proc.h not found" + exit 1 +} + +test -f "${SITE_PACKAGES}/utf8proc/lib64/libutf8proc.so" || { + echo "ERROR: libutf8proc.so not found" + exit 1 +} + + +echo "Build and installation completed successfully." +echo "There are no test cases available. Manually tested and skipping the test cases." From 1977a48548770930e589891287e004eba02df693 Mon Sep 17 00:00:00 2001 From: shivansh-ibm Date: Mon, 7 Sep 2026 15:21:20 +0530 Subject: [PATCH 2/4] Update utf8proc_ubi_10.2.sh --- u/utf8proc/utf8proc_ubi_10.2.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/u/utf8proc/utf8proc_ubi_10.2.sh b/u/utf8proc/utf8proc_ubi_10.2.sh index 6e2ebfada1..c8ee2a24c9 100644 --- a/u/utf8proc/utf8proc_ubi_10.2.sh +++ b/u/utf8proc/utf8proc_ubi_10.2.sh @@ -92,7 +92,7 @@ python3.14 -m pip wheel --wheel-dir ${WORK_DIR} -vv --no-build-isolation --no-de # Install locally built wheel for validation -WHEEL=$(find "${WORK_DIR}" -name "${PACKAGE}-*.whl" | head -1) +WHEEL=$(find "${WORK_DIR}" -name "${PACKAGE_NAME}-*.whl" | head -1) echo "Built wheel: ${WHEEL}" if ! python3.14 -m pip install "${WHEEL}" --no-deps; then From fe1e7220296aedf74e1dd82ba80caf709d02f2cb Mon Sep 17 00:00:00 2001 From: shivansh-ibm Date: Tue, 8 Sep 2026 17:38:34 +0530 Subject: [PATCH 3/4] Update utf8proc_ubi_10.2.sh --- u/utf8proc/utf8proc_ubi_10.2.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/u/utf8proc/utf8proc_ubi_10.2.sh b/u/utf8proc/utf8proc_ubi_10.2.sh index c8ee2a24c9..4a8ab189dc 100644 --- a/u/utf8proc/utf8proc_ubi_10.2.sh +++ b/u/utf8proc/utf8proc_ubi_10.2.sh @@ -105,6 +105,10 @@ test -f "${SITE_PACKAGES}/utf8proc/include/utf8proc.h" || { echo "ERROR: utf8proc.h not found" exit 1 } +ls ${SITE_PACKAGES}/utf8proc +ls ${SITE_PACKAGES}/utf8proc/lib +ls ${SITE_PACKAGES}/utf8proc/lib64 +ls ${SITE_PACKAGES}/utf8proc/include test -f "${SITE_PACKAGES}/utf8proc/lib64/libutf8proc.so" || { echo "ERROR: libutf8proc.so not found" From 7c8cbc1cc6f15650ff89c70a2f10b2aa227213b6 Mon Sep 17 00:00:00 2001 From: shivansh-ibm Date: Wed, 9 Sep 2026 12:06:09 +0530 Subject: [PATCH 4/4] Update utf8proc_ubi_10.2.sh --- u/utf8proc/utf8proc_ubi_10.2.sh | 5 ----- 1 file changed, 5 deletions(-) diff --git a/u/utf8proc/utf8proc_ubi_10.2.sh b/u/utf8proc/utf8proc_ubi_10.2.sh index 4a8ab189dc..5d9aa52c30 100644 --- a/u/utf8proc/utf8proc_ubi_10.2.sh +++ b/u/utf8proc/utf8proc_ubi_10.2.sh @@ -105,11 +105,6 @@ test -f "${SITE_PACKAGES}/utf8proc/include/utf8proc.h" || { echo "ERROR: utf8proc.h not found" exit 1 } -ls ${SITE_PACKAGES}/utf8proc -ls ${SITE_PACKAGES}/utf8proc/lib -ls ${SITE_PACKAGES}/utf8proc/lib64 -ls ${SITE_PACKAGES}/utf8proc/include - test -f "${SITE_PACKAGES}/utf8proc/lib64/libutf8proc.so" || { echo "ERROR: libutf8proc.so not found" exit 1