From 8ef46c49ece4c11bab610e6de8504fbccbac4940 Mon Sep 17 00:00:00 2001 From: Tejas Badjate Date: Tue, 1 Sep 2026 16:12:56 +0530 Subject: [PATCH 1/4] added script to support UBI10.2 and python3.14 env --- c/cassandra-driver/build_info.json | 50 ++++---- .../cassandra-driver_3.30.1_ubi_10.2.sh | 113 ++++++++++++++++++ 2 files changed, 141 insertions(+), 22 deletions(-) create mode 100644 c/cassandra-driver/cassandra-driver_3.30.1_ubi_10.2.sh diff --git a/c/cassandra-driver/build_info.json b/c/cassandra-driver/build_info.json index 50756c4b2c..e9e482c65e 100644 --- a/c/cassandra-driver/build_info.json +++ b/c/cassandra-driver/build_info.json @@ -1,22 +1,28 @@ -{ - "maintainer": "Varsha Kumar", - "package_name": "cassandra-driver", - "github_url": "https://github.com/apache/cassandra-python-driver", - "version": "3.30.1", - "default_branch": "trunk", - "build_script": "cassandra-driver_3.30.1_ubi_9.6.sh", - "package_dir": "c/cassandra-driver", - "docker_build": false, - "wheel_build": true, - "validate_build_script": true, - "use_non_root_user": false, - "3.30.1":{ - "build_script": "cassandra-driver_3.30.1_ubi_9.6.sh" - }, - "3.29.0":{ - "build_script": "cassandra-driver_ubi_9.3.sh" - }, - "*": { - "build_script": "cassandra-driver_3.30.1_ubi_9.6.sh" - } -} +{ + "maintainer": "tejasBadjateIBM", + "package_name": "cassandra-driver", + "github_url": "https://github.com/apache/cassandra-python-driver", + "version": "3.30.1", + "default_branch": "trunk", + "build_script": "cassandra-driver_3.30.1_ubi_10.2.sh", + "package_dir": "c/cassandra-driver", + "docker_build": false, + "wheel_build": true, + "validate_build_script": true, + "use_non_root_user": false, + "3.30.1":{ + "build_script": [ + "cassandra-driver_3.30.1_ubi_10.2.sh", + "cassandra-driver_3.30.1_ubi_9.6.sh" + ] + }, + "3.29.0":{ + "build_script": "cassandra-driver_ubi_9.3.sh" + }, + "*": { + "build_script": [ + "cassandra-driver_3.30.1_ubi_10.2.sh", + "cassandra-driver_3.30.1_ubi_9.6.sh" + ] + } +} diff --git a/c/cassandra-driver/cassandra-driver_3.30.1_ubi_10.2.sh b/c/cassandra-driver/cassandra-driver_3.30.1_ubi_10.2.sh new file mode 100644 index 0000000000..a41fc1d4cc --- /dev/null +++ b/c/cassandra-driver/cassandra-driver_3.30.1_ubi_10.2.sh @@ -0,0 +1,113 @@ +#!/bin/bash -e +# ----------------------------------------------------------------------------- +# +# Package : cassandra-driver +# Version : 3.30.1 +# Source repo : http://github.com/datastax/python-driver +# Tested on : UBI:10.2 +# Language : Python +# Ci-Check : True +# Script License : Apache License, Version 2 or later +# Maintainer : tejasBadjateIBM +# +# Disclaimer: This script has been tested in root mode on 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 case, please +# contact "Maintainer" of this script. +# +# ---------------------------------------------------------------------------- +PACKAGE_NAME=cassandra-driver +PACKAGE_VERSION=${1:-3.30.1} +PACKAGE_URL=http://github.com/datastax/python-driver +PACKAGE_DIR=python-driver + +# Install dependencies +dnf install -y \ + git \ + make \ + wget \ + sudo \ + openssl-devel \ + bzip2-devel \ + krb5-devel \ + libffi-devel \ + zlib-devel \ + python3.14 \ + python3.14-devel \ + python3.14-pip \ + cargo \ + rust + +yum install gcc-toolset-15 gcc-toolset-15-gcc gcc-toolset-15-gcc-c++ gcc-toolset-15-gcc-gfortran -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++" + +#Install libev +curl -LO https://dist.schmorp.de/libev/Attic/libev-4.33.tar.gz +tar -xzf libev-4.33.tar.gz +cd libev-4.33 +export CFLAGS="-fPIC" +export LDFLAGS="-fPIC" +./configure --disable-shared --enable-static +make -j$(nproc) +make install +cd .. + +# Clone the repository +git clone $PACKAGE_URL +cd $PACKAGE_DIR +git checkout $PACKAGE_VERSION + +#install necessary Python packages +python3.14 -m pip install wheel pytest tox nox mock build gevent eventlet pyopenssl "setuptools<80" +python3.14 -m pip install -r test-requirements.txt + +export CASS_DRIVER_LIBEV_INCLUDES="/usr/local/include" +export CASS_DRIVER_LIBEV_LIBS="/usr/local/lib" +export LDFLAGS="-Wl,-Bstatic -lev -Wl,-Bdynamic" +python3.14 setup.py build_ext --inplace + +#Install +if ! python3.14 -m pip install . --no-build-isolation ; then + echo "------------------$PACKAGE_NAME:Install_fails-------------------------------------" + echo "$PACKAGE_URL $PACKAGE_NAME" + echo "$PACKAGE_NAME | $PACKAGE_URL | $PACKAGE_VERSION | GitHub | Fail | Install_Fails" + exit 1 +fi +#Skipping some tests as these are parity with intel and some test dependencies are deprecated with python3.11 and python3.14 +if !(python3.14 -m pytest tests/unit/ \ + -k "not (CloudTests or TestTwistedConnection or _PoolTests or test_timeout_does_not_release_stream_id)" \ + --ignore=tests/unit/io/test_libevreactor.py \ + --ignore=tests/unit/io/test_asyncioreactor.py \ + --ignore=tests/unit/io/test_asyncorereactor.py \ + --ignore=tests/unit/cython/test_bytesio.py \ + --ignore=tests/unit/cython/test_types.py \ + --ignore=tests/unit/cython/test_utils.py -p no:warnings) ; then + echo "------------------$PACKAGE_NAME:install_success_but_test_fails---------------------" + echo "$PACKAGE_URL $PACKAGE_NAME" + echo "$PACKAGE_NAME | $PACKAGE_URL | $PACKAGE_VERSION | GitHub | Fail | Install_success_but_test_Fails" + exit 2 +else + echo "------------------$PACKAGE_NAME:install_&_test_both_success-------------------------" + echo "$PACKAGE_URL $PACKAGE_NAME" + echo "$PACKAGE_NAME | $PACKAGE_URL | $PACKAGE_VERSION | GitHub | Pass | Both_Install_and_Test_Success" + exit 0 +fi \ No newline at end of file From 15b184487a5967343b0c13e9186c1494181aa13f Mon Sep 17 00:00:00 2001 From: Tejas Badjate Date: Tue, 1 Sep 2026 16:14:47 +0530 Subject: [PATCH 2/4] Revert "added script to support UBI10.2 and python3.14 env" This reverts commit 8ef46c49ece4c11bab610e6de8504fbccbac4940. --- c/cassandra-driver/build_info.json | 50 ++++---- .../cassandra-driver_3.30.1_ubi_10.2.sh | 113 ------------------ 2 files changed, 22 insertions(+), 141 deletions(-) delete mode 100644 c/cassandra-driver/cassandra-driver_3.30.1_ubi_10.2.sh diff --git a/c/cassandra-driver/build_info.json b/c/cassandra-driver/build_info.json index e9e482c65e..50756c4b2c 100644 --- a/c/cassandra-driver/build_info.json +++ b/c/cassandra-driver/build_info.json @@ -1,28 +1,22 @@ -{ - "maintainer": "tejasBadjateIBM", - "package_name": "cassandra-driver", - "github_url": "https://github.com/apache/cassandra-python-driver", - "version": "3.30.1", - "default_branch": "trunk", - "build_script": "cassandra-driver_3.30.1_ubi_10.2.sh", - "package_dir": "c/cassandra-driver", - "docker_build": false, - "wheel_build": true, - "validate_build_script": true, - "use_non_root_user": false, - "3.30.1":{ - "build_script": [ - "cassandra-driver_3.30.1_ubi_10.2.sh", - "cassandra-driver_3.30.1_ubi_9.6.sh" - ] - }, - "3.29.0":{ - "build_script": "cassandra-driver_ubi_9.3.sh" - }, - "*": { - "build_script": [ - "cassandra-driver_3.30.1_ubi_10.2.sh", - "cassandra-driver_3.30.1_ubi_9.6.sh" - ] - } -} +{ + "maintainer": "Varsha Kumar", + "package_name": "cassandra-driver", + "github_url": "https://github.com/apache/cassandra-python-driver", + "version": "3.30.1", + "default_branch": "trunk", + "build_script": "cassandra-driver_3.30.1_ubi_9.6.sh", + "package_dir": "c/cassandra-driver", + "docker_build": false, + "wheel_build": true, + "validate_build_script": true, + "use_non_root_user": false, + "3.30.1":{ + "build_script": "cassandra-driver_3.30.1_ubi_9.6.sh" + }, + "3.29.0":{ + "build_script": "cassandra-driver_ubi_9.3.sh" + }, + "*": { + "build_script": "cassandra-driver_3.30.1_ubi_9.6.sh" + } +} diff --git a/c/cassandra-driver/cassandra-driver_3.30.1_ubi_10.2.sh b/c/cassandra-driver/cassandra-driver_3.30.1_ubi_10.2.sh deleted file mode 100644 index a41fc1d4cc..0000000000 --- a/c/cassandra-driver/cassandra-driver_3.30.1_ubi_10.2.sh +++ /dev/null @@ -1,113 +0,0 @@ -#!/bin/bash -e -# ----------------------------------------------------------------------------- -# -# Package : cassandra-driver -# Version : 3.30.1 -# Source repo : http://github.com/datastax/python-driver -# Tested on : UBI:10.2 -# Language : Python -# Ci-Check : True -# Script License : Apache License, Version 2 or later -# Maintainer : tejasBadjateIBM -# -# Disclaimer: This script has been tested in root mode on 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 case, please -# contact "Maintainer" of this script. -# -# ---------------------------------------------------------------------------- -PACKAGE_NAME=cassandra-driver -PACKAGE_VERSION=${1:-3.30.1} -PACKAGE_URL=http://github.com/datastax/python-driver -PACKAGE_DIR=python-driver - -# Install dependencies -dnf install -y \ - git \ - make \ - wget \ - sudo \ - openssl-devel \ - bzip2-devel \ - krb5-devel \ - libffi-devel \ - zlib-devel \ - python3.14 \ - python3.14-devel \ - python3.14-pip \ - cargo \ - rust - -yum install gcc-toolset-15 gcc-toolset-15-gcc gcc-toolset-15-gcc-c++ gcc-toolset-15-gcc-gfortran -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++" - -#Install libev -curl -LO https://dist.schmorp.de/libev/Attic/libev-4.33.tar.gz -tar -xzf libev-4.33.tar.gz -cd libev-4.33 -export CFLAGS="-fPIC" -export LDFLAGS="-fPIC" -./configure --disable-shared --enable-static -make -j$(nproc) -make install -cd .. - -# Clone the repository -git clone $PACKAGE_URL -cd $PACKAGE_DIR -git checkout $PACKAGE_VERSION - -#install necessary Python packages -python3.14 -m pip install wheel pytest tox nox mock build gevent eventlet pyopenssl "setuptools<80" -python3.14 -m pip install -r test-requirements.txt - -export CASS_DRIVER_LIBEV_INCLUDES="/usr/local/include" -export CASS_DRIVER_LIBEV_LIBS="/usr/local/lib" -export LDFLAGS="-Wl,-Bstatic -lev -Wl,-Bdynamic" -python3.14 setup.py build_ext --inplace - -#Install -if ! python3.14 -m pip install . --no-build-isolation ; then - echo "------------------$PACKAGE_NAME:Install_fails-------------------------------------" - echo "$PACKAGE_URL $PACKAGE_NAME" - echo "$PACKAGE_NAME | $PACKAGE_URL | $PACKAGE_VERSION | GitHub | Fail | Install_Fails" - exit 1 -fi -#Skipping some tests as these are parity with intel and some test dependencies are deprecated with python3.11 and python3.14 -if !(python3.14 -m pytest tests/unit/ \ - -k "not (CloudTests or TestTwistedConnection or _PoolTests or test_timeout_does_not_release_stream_id)" \ - --ignore=tests/unit/io/test_libevreactor.py \ - --ignore=tests/unit/io/test_asyncioreactor.py \ - --ignore=tests/unit/io/test_asyncorereactor.py \ - --ignore=tests/unit/cython/test_bytesio.py \ - --ignore=tests/unit/cython/test_types.py \ - --ignore=tests/unit/cython/test_utils.py -p no:warnings) ; then - echo "------------------$PACKAGE_NAME:install_success_but_test_fails---------------------" - echo "$PACKAGE_URL $PACKAGE_NAME" - echo "$PACKAGE_NAME | $PACKAGE_URL | $PACKAGE_VERSION | GitHub | Fail | Install_success_but_test_Fails" - exit 2 -else - echo "------------------$PACKAGE_NAME:install_&_test_both_success-------------------------" - echo "$PACKAGE_URL $PACKAGE_NAME" - echo "$PACKAGE_NAME | $PACKAGE_URL | $PACKAGE_VERSION | GitHub | Pass | Both_Install_and_Test_Success" - exit 0 -fi \ No newline at end of file From aa1f9f4b37ae168e436f144ab005f983cce8a438 Mon Sep 17 00:00:00 2001 From: Tejas Badjate Date: Wed, 2 Sep 2026 12:20:34 +0530 Subject: [PATCH 3/4] added script to support UBI10.2 and python3.14 env --- z/zstd/build_info.json | 41 ++++++----- z/zstd/zstd_ubi_10.2.sh | 150 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 175 insertions(+), 16 deletions(-) create mode 100644 z/zstd/zstd_ubi_10.2.sh diff --git a/z/zstd/build_info.json b/z/zstd/build_info.json index b03bd6e86e..c8dea88da7 100644 --- a/z/zstd/build_info.json +++ b/z/zstd/build_info.json @@ -1,16 +1,25 @@ -{ - "maintainer": "Harithanagothu2", - "package_name": "zstd", - "github_url": "https://github.com/sergey-dryabzhinsky/python-zstd.git", - "version": "v1.5.6.1", - "wheel_build" : true, - "package_dir": "z/zstd", - "default_branch": "master", - "build_script": "zstd_ubi_9.3.sh", - "docker_build": false, - "validate_build_script": true, - "use_non_root_user": "false", - "*":{ - "build_script":"zstd_ubi_9.3.sh" - } -} +{ + "maintainer": "tejasBadjateIBM", + "package_name": "zstd", + "github_url": "https://github.com/sergey-dryabzhinsky/python-zstd.git", + "version": "v1.5.7.2", + "wheel_build" : true, + "package_dir": "z/zstd", + "default_branch": "master", + "build_script": "zstd_ubi_10.2.sh", + "docker_build": false, + "validate_build_script": true, + "use_non_root_user": "false", + "v1.5.7.2" : { + "build_script" : "zstd_ubi_10.2.sh" + }, + "v1.5.6.1" : { + "build_script" : "zstd_ubi_9.3.sh" + }, + "*":{ + "build_script": [ + "zstd_ubi_9.3.sh", + "zstd_ubi_10.2.sh" + ] + } +} diff --git a/z/zstd/zstd_ubi_10.2.sh b/z/zstd/zstd_ubi_10.2.sh new file mode 100644 index 0000000000..5c89f6a84c --- /dev/null +++ b/z/zstd/zstd_ubi_10.2.sh @@ -0,0 +1,150 @@ +#!/bin/bash -e +# ----------------------------------------------------------------------------- +# +# Package : zstd +# Version : v1.5.7.2 +# Source repo : https://github.com/sergey-dryabzhinsky/python-zstd.git +# Tested on : UBI:10.2 +# Language : Python +# Ci-Check : True +# Script License: Apache License, Version 2 or later +# Maintainer : tejasBadjateIBM +# +# 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. +# +# ----------------------------------------------------------------------------- + +# Variables +PACKAGE_NAME=zstd +PACKAGE_VERSION=${1:-v1.5.7.2} +PACKAGE_URL=https://github.com/sergey-dryabzhinsky/python-zstd.git +PACKAGE_DIR=python-zstd + +# Install dependencies and tools. +yum install -y git wget python3.14-devel python3.14-pip openssl-devel cmake libzstd.ppc64le +python3.14 -m pip install --upgrade pip setuptools wheel pytest + +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++" + +echo "-------------------------------------------------------------Installing Openblas ---------------------------------------------------------" + +git clone -b v0.3.33 https://github.com/xianyi/OpenBLAS +cd OpenBLAS +git submodule update --init +SRC_DIR=$(pwd) + +# Set pip config +python3.14 -m pip config set global.index-url https://pypi.python.org/simple +python3.14 -m pip config set global.no-index false + +# Install prerequisite wheels +python3.14 -m pip install setuptools + +# Setting the environment variables +LDFLAGS=$(echo "${LDFLAGS}" | sed "s/-Wl,--gc-sections//g") + +# See this workaround: +# https://github.com/xianyi/OpenBLAS/issues/818#issuecomment-207365134 +export CF="${CFLAGS} -Wno-unused-parameter -Wno-old-style-declaration" +unset CFLAGS +export USE_OPENMP=1 + +# Set installation path +export PREFIX=${SRC_DIR}/local/openblas + +# Build options +build_opts=() +build_opts+=(USE_OPENMP=${USE_OPENMP}) + +if [ -n "${FFLAGS}" ]; then + # Don't use GNU OpenMP, which is not fork-safe + export FFLAGS="${FFLAGS/-fopenmp/ }" + export FFLAGS="${FFLAGS} -frecursive" + export LAPACK_FFLAGS="${FFLAGS}" +fi + +build_opts+=(BINARY="64") +build_opts+=(DYNAMIC_ARCH=1) + +# Set target platform-/CPU-specific options +# Only setting option for x86 CPU platform +build_opts+=(TARGET="PRESCOTT") + +# Placeholder for future builds that may include ILP64 variants. +build_opts+=(INTERFACE64=0) +build_opts+=(SYMBOLSUFFIX="") + +# Build LAPACK +build_opts+=(NO_LAPACK=0) + +# Enable threading +build_opts+=(USE_THREAD=1) +build_opts+=(NUM_THREADS=8) + +# Disable CPU/memory affinity handling to avoid problems with NumPy and R +build_opts+=(NO_AFFINITY=1) + +# Build +make -j8 ${build_opts[@]} \ + HOST=${HOST} CROSS_SUFFIX="${HOST}-" \ + CFLAGS="${CF}" FFLAGS="${FFLAGS}" + +# Install OpenBLAS to PREFIX +CFLAGS="${CF}" FFLAGS="${FFLAGS}" \ + make install PREFIX="${PREFIX}" "${build_opts[@]}" + +cd .. +echo ""-------------------------------------------------------------Installed Openblas ---------------------------------------------------------"" + + +#clone repository +git clone $PACKAGE_URL +cd $PACKAGE_DIR +git checkout $PACKAGE_VERSION +git submodule update --init + +#install +if ! python3.14 setup.py install ; then + echo "------------------$PACKAGE_NAME:Install_fails-------------------------------------" + echo "$PACKAGE_URL $PACKAGE_NAME" + echo "$PACKAGE_NAME | $PACKAGE_URL | $PACKAGE_VERSION | GitHub | Fail | Install_Fails" + exit 1 +fi + +#test +if ! python3.14 -m pytest; then + echo "--------------------$PACKAGE_NAME:Install_success_but_test_fails---------------------" + echo "$PACKAGE_URL $PACKAGE_NAME" + echo "$PACKAGE_NAME | $PACKAGE_URL | $PACKAGE_VERSION | GitHub | Fail | Install_success_but_test_Fails" + exit 2 +else + echo "------------------$PACKAGE_NAME:Install_&_test_both_success-------------------------" + echo "$PACKAGE_URL $PACKAGE_NAME" + echo "$PACKAGE_NAME | $PACKAGE_URL | $PACKAGE_VERSION | GitHub | Pass | Both_Install_and_Test_Success" + exit 0 +fi + + From 4ec7fec4798a326abd2dcf0b77394608f898ea7d Mon Sep 17 00:00:00 2001 From: Tejas Badjate Date: Thu, 3 Sep 2026 17:11:36 +0530 Subject: [PATCH 4/4] removed openblas dependency --- z/zstd/zstd_ubi_10.2.sh | 71 ----------------------------------------- 1 file changed, 71 deletions(-) diff --git a/z/zstd/zstd_ubi_10.2.sh b/z/zstd/zstd_ubi_10.2.sh index 5c89f6a84c..43a48ce375 100644 --- a/z/zstd/zstd_ubi_10.2.sh +++ b/z/zstd/zstd_ubi_10.2.sh @@ -49,77 +49,6 @@ 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++" -echo "-------------------------------------------------------------Installing Openblas ---------------------------------------------------------" - -git clone -b v0.3.33 https://github.com/xianyi/OpenBLAS -cd OpenBLAS -git submodule update --init -SRC_DIR=$(pwd) - -# Set pip config -python3.14 -m pip config set global.index-url https://pypi.python.org/simple -python3.14 -m pip config set global.no-index false - -# Install prerequisite wheels -python3.14 -m pip install setuptools - -# Setting the environment variables -LDFLAGS=$(echo "${LDFLAGS}" | sed "s/-Wl,--gc-sections//g") - -# See this workaround: -# https://github.com/xianyi/OpenBLAS/issues/818#issuecomment-207365134 -export CF="${CFLAGS} -Wno-unused-parameter -Wno-old-style-declaration" -unset CFLAGS -export USE_OPENMP=1 - -# Set installation path -export PREFIX=${SRC_DIR}/local/openblas - -# Build options -build_opts=() -build_opts+=(USE_OPENMP=${USE_OPENMP}) - -if [ -n "${FFLAGS}" ]; then - # Don't use GNU OpenMP, which is not fork-safe - export FFLAGS="${FFLAGS/-fopenmp/ }" - export FFLAGS="${FFLAGS} -frecursive" - export LAPACK_FFLAGS="${FFLAGS}" -fi - -build_opts+=(BINARY="64") -build_opts+=(DYNAMIC_ARCH=1) - -# Set target platform-/CPU-specific options -# Only setting option for x86 CPU platform -build_opts+=(TARGET="PRESCOTT") - -# Placeholder for future builds that may include ILP64 variants. -build_opts+=(INTERFACE64=0) -build_opts+=(SYMBOLSUFFIX="") - -# Build LAPACK -build_opts+=(NO_LAPACK=0) - -# Enable threading -build_opts+=(USE_THREAD=1) -build_opts+=(NUM_THREADS=8) - -# Disable CPU/memory affinity handling to avoid problems with NumPy and R -build_opts+=(NO_AFFINITY=1) - -# Build -make -j8 ${build_opts[@]} \ - HOST=${HOST} CROSS_SUFFIX="${HOST}-" \ - CFLAGS="${CF}" FFLAGS="${FFLAGS}" - -# Install OpenBLAS to PREFIX -CFLAGS="${CF}" FFLAGS="${FFLAGS}" \ - make install PREFIX="${PREFIX}" "${build_opts[@]}" - -cd .. -echo ""-------------------------------------------------------------Installed Openblas ---------------------------------------------------------"" - - #clone repository git clone $PACKAGE_URL cd $PACKAGE_DIR