Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install the Bazel Homebrew package directly #11403

Closed
wants to merge 1 commit into from

Conversation

NashMiao
Copy link

@NashMiao NashMiao commented May 15, 2020

I try to install bazel in the way provided by documents over and over again, but it always failed :

$ brew install bazelbuild/tap/bazel
Updating Homebrew...
==> Installing bazel from bazelbuild/tap
==> Downloading https://releases.bazel.build/3.1.0/release/bazel-3.1.0-installer-darwin-x86_64.sh
-=O=-            #     #     #     #                                          
curl: (7) Failed to connect to releases.bazel.build port 443: Operation timed out
Error: An exception occurred within a child process:
  DownloadError: Failed to download resource "bazel"
Download failed: https://releases.bazel.build/3.1.0/release/bazel-3.1.0-installer-darwin-x86_64.sh

image

However, I found we can install bazel directly with Homebrew successfully:

brew install bazel

image

Here is the information:

$ brew info bazel
bazel: stable 3.1.0 (bottled)
Google's own build tool
https://bazel.build/
Not installed
From: https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git/Formula/bazel.rb
==> Dependencies
Build: [email protected]
Required: openjdk@11 ✘
==> Requirements
Required: macOS >= 10.10 ✔
==> Analytics
install: 4,734 (30 days), 17,069 (90 days), 70,323 (365 days)
install-on-request: 4,434 (30 days), 15,988 (90 days), 65,300 (365 days)
build-error: 0 (30 days)

image

image

❯ brew info bazel
bazel: stable 3.1.0 (bottled)
Google's own build tool
https://bazel.build/
Not installed
From: https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git/Formula/bazel.rb
==> Dependencies
Build: [email protected] ✔
Required: openjdk@11 ✘
==> Requirements
Required: macOS >= 10.10 ✔
==> Analytics
install: 4,734 (30 days), 17,069 (90 days), 70,323 (365 days)
install-on-request: 4,434 (30 days), 15,988 (90 days), 65,300 (365 days)
build-error: 0 (30 days)
@googlebot
Copy link

Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please visit https://cla.developers.google.com/ to sign.

Once you've signed (or fixed any issues), please reply here with @googlebot I signed it! and we'll verify it.


What to do if you already signed the CLA

Individual signers
Corporate signers

ℹ️ Googlers: Go here for more info.

@NashMiao
Copy link
Author

@googlebot I signed it!

@googlebot
Copy link

CLAs look good, thanks!

ℹ️ Googlers: Go here for more info.

@jin jin requested review from philwo and tetromino and removed request for aiuto and gregestren May 15, 2020 09:55
@jin jin added the area-EngProd Bazel CI, infrastructure, bootstrapping, release, and distribution tooling label May 15, 2020
@tetromino
Copy link
Contributor

The actual problem appears to be that https://releases.bazel.build is not accessible from China.

The two formulas (bazelbuild/tap/bazel vs. the default bazel) are actually different - bazelbuild/tap/bazel installs our official binary, the default bazel formula installs a binary built by the Homebrew project from source. I think for now we want to encourage the bazelbuild/tap one (since we can better control that our users get a good experience) - see #11243.

But obviously we need to fix connectivity from China.

@NashMiao
Copy link
Author

NashMiao commented May 15, 2020

Thank you for your answer. After reading #11243, I fully agree with you. Now, maybe the server's network needs to be improved.

@NashMiao NashMiao closed this May 15, 2020
tetromino added a commit to tetromino/homebrew-tap that referenced this pull request May 15, 2020
Users have reported that downloads from https://releases.bazel.build became
inaccessible from China: bazelbuild/bazel#11403

Verified using https://www.websitepulse.com/tools/china-firewall-test that
downloads from github should work (and downloads from releases.bazel.build
don't).
@philwo philwo added the team-OSS Issues for the Bazel OSS team: installation, release processBazel packaging, website label Jun 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-EngProd Bazel CI, infrastructure, bootstrapping, release, and distribution tooling cla: yes team-OSS Issues for the Bazel OSS team: installation, release processBazel packaging, website
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants