第一次更新BigSur,在命令行运行gcc出现了xcrun: error: invalid active developer path, missing xcrun的报错。
经搜索,需要重新安装命令行工具Command Line Tools,是因为更新系统时原来的 Command Line Tools 被自动卸载了,所以重新安装即可。
在终端中执行如下指令即可
Command Line Tools包含的工具很多,如下所示
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90
| ar as asa bison BuildStrings c++ c89 c99 cc clang clang++ cmpdylib codesign_allocate CpMac cpp ctags ctf_insert DeRez dsymutil dwarfdump dyldinfo flex flex++ g++ gatherheaderdoc gcc gcov GetFileInfo git git-cvsserver git-receive-pack git-shell git-upload-archive git-upload-pack gm4 gnumake gperf hdxml2manxml headerdoc2html indent install_name_tool ld lex libtool lipo lldb lorder m4 make MergePef mig mkdep MvMac nasm ndisasm nm nmedit otool pagestuff projectInfo ranlib rebase redo_prebinding ResMerger resolveLinks Rez RezDet RezWack rpcgen segedit SetFile size SplitForks strings strip svn svnadmin svndumpfilter svnlook svnrdump svnserve svnsync svnversion unifdef unifdefall UnRezWack unwinddump what xml2man yacc
|