Repository navigation
Docs: List Xcode Command Line Tools as a macOS prerequisite - #1677
Conversation
On macOS, /usr/bin/make is a shim for the Xcode Command Line Tools. Without them, make fails with an xcode-select error before it reads the Makefile. A sandbox that blocks /var/select/ gives the same error. Say so, and tell sandbox users to run the go build commands directly. Fixes rossoctl#1032 Assisted-By: Claude (Anthropic AI) <[email protected]> Signed-off-by: Hai Huang <[email protected]>
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 56 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
clawgenti
left a comment
There was a problem hiding this comment.
Summary
This is a small, accurate docs fix for #1032. /usr/bin/make really is an Xcode CLT shim, and the sandbox workaround is the one the reporter verified. The new bullet sits in the right place in Prerequisites. I have one non-blocking suggestion: "run the Makefile's go build commands directly" leaves out a few steps a sandboxed reader needs.
Author: huang195 (MEMBER — maintainer)
Areas reviewed: Docs (checked against Makefile at head and the issue thread)
Agent/IDE config (.claude/.vscode): none
Commits: 1 commit, all signed-off: yes
CI status: passing (CodeRabbit/Spellcheck skipped)
| - **Xcode Command Line Tools on macOS** (`xcode-select --install`). `/usr/bin/make` is a | ||
| shim for them, so without them `make` fails before it reads the Makefile. In a sandbox | ||
| that blocks `/var/select/`, the same `xcode-select: error` shows even when the tools are | ||
| installed. There, run the Makefile's `go build` commands directly. |
There was a problem hiding this comment.
suggestion: "Run the Makefile's go build commands directly" is a bit thin for someone in exactly this situation. The commands can't be copied as they stand:
cortexneeds its tag list first:TAGS=$(go -C scripts/profile-tags run . full), thencd cmd/cortex && GOWORK=off go build -tags "$TAGS" -o ../../bin/cortex .agentop's-ldflags "-X main.revision=..."comes fromgit rev-parse./usr/bin/gitis the same xcode-select shim, so in that sandbox the revision may come out empty. Plaingo buildmay also stop witherror obtaining VCS statusunless a non-shim git is on PATH or you pass-buildvcs=false. (The reporter probably had Homebrew git, so this is worth one clause, not a rewrite.)- Building is only half of
dev-install. Per the issue, installing (./bin/agentop setup --from ./bin --yes --no-modify-path --restart) still has to run from a host shell outside the sandbox.
One option is to say this in a sentence and point at the agentop / cortex targets in Makefile, or to add a short code block with the two builds and the host-side setup line.
Closes #1032.
What it does
Adds the Xcode Command Line Tools to the macOS prerequisites in
CONTRIBUTING.md:/usr/bin/makeis a shim for them. Without them,makefails with anxcode-select: errorbefore it reads the Makefile./var/select/gives the same error, even when the tools are installed. There, run the Makefile'sgo buildcommands directly. The reporter verified this workaround.Not done
gmakehint. aslom's comment says thatgmakealone is not sufficient on macOS./v1/versionendpoint, and no detection of the shim failure indev-install. The issue lists these as possible improvements, not as requirements.Assisted-By: Claude (Anthropic AI) [email protected]