Skip to content

Commit 2a876a1

Browse files
committed
ci: Move away from soon-to-be-deprecated ubuntu-20.04 GHA runner (#4636)
In the process, port a more modern build_llvm.bash from osl. Signed-off-by: Larry Gritz <[email protected]>
1 parent 6f46527 commit 2a876a1

File tree

4 files changed

+34
-23
lines changed

4 files changed

+34
-23
lines changed

.github/workflows/ci.yml

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -456,40 +456,37 @@ jobs:
456456
PUGIXML_VERSION=v1.14
457457
WEBP_VERSION=v1.4.0
458458

459-
- desc: clang14 C++20 avx2 exr3.1 ocio2.1
459+
- desc: clang15 C++17 avx2 exr3.1 ocio2.2
460460
nametag: linux-clang14
461-
runner: ubuntu-20.04
462-
cxx_compiler: clang++
463-
cc_compiler: clang
464-
cxx_std: 20
461+
runner: ubuntu-22.04
462+
cxx_compiler: clang++-15
463+
cc_compiler: clang-15
464+
cxx_std: 17
465465
fmt_ver: 10.1.1
466466
opencolorio_ver: v2.2.1
467467
openexr_ver: v3.1.13
468468
pybind11_ver: v2.12.0
469-
python_ver: 3.8
469+
python_ver: "3.10"
470470
simd: avx2,f16c
471-
setenvs: export LLVM_VERSION=14.0.0
472-
USE_OPENVDB=0
473-
# The installed OpenVDB has a TLS conflict with Python 3.8
474471
- desc: debug gcc9/C++17, sse4.2, exr3.1
475472
nametag: linux-gcc9-cpp17-debug
476-
runner: ubuntu-20.04
473+
runner: ubuntu-22.04
477474
cxx_compiler: g++-9
478475
cxx_std: 17
479476
build_type: Debug
480-
python_ver: 3.8
477+
python_ver: "3.10"
481478
simd: sse4.2
482479
openexr_ver: v3.1.13
483480
pybind11_ver: v2.7.0
484481
ctest_test_timeout: 1200
485482
setenvs: export PUGIXML_VERSION=v1.9
486483
- desc: static libs gcc9 C++17 exr3.1
487484
nametag: linux-static
488-
runner: ubuntu-20.04
485+
runner: ubuntu-22.04
489486
cxx_compiler: g++-9
490487
cxx_std: 17
491488
openexr_ver: v3.1.13
492-
python_ver: 3.8
489+
python_ver: "3.10"
493490
pybind11_ver: v2.7.0
494491
setenvs: export BUILD_SHARED_LIBS=OFF
495492
depcmds: |

src/build-scripts/build_llvm.bash

Lines changed: 22 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,22 +12,36 @@ set -ex
1212
echo "Building LLVM"
1313
uname
1414

15+
: ${LLVM_VERSION:=18.1.8}
16+
: ${LLVM_INSTALL_DIR:=${PWD}/llvm-install}
17+
mkdir -p $LLVM_INSTALL_DIR || true
1518

1619
if [[ `uname` == "Linux" ]] ; then
17-
: ${LLVM_VERSION:=13.0.0}
18-
: ${LLVM_INSTALL_DIR:=${PWD}/llvm-install}
1920
: ${LLVM_DISTRO_NAME:=ubuntu-18.04}
2021
LLVMTAR=clang+llvm-${LLVM_VERSION}-x86_64-linux-gnu-${LLVM_DISTRO_NAME}.tar.xz
2122
echo LLVMTAR = $LLVMTAR
2223
curl --location https://github.com/llvm/llvm-project/releases/download/llvmorg-${LLVM_VERSION}/${LLVMTAR} -o $LLVMTAR
2324
ls -l $LLVMTAR
2425
tar xf $LLVMTAR
2526
rm -f $LLVMTAR
26-
echo "Installed LLVM ${LLVM_VERSION} in ${LLVM_INSTALL_DIR}"
27-
mkdir -p $LLVM_INSTALL_DIR && true
2827
mv clang+llvm*/* $LLVM_INSTALL_DIR
29-
export LLVM_DIRECTORY=$LLVM_INSTALL_DIR
30-
export PATH=${LLVM_INSTALL_DIR}/bin:$PATH
31-
export LLVM_ROOT=${LLVM_INSTALL_DIR}
32-
# ls -a $LLVM_DIRECTORY
28+
elif [[ `uname -s` == "Windows" || "${RUNNER_OS}" == "Windows" ]] ; then
29+
echo "Installing Windows LLVM"
30+
: ${LLVM_DISTRO_NAME:=ubuntu-18.04}
31+
LLVMTAR=clang+llvm-${LLVM_VERSION}-x86_64-pc-windows-msvc.tar.xz
32+
echo LLVMTAR = $LLVMTAR
33+
curl --location https://github.com/llvm/llvm-project/releases/download/llvmorg-${LLVM_VERSION}/${LLVMTAR} -o $LLVMTAR
34+
ls -l $LLVMTAR
35+
tar xf $LLVMTAR
36+
rm -f $LLVMTAR
37+
mv clang+llvm*/* $LLVM_INSTALL_DIR
38+
else
39+
echo Bad uname `uname`
3340
fi
41+
42+
echo "Installed LLVM ${LLVM_VERSION} in ${LLVM_INSTALL_DIR}"
43+
ls -a $LLVM_INSTALL_DIR || true
44+
ls -a $LLVM_INSTALL_DIR/* || true
45+
export LLVM_DIRECTORY=$LLVM_INSTALL_DIR
46+
export PATH=${LLVM_INSTALL_DIR}/bin:$PATH
47+
export LLVM_ROOT=${LLVM_INSTALL_DIR}

src/build-scripts/gh-installdeps.bash

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ cmake --version
148148
# If we're using clang to compile on native Ubuntu, we need to install it.
149149
# If on an ASWF CentOS docker container, it already is installed.
150150
#
151-
if [[ ("$CXX" == "clang++" && "$ASWF_ORG" == "") || "$LLVM_VERSION" != "" ]] ; then
151+
if [[ "$LLVM_VERSION" != "" ]] ; then
152152
source src/build-scripts/build_llvm.bash
153153
fi
154154

testsuite/raw/ref/out-libraw-0.20.2-gh.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -546,7 +546,7 @@
546546
Sony:ImageStabilization: 1
547547
Sony:LensID: 40
548548
Sony:LensMount: 25
549-
Comparing "RAW_CANON_EOS_7D.CR2.tif" and "ref/RAW_CANON_EOS_7D.CR2-libraw0.20.0.tif"
549+
Comparing "RAW_CANON_EOS_7D.CR2.tif" and "ref/RAW_CANON_EOS_7D.CR2.tif"
550550
PASS
551551
Comparing "RAW_NIKON_D3X.NEF.tif" and "ref/RAW_NIKON_D3X.NEF.tif"
552552
PASS

0 commit comments

Comments
 (0)