gcc 446 B

123456789101112131415
  1. #!/bin/bash
  2. set -o errexit -o pipefail
  3. if [[ "$OS" = "Darwin" ]]; then
  4. set +o pipefail
  5. if ! "xcode-select" --version &>/dev/null; then
  6. echo "Try again after installing the Xcode command-line tools by running: xcode-select --install"
  7. exit 1
  8. fi
  9. if ! xcodebuild -help &>/dev/null; then
  10. echo "Try again after agreeing to the Xcode license by running: sudo xcodebuild -license"
  11. exit 1
  12. fi
  13. else
  14. has gcc || gimme_pkg build-essential
  15. fi