title: How can I do remote debugging in Xcode 4?
body: <p>Is there a way to do remote debugging in Xcode 4? The previous answers to this question were for Xcode 3 and Apple removed the specific debugging in Xcode guide that (I assume) covered remote debugging.</p>
  
  <p>For kicks I've been doing this with <code>lldb</code>, but if there's a way with <code>gdb</code> that'd be great. So far, I've been able to start a debug server on the remote machine like so</p>
  
  <blockquote>
    <p>/usr/bin/ssh -l ${REMOTE_USER} -f ${REMOTE_HOST} "/Developer/usr/bin/debugserver localhost:12345"</p>
  </blockquote>
  
  <p>And I can then manually log in with <code>lldb</code> from the Terminal and debug away. What I'd like to be able to do is at the very least start a bare <code>lldb</code> session within Xcode and then manually to <code>process connect connect://hostname:port</code>.</p>