cmake-gui: Change --install to use /usr/local/bin by default (#15627)
In commit v3.3.0-rc1~49^2~2 (cmake-gui: Add --install option to add command-line tools on OS X, 2015-05-19) the option default was set to /usr/bin because that is where the old command line install dialog placed the symlinks. A better default is /usr/local/bin because it is meant for locally installed software rather than Apple-installed tools. Also, as of OS X El Capitan, special privileges are required even for root to modify /usr/bin but not /usr/local/bin.
This commit is contained in:
parent
d9b974b18e
commit
d2cf92ec26
|
@ -84,7 +84,7 @@ int main(int argc, char** argv)
|
||||||
#if defined(Q_OS_MAC)
|
#if defined(Q_OS_MAC)
|
||||||
if (argc2 == 2 && strcmp(argv2[1], "--install") == 0)
|
if (argc2 == 2 && strcmp(argv2[1], "--install") == 0)
|
||||||
{
|
{
|
||||||
return cmOSXInstall("/usr/bin");
|
return cmOSXInstall("/usr/local/bin");
|
||||||
}
|
}
|
||||||
if (argc2 == 2 && cmHasLiteralPrefix(argv2[1], "--install="))
|
if (argc2 == 2 && cmHasLiteralPrefix(argv2[1], "--install="))
|
||||||
{
|
{
|
||||||
|
|
|
@ -425,7 +425,7 @@ void CMakeSetupDialog::doInstallForCommandLine()
|
||||||
"\n"
|
"\n"
|
||||||
" PATH=\"%1\":\"$PATH\"\n"
|
" PATH=\"%1\":\"$PATH\"\n"
|
||||||
"\n"
|
"\n"
|
||||||
"Or, to install symlinks to '/usr/bin', run:\n"
|
"Or, to install symlinks to '/usr/local/bin', run:\n"
|
||||||
"\n"
|
"\n"
|
||||||
" sudo \"%2\" --install\n"
|
" sudo \"%2\" --install\n"
|
||||||
"\n"
|
"\n"
|
||||||
|
|
Loading…
Reference in New Issue