The ubuntu-latest runner is now using Ubuntu 24.04. Package libhwy0 has been renamed to libhwy1t64. Since libhwy-dev is required and dev packages depend on the runtime library, libhwy1t64 does not need to be explicitly installed. Update libjxl and its dependencies in CodeQL workflow.
106 lines
3.5 KiB
YAML
106 lines
3.5 KiB
YAML
name: "CodeQL"
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- dev
|
|
- releases
|
|
- 'release-[0-9]+.*'
|
|
pull_request:
|
|
# The branches below must be a subset of the branches above
|
|
branches:
|
|
- dev
|
|
- releases
|
|
- 'release-[0-9]+.*'
|
|
schedule:
|
|
- cron: '56 5 * * 1'
|
|
|
|
jobs:
|
|
analyze:
|
|
name: Analyze
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
actions: read
|
|
contents: read
|
|
security-events: write
|
|
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
build_type: [release]
|
|
language: [ 'cpp', 'python' ]
|
|
|
|
steps:
|
|
- name: Checkout source
|
|
uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
echo "Running apt update."
|
|
sudo apt update
|
|
echo "Installing dependencies with apt."
|
|
DEBIAN_FRONTEND=noninteractive sudo apt install -y cmake libgtk-3-dev libgtkmm-3.0-dev liblensfun-dev librsvg2-dev liblcms2-dev libfftw3-dev libiptcdata0-dev libtiff5-dev libcanberra-gtk3-dev liblensfun-bin libexiv2-dev libtcmalloc-minimal4 libhwy-dev libopenexr-dev libgif-dev
|
|
|
|
- name: Install libjxl
|
|
run: |
|
|
echo "Downloading and installing libjxl..."
|
|
VERSION_UBUNTU=24.04
|
|
VERSION_JXL=0.11.1
|
|
curl -Ss -qgb "" -fLC - --retry 3 --retry-delay 3 -o libjxl-debs.tar.gz \
|
|
"https://github.com/libjxl/libjxl/releases/download/v${VERSION_JXL}/jxl-debs-amd64-ubuntu-${VERSION_UBUNTU}-v${VERSION_JXL}.tar.gz"
|
|
tar xf libjxl-debs.tar.gz
|
|
DEBIAN_FRONTEND=noninteractive sudo dpkg -i jxl_${VERSION_JXL}_amd64.deb libjxl-dev_${VERSION_JXL}_amd64.deb libjxl_${VERSION_JXL}_amd64.deb
|
|
|
|
- name: Configure build
|
|
run: |
|
|
export REF_NAME_FILTERED="$(echo '${{github.ref_name}}' | sed 's/[^A-z0-9_.-]//g')"
|
|
echo "Setting cache suffix."
|
|
if [ '${{github.ref_type}}' == 'tag' ]; then
|
|
export CACHE_SUFFIX=""
|
|
else
|
|
export CACHE_SUFFIX="5-$REF_NAME_FILTERED"
|
|
fi
|
|
export CACHE_SUFFIX="$CACHE_SUFFIX-AppImage"
|
|
echo "Cache suffix is '$CACHE_SUFFIX'."
|
|
echo "Making build directory."
|
|
mkdir build
|
|
echo "Changing working directory to the build directory."
|
|
cd build
|
|
echo "Running CMake configure."
|
|
cmake \
|
|
-DCMAKE_BUILD_TYPE='${{matrix.build_type}}' \
|
|
-DCACHE_NAME_SUFFIX="$CACHE_SUFFIX" \
|
|
-DPROC_TARGET_NUMBER="1" \
|
|
-DBUILD_BUNDLE="ON" \
|
|
-DBUNDLE_BASE_INSTALL_DIR="/" \
|
|
-DOPTION_OMP="ON" \
|
|
-DWITH_LTO="OFF" \
|
|
-DWITH_PROF="OFF" \
|
|
-DWITH_SAN="OFF" \
|
|
-DWITH_SYSTEM_KLT="OFF" \
|
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
|
-DLENSFUNDBDIR="../share/lensfun/version_1" \
|
|
..
|
|
echo "Recording filtered ref name."
|
|
echo "REF_NAME_FILTERED=$REF_NAME_FILTERED" >> $GITHUB_ENV
|
|
|
|
- name: Initialize CodeQL
|
|
uses: github/codeql-action/init@v3
|
|
with:
|
|
languages: ${{ matrix.language }}
|
|
|
|
- name: Build RawTherapee
|
|
working-directory: ./build
|
|
run: |
|
|
echo "Running make install."
|
|
make -j$(nproc) install DESTDIR=AppDir/usr/bin
|
|
echo "Moving usr/bin/share to usr/share."
|
|
mv AppDir/usr/bin/share AppDir/usr/
|
|
|
|
- name: Perform CodeQL Analysis
|
|
uses: github/codeql-action/analyze@v3
|
|
with:
|
|
category: "/language:${{matrix.language}}"
|