[Bazel CI] Android Firebase Cloud Messaging fails on macOS arm64: zlib zutil.c does not compile with Xcode 26.6 (Bazel 7.2.0rc1)

オープン
#722 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
30/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
android, c, macos

調査の方向性

Start with the failing target in android/firebase-cloud-messaging and reproduce with the listed steps on macOS arm64 using Bazel 7.2.0rc1. Read external/zlib/zutil.h around line 140, where fdopen is defined as a macro, alongside external/zlib/BUILD.bazel; compare with the macOS arm64 change in #716. Done means bazel build //app:app succeeds under Xcode 26.6 without breaking other zlib users.

索引モデルが issue の本文から書いたものです。

説明

CI: https://buildkite.com/bazel/bazel-bazel-examples/builds/5640#01a21001-b43b-4d66-8a31-d33936c497f1

Platform: macOS arm64

Failing tasks:

  • android (Android Firebase Cloud Messaging)

Logs:

(01:02:19) ERROR: .../external/zlib/BUILD.bazel:31:11: Compiling zutil.c [for tool] failed: (Exit 1): cc_wrapper.sh failed: error executing CppCompile command (from target @@zlib//:zlib)
In file included from external/zlib/zutil.c:10:
In file included from external/zlib/gzguts.h:21:
In file included from /Applications/Xcode26.6.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/stdio.h:61:
/Applications/Xcode26.6.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/_stdio.h:322:7: error: expected identifier or '('
  322 | FILE    *fdopen(int, const char *) __DARWIN_ALIAS_STARTING(__MAC_10_6, __IPHONE_2_0, __DARWIN_ALIAS(fdopen));
external/zlib/zutil.h:140:33: note: expanded from macro 'fdopen'
  140 | #        define fdopen(fd,mode) NULL /* No fdopen() */
(01:02:20) ERROR: Build did NOT complete successfully

Culprit: This task runs on macos_arm64 since #716. There the job uses Xcode 26.6, and the zlib version this example pulls in defines fdopen as a macro, which breaks the SDK's _stdio.h.

Steps:

git clone https://github.com/bazelbuild/examples.git
git reset c511c5d8659148c4d6ef715f24864c90cc25a6ab --hard
export USE_BAZEL_VERSION=7.2.0rc1
cd android/firebase-cloud-messaging
bazel build //app:app

CC Greenteam @meteorcloudy

主要言語
Starlark
スター
958
フォーク
582
PR マージ指標
30日以内にマージされた PR はありません

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

bazelbuild/examples のほかの issue

bazelbuild/examples の issue をすべて見る

似ている issue

Build System の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。