In iossim, use default home directory if no -u override is given.
commit506ceebdd613e5f0d6d0bb942871f8e4f039aa86
authorlliabraa@chromium.org <lliabraa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Wed, 9 Jul 2014 22:12:14 +0000 (9 22:12 +0000)
committerlliabraa@chromium.org <lliabraa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Wed, 9 Jul 2014 22:12:14 +0000 (9 22:12 +0000)
treeddcbc785b5d2045ea360cf9e2e37056b710acc87
parentfd98b61111df70659bdee313c12601d9531df077
In iossim, use default home directory if no -u override is given.

With Xcode 6, the home directory of the iOS Simulator and iossim
processes must match so that the iOS Simulator can find the SimDevice
object created by iossim. Since the existing behavior of iossim is to
create a new, random, home directory on each run (if no -u value is
specified on the command line), the home directories will be  mismatched
if iossim is launched multiple times without killing the iOS Simulator
in between runs.

The fix here is to only override the home directory in iossim if -u
is specified. Since this will often reuse the default SimDeviceSet
(at ~/Library/Developer/CoreSimulator/Devices), functionality
is also changed to reuse an existing SimDevice if possible (though
iossim will create a SimDevice if necessary).

BUG=None
TBR=rohitrao

Review URL: https://codereview.chromium.org/382563002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@282139 0039d316-1c4b-4281-b951-d872f2087c98
testing/iossim/iossim.mm