From 4f7fbb16ebf47b504e30a4ef89f7148a73bab5da Mon Sep 17 00:00:00 2001 From: Thomas Lange Date: Mon, 6 Jan 2025 18:24:34 +0100 Subject: [PATCH] CI: Support macOS 15 build with autotools Use also always Qt 5 on macOS 13 and Qt 6 on macOS 15. Disable adplug because 'libbinio/binio.h' is not found for some reason. --- .../install-dependencies.sh | 14 +++++++++--- .github/actions/run-action/run-action.sh | 22 ++++++++++++++----- .github/workflows/c-cpp.yml | 9 ++------ 3 files changed, 30 insertions(+), 15 deletions(-) diff --git a/.github/actions/install-dependencies/install-dependencies.sh b/.github/actions/install-dependencies/install-dependencies.sh index 6387cc910..ea1c08f36 100755 --- a/.github/actions/install-dependencies/install-dependencies.sh +++ b/.github/actions/install-dependencies/install-dependencies.sh @@ -6,8 +6,8 @@ # ubuntu-22.04: Qt 5 + GTK 3 # ubuntu-24.04: Qt 6 + GTK 3 # Windows: Qt 6 + GTK 2 -# macOS (Autotools): Qt 5 - GTK -# macOS (Meson): Qt 6 - GTK +# macOS 13: Qt 5 - GTK +# macOS 15: Qt 6 - GTK os=$(tr '[:upper:]' '[:lower:]' <<< "$1") build_system=$(tr '[:upper:]' '[:lower:]' <<< "$2") @@ -58,11 +58,19 @@ case "$os" in fi ;; + macos-13) + if [ "$build_system" = 'meson' ]; then + brew install $macos_packages qt@5 meson + else + brew install $macos_packages qt@5 automake + fi + ;; + macos*) if [ "$build_system" = 'meson' ]; then brew install $macos_packages qt@6 meson else - brew install $macos_packages qt@5 automake + brew install $macos_packages qt@6 automake libiconv fi ;; diff --git a/.github/actions/run-action/run-action.sh b/.github/actions/run-action/run-action.sh index 96a7d3763..cdc478800 100755 --- a/.github/actions/run-action/run-action.sh +++ b/.github/actions/run-action/run-action.sh @@ -6,8 +6,8 @@ # ubuntu-22.04: Qt 5 + GTK 3 # ubuntu-24.04: Qt 6 + GTK 3 # Windows: Qt 6 + GTK 2 -# macOS (Autotools): Qt 5 - GTK -# macOS (Meson): Qt 6 - GTK +# macOS 13: Qt 5 - GTK +# macOS 15: Qt 6 - GTK action=$(tr '[:upper:]' '[:lower:]' <<< "$1") os=$(tr '[:upper:]' '[:lower:]' <<< "$2") @@ -49,13 +49,25 @@ case "$action" in fi ;; + macos-13) + export PATH="/usr/local/opt/qt@5/bin:$PATH" + export PKG_CONFIG_PATH="/usr/local/opt/qt@5/lib/pkgconfig:$PKG_CONFIG_PATH" + + if [ "$build_system" = 'meson' ]; then + meson setup build -D qt5=true -D gtk=false -D mac-media-keys=true + else + ./autogen.sh && ./configure --enable-qt5 --disable-gtk --enable-mac-media-keys + fi + ;; + macos*) + export PATH="/opt/homebrew/opt/qt@6/bin:$PATH" + export PKG_CONFIG_PATH="/opt/homebrew/opt/qt@6/libexec/lib/pkgconfig:$PKG_CONFIG_PATH" + if [ "$build_system" = 'meson' ]; then meson setup build -D gtk=false -D mac-media-keys=true else - export PATH="/usr/local/opt/qt@5/bin:$PATH" - export PKG_CONFIG_PATH="/usr/local/opt/qt@5/lib/pkgconfig:$PKG_CONFIG_PATH" - ./autogen.sh && ./configure --enable-qt5 --disable-gtk --enable-mac-media-keys + ./autogen.sh && ./configure --disable-gtk --disable-adplug --enable-mac-media-keys fi ;; diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml index b49c58d60..1fa84789c 100644 --- a/.github/workflows/c-cpp.yml +++ b/.github/workflows/c-cpp.yml @@ -10,13 +10,8 @@ jobs: build: strategy: matrix: - os: [ubuntu-20.04, ubuntu-22.04, ubuntu-24.04, - macos-13, macos-15, - windows-2022] - build-system: [autotools, meson] - exclude: - - os: macos-15 - build-system: autotools + os: [macos-13, macos-15] + build-system: [autotools] fail-fast: false runs-on: ${{ matrix.os }}