fix: downgrade gcc-toolset from 14 to 13 for CUDA compatibility

gcc-toolset-14 (GCC 14) in manylinux_2_28 containers is incompatible
with CUDA 12.6 nvcc, causing compilation errors in type_traits headers.
Use gcc-toolset-13 instead and export CC/CXX to GITHUB_ENV to ensure
subsequent steps use the correct compiler.
This commit is contained in:
Junya Morioka
2026-01-28 02:35:58 +09:00
parent 74b21a43e5
commit 34d8e036bb
2 changed files with 36 additions and 6 deletions
@@ -99,12 +99,22 @@ jobs:
unzip \ unzip \
zip \ zip \
git \ git \
gcc \ gcc-toolset-13-gcc \
gcc-c++ \ gcc-toolset-13-gcc-c++ \
clang \ clang \
ninja-build \ ninja-build \
time \ time \
patchelf patchelf
# Activate gcc-toolset-13 for CUDA compatibility
if [ -f /opt/rh/gcc-toolset-13/enable ]; then
# Export PATH and other env vars to GITHUB_ENV for subsequent steps
source /opt/rh/gcc-toolset-13/enable
echo "PATH=$PATH" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH:-}" >> $GITHUB_ENV
echo "CC=$(which gcc)" >> $GITHUB_ENV
echo "CXX=$(which g++)" >> $GITHUB_ENV
echo "GCC version: $(gcc --version | head -1)"
fi
else else
echo "Error: No supported package manager found (apt-get or dnf)" echo "Error: No supported package manager found (apt-get or dnf)"
exit 1 exit 1
+24 -4
View File
@@ -104,12 +104,22 @@ jobs:
unzip \ unzip \
zip \ zip \
git \ git \
gcc \ gcc-toolset-13-gcc \
gcc-c++ \ gcc-toolset-13-gcc-c++ \
clang \ clang \
ninja-build \ ninja-build \
time \ time \
patchelf patchelf
# Activate gcc-toolset-13 for CUDA compatibility
if [ -f /opt/rh/gcc-toolset-13/enable ]; then
# Export PATH and other env vars to GITHUB_ENV for subsequent steps
source /opt/rh/gcc-toolset-13/enable
echo "PATH=$PATH" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH:-}" >> $GITHUB_ENV
echo "CC=$(which gcc)" >> $GITHUB_ENV
echo "CXX=$(which g++)" >> $GITHUB_ENV
echo "GCC version: $(gcc --version | head -1)"
fi
else else
echo "Error: No supported package manager found (apt-get or dnf)" echo "Error: No supported package manager found (apt-get or dnf)"
exit 1 exit 1
@@ -210,12 +220,22 @@ jobs:
unzip \ unzip \
zip \ zip \
git \ git \
gcc \ gcc-toolset-13-gcc \
gcc-c++ \ gcc-toolset-13-gcc-c++ \
clang \ clang \
ninja-build \ ninja-build \
time \ time \
patchelf patchelf
# Activate gcc-toolset-13 for CUDA compatibility
if [ -f /opt/rh/gcc-toolset-13/enable ]; then
# Export PATH and other env vars to GITHUB_ENV for subsequent steps
source /opt/rh/gcc-toolset-13/enable
echo "PATH=$PATH" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH:-}" >> $GITHUB_ENV
echo "CC=$(which gcc)" >> $GITHUB_ENV
echo "CXX=$(which g++)" >> $GITHUB_ENV
echo "GCC version: $(gcc --version | head -1)"
fi
else else
echo "Error: No supported package manager found (apt-get or dnf)" echo "Error: No supported package manager found (apt-get or dnf)"
exit 1 exit 1