cargo build しようと思ったら下記のエラーがでた。

= note: some arguments are omitted. use --verbose to show all linker arguments
  = note: You have not agreed to the Xcode license agreements. Please run 'sudo xcodebuild -license' from within a Terminal window to review and agree to the Xcode and Apple SDKs license.

Xcode のライセンスに同意していないことが原因のようなので、下記コマンドで同意する。

$ sudo xcodebuild -license

同意表示の後、agree をきちんと打って同意完了。

ビルドが成功するようになった。