kpt: homebrew installation fails on macOS 11 (Big Sur)

I’m running the beta version of macOS 11, and have been running into issue trying to brew upgrade to the latest version. Wanted to file this issue early since there’s likely plenty of time before Big Sur exits beta 😃

==> Upgrading 1 outdated package:
googlecontainertools/kpt/kpt 0.32.0 -> 0.33.0
==> Upgrading googlecontainertools/kpt/kpt 0.32.0 -> 0.33.0
==> Downloading https://github.com/GoogleContainerTools/kpt/archive/v0.33.0.tar.
Already downloaded: /Users/xander/Library/Caches/Homebrew/downloads/ac1b2a55ace325dc4b88fa6472234f6240ba15cd90ad89237df2812f6c8f5011--kpt-0.33.0.tar.gz
Error: Your CLT does not support macOS 11.0.
It is either outdated or was modified.
Please update your CLT or delete it if no updates are available.

About this issue

  • Original URL
  • State: open
  • Created 4 years ago
  • Reactions: 22
  • Comments: 34 (2 by maintainers)

Most upvoted comments

So, either try the new Xcode beta, or wait, I guess

Xcode 12.2 beta (12B5018i) has the same issue. Downloading & installing the CLTs didn’t solve the underlying error message.

Command Line Tools for Xcode 12.2 beta 2 contains required SDK (MacOSX11.0.sdk).

Re: Xcode 12.2 beta - could be. I think it’s 100 gigabytes unpacked or something. One of my old iMacs has 120 gb, so it’s easier said than done. But I believe I’ve tried the 12.2 beta without success on another machine. But could be I messed something up.

You don’t have to download the whole Xcode app, just “Command Line Tools for Xcode 12.2 beta 2” which can be found on https://developer.apple.com/download/more/ - it’s only ~450MB.

I just installed the mentioned command line tools and brew doctor no longer shows warning about missing CLT. I also manage to install some stuff using brew without an issue.

Another solution:

sudo rm -rf /Library/Developer/CommandLineTools
sudo xcode-select --install

Thanks brew doctor for this hint.

This has resurfaced with the release of Xcode 12GM.

After update to Big Sur, when I run brew upgrade I had an error when install python 3.8.

[...]
Warning: Building python@3.8 from source:
  The bottle needs the Apple Command Line Tools to be installed.
  You can install them, if desired, with:
    xcode-select --install

==> Downloading https://files.pythonhosted.org/packages/a7/e0/30642b9c2df516506d
######################################################################## 100.0%
==> Downloading https://files.pythonhosted.org/packages/0b/f5/be8e741434a4bf4ce5
######################################################################## 100.0%
==> Downloading https://files.pythonhosted.org/packages/83/72/611c121b6bd15479cb
######################################################################## 100.0%
==> Downloading https://www.python.org/ftp/python/3.8.6/Python-3.8.6.tar.xz
######################################################################## 100.0%
Error: Your Xcode does not support macOS 11.0.
It is either outdated or was modified.
Please update your Xcode or delete it if no updates are available.

To Fixed it, I installed Command Line Tools for XCode 12.2 manually from https://developer.apple.com/download/more/?=for Xcode

It’s ok after.

So, either try the new Xcode beta, or wait, I guess

Xcode 12.2 beta (12B5018i) has the same issue. Downloading & installing the CLTs didn’t solve the underlying error message.

Another solution:

sudo rm -rf /Library/Developer/CommandLineTools
sudo xcode-select --install

Thanks brew doctor for this hint.

this saved my life, thank you kind user.

I can confirm as well.

I’m using Xcode 12 stable. After installing “Command Line Tools for Xcode 12.2 beta 3”, brew worked as expected.

Thank you so much. ıt’s time saver. Works perfectly. Here is the page: https://developer.apple.com/download/more/

Apple has just really gotten sloppy lately at releasing software. You don’t have to reinstall anything, just create an alias for MacOSX11.1.sdk. The SDKs are all symlinked to MacOSX.sdk. So this command is all you need.

sudo ln -s /Library/Developer/CommandLineTools/SDKs/MacOSX11.0.sdk /Library/Developer/CommandLineTools/SDKs/MacOSX11.1.sdk

Then switch to the CLT tools:

sudo xcode-select -s /Library/Developer/CommandlineTools/

EDIT: This works and doesn’t break anything.

Another solution:

sudo rm -rf /Library/Developer/CommandLineTools
sudo xcode-select --install

Thanks brew doctor for this hint.

Works for me. Reinstall CLT even if it’s the latest version. 此方法有效。即使已经是最新的 CLT 了,也需要把文件夹删除干净后重新装,文件签名都是一样的。很诡异。 https://v2ex.com/t/725768

I have just tested theCommand Line Tools for Xcode 12.3 beta with success: Apple Developer Portal

So, either try the new Xcode beta, or wait, I guess

Xcode 12.2 beta (12B5018i) has the same issue. Downloading & installing the CLTs didn’t solve the underlying error message.

Command Line Tools for Xcode 12.2 beta 2 contains required SDK (MacOSX11.0.sdk).

Re: Xcode 12.2 beta - could be. I think it’s 100 gigabytes unpacked or something. One of my old iMacs has 120 gb, so it’s easier said than done. But I believe I’ve tried the 12.2 beta without success on another machine. But could be I messed something up.

You don’t have to download the whole Xcode app, just “Command Line Tools for Xcode 12.2 beta 2” which can be found on https://developer.apple.com/download/more/ - it’s only ~450MB.

I just installed the mentioned command line tools and brew doctor no longer shows warning about missing CLT. I also manage to install some stuff using brew without an issue.

THIS WORKS FOR ME! I install Command_Line_Tools_for_Xcode_12.2. Thanks.

I can confirm as well.

I’m using Xcode 12 stable. After installing “Command Line Tools for Xcode 12.2 beta 3”, brew worked as expected.

I can confirm as well.

I’m using Xcode 12 stable. After installing “Command Line Tools for Xcode 12.2 beta 3”, brew worked as expected.

It works for me.

$ softwareupdate --list
Software Update Tool

Finding available software
Software Update found the following new or updated software:
* Label: Command Line Tools beta 3 for Xcode-12.2
	Title: Command Line Tools beta 3 for Xcode, Version: 12.2, Size: 440919K, Recommended: YES,
$ softwareupdate -i "Command Line Tools beta 3 for Xcode-12.2"

Another solution:

sudo rm -rf /Library/Developer/CommandLineTools
sudo xcode-select --install

Thanks brew doctor for this hint.

I had the lastest version installed, but removing and installing again worked well.

I just tested the command line tools 12.2 beta on one of the systems that refused to build emacs from source as described, and I’m happy to report that seems to have solved the issue.

I’ve got a few Big Sur systems by now, and Homebrew worked on some of them, but not on others. I’ve tried various combinations of installing Xcode 12, Xcode 12.2 beta and command line tools packages. There is no command line tools package for the 12.2 beta yet, so haven’t tested that of course. In the end I believe command line tools 12 is enough, with the proper symlinks in place. I took an image of symlinks from a Big Sur system where building emacs from source worked, and tried putting the same symlinks in place where it did not. When it did not work, it was because the configure script reported that the C compiler was not working. I’ll share screenshot with the symlinks from the system that worked (and which fixed one system where it did not, prior to adding similar symlinks): image I’m not claming this is a solution, or a good solution, but if it either helps somebody else in getting Homebrew working again, or if it help diagnose the underlying cause, that’s a good thing at least.

@mortent CLT is up to date - what seems to be interesting is that this is only affecting the kpt package on my end, so far I haven’t run into this upgrading any other brew package