From 2e6fe1a4ccfc4ffc63e5d0dc09f972ebbca12426 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Cumplido?= Date: Tue, 26 Nov 2024 06:04:07 +0100 Subject: [PATCH] GH-44844: [CI] Uninstall pkg-config entirely on verification and java-jars macOS jobs (#44845) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ### Rationale for this change Jobs are failing on nightlies. ### What changes are included in this PR? Remove pkg-config entirely as we've done on other CI jobs. ### Are these changes tested? Yes via archery ### Are there any user-facing changes? No * GitHub Issue: #44844 Lead-authored-by: Raúl Cumplido Co-authored-by: Sutou Kouhei Signed-off-by: Sutou Kouhei --- dev/tasks/java-jars/github.yml | 8 ++++++++ dev/tasks/verify-rc/github.macos.yml | 15 +++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/dev/tasks/java-jars/github.yml b/dev/tasks/java-jars/github.yml index c3119946450e4..affa26a1d9332 100644 --- a/dev/tasks/java-jars/github.yml +++ b/dev/tasks/java-jars/github.yml @@ -129,6 +129,14 @@ jobs: done brew install --overwrite python + if [ "$(uname -m)" = "arm64" ]; then + # pkg-config formula is deprecated but it's still installed + # in GitHub Actions runner now. We can remove this once + # pkg-config formula is removed from GitHub Actions runner. + brew uninstall pkg-config || : + brew uninstall pkg-config@0.29.2 || : + fi + brew bundle --file=arrow/cpp/Brewfile # We want to link aws-sdk-cpp statically but Homebrew's # aws-sdk-cpp provides only shared library. If we have diff --git a/dev/tasks/verify-rc/github.macos.yml b/dev/tasks/verify-rc/github.macos.yml index e0272e8f4e321..da6d274918f39 100644 --- a/dev/tasks/verify-rc/github.macos.yml +++ b/dev/tasks/verify-rc/github.macos.yml @@ -42,8 +42,23 @@ jobs: - name: Install System Dependencies shell: bash run: | + {% if github_runner in ("macos-14", "macos-latest") %} + # pkg-config formula is deprecated but it's still installed + # in GitHub Actions runner now. We can remove this once + # pkg-config formula is removed from GitHub Actions runner. + brew uninstall pkg-config || : + brew uninstall pkg-config@0.29.2 || : + {% endif %} + brew bundle --file=arrow/cpp/Brewfile brew bundle --file=arrow/c_glib/Brewfile + + # For Meson. + # See also: https://github.com/mesonbuild/meson/issues/7701 + pkgconf="$(brew --prefix pkgconf)/bin/pkgconf" + if [ -x "${pkgconf}" ]; then + echo "PKG_CONFIG=${pkgconf}" >> $GITHUB_ENV + fi {% endif %} - uses: actions/setup-java@v2