Skip to content

Commit

Permalink
Move the "run" alias from process launch --shell to process launch --…
Browse files Browse the repository at this point in the history
…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
Enrico Granata committed Sep 22, 2015
1 parent 871b2e5 commit f515729
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lldb/source/Interpreter/CommandInterpreter.cpp
Original file line number Diff line number Diff line change
@@ -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);

0 comments on commit f515729

Please sign in to comment.