0

Whenever I try to run g++ in macos monterey it shows invalid active developer path

g++ --version
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
  • Possibly [related](https://apple.stackexchange.com/questions/254380/why-am-i-getting-an-invalid-active-developer-path-when-attempting-to-use-git-a) as is [this](https://stackoverflow.com/questions/52522565/git-is-not-working-after-macos-update-xcrun-error-invalid-active-developer-pa). – G.M. Nov 11 '21 at 13:08
  • Update xcode or the command line tools – Alan Birtles Nov 11 '21 at 13:12
  • Probably both just to be safe. They created a much clearer separation with I think Big Sur. If I were picking just one, I'd try the CLT first. – sweenish Nov 11 '21 at 13:20
  • If you are trying to run *actual* `g++`, you may want to `brew install gcc` which will install 11.2.0. I presume you are aware of [brew](https://brew.sh/) for macOS. – Eljay Nov 11 '21 at 13:24

0 Answers0