diff options
authorAlexandru Croitor <>2017-08-16 15:09:04 +0200
committerLiang Qi <>2017-08-24 04:49:06 +0000
commitdfaabde5dcbdecf24d24dce4172c976687085bb6 (patch)
parentf1b1f3dc097defe3c7cb9a571598583376eddf5f (diff)
Enable developer mode on macOS platforms
Previously when a VM user tried to attach lldb to a process via ssh, lldb would fail with the following error message: "error: process exited with status -1 (unable to attach)". If this were done over VNC rather than ssh, the user would instead get a UI popup to enter a password to allow debugging the process. When trying to debug an application using Xcode for the first time, Xcode will offer to enable the so called "Developer Mode" which allows attaching a debugger without specifying a password every time. This change enables "Developer Mode", so that every VM user doesn't have to. Change-Id: Ie4e473a982c908afd456ac1773bbdaf4ce778094 Reviewed-by: Edward Welbourne <> Reviewed-by: Simon Hausmann <>
1 files changed, 8 insertions, 0 deletions
diff --git a/coin/provisioning/common/ b/coin/provisioning/common/
index 82c05a45..c6f00ee7 100755
--- a/coin/provisioning/common/
+++ b/coin/provisioning/common/
@@ -51,6 +51,7 @@ function InstallXCode()
+ ExceptionDeveloperMode=113
@@ -63,6 +64,9 @@ function InstallXCode()
echo "Accept license"
sudo xcodebuild -license accept || throw $ExceptionAcceptLicense
+ echo "Enabling developer mode, so that using lldb does not require interactive password entry"
+ sudo /usr/sbin/DevToolsSecurity -enable || throw $ExceptionDeveloperMode
echo "Xcode = $version" >> ~/versions.txt
catch || {
@@ -71,6 +75,10 @@ function InstallXCode()
echo "Failed to unarchive .cpio."
exit 1;
+ $ExceptionDeveloperMode)
+ echo "Failed to enable developer mode."
+ exit 1;
+ ;;
echo "Failed to accept license."
exit 1;