summaryrefslogtreecommitdiffstats
path: root/lldb/source/Interpreter/CommandInterpreter.cpp
diff options
context:
space:
mode:
authorEnrico Granata <egranata@apple.com>2015-09-22 22:57:12 +0000
committerEnrico Granata <egranata@apple.com>2015-09-22 22:57:12 +0000
commitf515729a0711a1ee8bb56b0e9c993a991b87a5ab (patch)
treefc3710ba151518d50d314e43cb2179aaee932ab4 /lldb/source/Interpreter/CommandInterpreter.cpp
parent871b2e5e3078cf0c497f300739ee11909091b53e (diff)
downloadbcm5719-llvm-f515729a0711a1ee8bb56b0e9c993a991b87a5ab.tar.gz
bcm5719-llvm-f515729a0711a1ee8bb56b0e9c993a991b87a5ab.zip
Move the "run" alias from process launch --shell to process launch --shell-expand-args when building on OS X
The argdumper-based launching is more friendly to System Integrity Protection, and will work on older releases of OS X as well Leave non-Apple builds alone llvm-svn: 248338
Diffstat (limited to 'lldb/source/Interpreter/CommandInterpreter.cpp')
-rw-r--r--lldb/source/Interpreter/CommandInterpreter.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/lldb/source/Interpreter/CommandInterpreter.cpp b/lldb/source/Interpreter/CommandInterpreter.cpp
index fa1c8af9091..498a63e86ad 100644
--- a/lldb/source/Interpreter/CommandInterpreter.cpp
+++ b/lldb/source/Interpreter/CommandInterpreter.cpp
@@ -352,11 +352,19 @@ CommandInterpreter::Initialize ()
#if defined (__arm__) || defined (__arm64__) || defined (__aarch64__)
ProcessAliasOptionsArgs (cmd_obj_sp, "--", alias_arguments_vector_sp);
#else
+ #if defined(__APPLE__)
+ std::string shell_option;
+ shell_option.append("--shell-expand-args");
+ shell_option.append(" true");
+ shell_option.append(" --");
+ ProcessAliasOptionsArgs (cmd_obj_sp, shell_option.c_str(), alias_arguments_vector_sp);
+ #else
std::string shell_option;
shell_option.append("--shell=");
shell_option.append(HostInfo::GetDefaultShell().GetPath());
shell_option.append(" --");
ProcessAliasOptionsArgs (cmd_obj_sp, shell_option.c_str(), alias_arguments_vector_sp);
+ #endif
#endif
AddAlias ("r", cmd_obj_sp);
AddAlias ("run", cmd_obj_sp);
OpenPOWER on IntegriCloud