Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ios-deploy: Unable to locate DeviceSupport directory #4326

Closed
drewwarren opened this issue Jun 2, 2016 · 10 comments
Closed

ios-deploy: Unable to locate DeviceSupport directory #4326

drewwarren opened this issue Jun 2, 2016 · 10 comments

Comments

@drewwarren
Copy link

@drewwarren drewwarren commented Jun 2, 2016

Steps to Reproduce

I was attempting to flutter run with xcode 7.2.something and I would see

Starting debug of iPhone 5s (GSM) 'drewwarren’s iPhone' (4127c6ffa53f153512916da5fe2a3afac8d23798) connected through USB...
2016-06-02 11:17:59.787 ios-deploy[4022:2958268] [ !! ] Unable to locate DeviceSupport directory. This probably means you don't have Xcode installed, you will need to launch the app manually and logging output will not be shown!
Could not install ios/.generated/build/Release-iphoneos/Runner.app on 4127c6ffa53f153512916da5fe2a3afac8d23798.
Error running application on drewwarren’s iPhone.

This says I might not have Xcode installed, but I did. flutter doctor made everything look okay for Xcode.

When I was in this state if I attempted to open FlutterApplication.xcodeproj in Xcode and click the play button I would see Could not find Developer Disk Image.

@chinmaygarde chinmaygarde self-assigned this Jun 2, 2016
@chinmaygarde chinmaygarde removed their assignment Sep 9, 2016
@smrtsmrf

This comment has been minimized.

Copy link

@smrtsmrf smrtsmrf commented Jun 9, 2017

I get the same issue, but I'm using the latest version of XCode. When I try to run it in XCode, I get a white screen on my device and this in XCode. Weird thing is that it was working the other day.
screen shot 2017-06-09 at 4 35 29 pm

@cbracken

This comment has been minimized.

Copy link
Member

@cbracken cbracken commented Jun 13, 2017

@smrtsmrf can you check whether you're using Xcode 8.3.3? If so, it appears Xcode has changed the format it uses for the iOS DeviceSupport directory which is causing ios-deploy (one of our dependencies for launching iOS apps on devices) to get confused.

Upstream ios-deploy issue is: ios-control/ios-deploy#292

We can see what's in the iOS device support dir via:

ls "$(xcrun --sdk iphoneos --show-sdk-platform-path)/DeviceSupport"

With Xcode 8.3.3, I see:

drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:27 10.0/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:29 10.1/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:26 10.2/
drwxrwxr-x   4 cbracken  eng  136 26 Apr 19:26 10.3.1 (14E8301)/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:26 8.0/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:28 8.1/
drwxrwxr-x   4 cbracken  eng  136 10 May 22:21 8.2/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:27 8.3/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:28 8.4/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:27 9.0/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:26 9.1/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:28 9.2/
drwxrwxr-x   4 cbracken  eng  136  2 Feb 07:28 9.3/

Looks like a quick hacky fix is:

cd "$(xcrun --sdk iphoneos --show-sdk-platform-path)/DeviceSupport"
ln -s 10.3.1\ \(14E8301\) 10.3

If you installed Xcode via the App Store (in which case, these files will all be owned by root), you may get a permission denied error and may need to run ln as root:

sudo ln -s 10.3.1\ \(14E8301\) 10.3
@cbracken cbracken changed the title Error message misleading when xcode needs updating ios-deploy: Unable to locate DeviceSupport directory Jun 13, 2017
@smrtsmrf

This comment has been minimized.

Copy link

@smrtsmrf smrtsmrf commented Jun 13, 2017

@cbracken thanks, that did the trick. 👍

@cbracken

This comment has been minimized.

Copy link
Member

@cbracken cbracken commented Jun 13, 2017

Thanks for confirming! Will keep this issue open for reference until a fix goes into ios-deploy.

@davorpeic

This comment has been minimized.

Copy link

@davorpeic davorpeic commented Aug 2, 2017

Thanks @cbracken your solution fixed my 10.3.3 even I added particular subversion. There is more talk about this on ios-deploy repo ios-control/ios-deploy#292

dp

@sethladd

This comment has been minimized.

Copy link
Contributor

@sethladd sethladd commented Sep 3, 2017

We might want to bump up the priority of this fix. The workaround has 12 thumbs up, and the workaround is still required. Maybe our tool can just make the symlink? Or, print out a link to this bug?

@cbracken

This comment has been minimized.

Copy link
Member

@cbracken cbracken commented Sep 4, 2017

@sethladd We can't autogen the symlink since it requires root privileges but we can definitely output the one-line command to do it. I'll land a doctor check (and run it at build time as well) that outputs this.

cbracken added a commit to cbracken/flutter that referenced this issue Sep 5, 2017
ios-deploy 1.9.2 includes fixes for a common source of Xcode breakage
(flutter#4326) with Xcode 8.3.3 + iOS 10.3.3, and is required to
to support Xcode 9 (flutter#11875).
cbracken added a commit to cbracken/flutter that referenced this issue Sep 5, 2017
ios-deploy 1.9.2 includes fixes for a common source of Xcode breakage
(flutter#4326) with Xcode 8.3.3 + iOS 10.3.3, and is required to
to support Xcode 9 (flutter#11875).
cbracken added a commit that referenced this issue Sep 5, 2017
ios-deploy 1.9.2 includes fixes for a common source of Xcode breakage
(#4326) with Xcode 8.3.3 + iOS 10.3.3, and is required to
to support Xcode 9 (#11875).
@cbracken

This comment has been minimized.

Copy link
Member

@cbracken cbracken commented Sep 6, 2017

ios-deploy 1.9.2 was released today and includes a fix for this issue. I've added a doctor check to bump to that version.

@cbracken cbracken closed this Sep 6, 2017
@blackdynamo

This comment has been minimized.

Copy link

@blackdynamo blackdynamo commented Oct 30, 2017

I am still having this issue in 1.9.2 with Xcode 9.0.1. My device is running 11.0.3 (15A432).

I have also tried using the solution to add the symlinks but doesn't seem to work for me. Create a symlink for 11.0.3 (15A432) -> 11.0 (15A372)

------ Debug phase ------
Starting debug of 38813d6fae7464bb3f099582ea78ce53955e8632 (N66mAP, iPhone 6s Plus, iphoneos, arm64) a.k.a. 'iPhone' connected through USB...
[  0%] Looking up developer disk image
[ 95%] Developer disk image mounted successfully
2017-10-30 16:25:46.621 ios-deploy[44705:5930783] [ !! ] Unable to locate DeviceSupport directory with suffix 'Symbols'. This probably means you don't have Xcode installed, you will need to launch the app manually and logging output will not be shown!
/Applications/Xcode.app/Contents/Developer/platforms/iPhoneOS.platform/DeviceSupport$ ls -la
total 0
drwxrwxr-x  17 root  wheel  544 30 Oct 16:30 .
drwxr-xr-x  10 root  wheel  320 10 Oct 15:23 ..
drwxrwxr-x   4 root  wheel  128 28 Jul 16:14 10.0
drwxrwxr-x   4 root  wheel  128 28 Jul 16:15 10.1
drwxrwxr-x   4 root  wheel  128 28 Jul 16:12 10.2
drwxrwxr-x   4 root  wheel  128 28 Jul 16:13 10.3
drwxrwxr-x   5 root  wheel  160 30 Oct 16:13 11.0 (15A372)
lrwxr-xr-x   1 root  wheel   13 30 Oct 16:30 11.0.3 (15A432) -> 11.0 (15A372)
drwxrwxr-x   4 root  wheel  128 28 Jul 16:12 8.0
drwxrwxr-x   4 root  wheel  128 28 Jul 16:12 8.1
drwxrwxr-x   4 root  wheel  128 10 Oct 15:55 8.2
drwxrwxr-x   4 root  wheel  128 28 Jul 16:13 8.3
drwxrwxr-x   4 root  wheel  128 28 Jul 16:14 8.4
drwxrwxr-x   4 root  wheel  128 28 Jul 16:12 9.0
drwxrwxr-x   4 root  wheel  128 28 Jul 16:12 9.1
drwxrwxr-x   4 root  wheel  128 28 Jul 16:13 9.2
drwxrwxr-x   4 root  wheel  128 28 Jul 16:14 9.3
@blackdynamo

This comment has been minimized.

Copy link

@blackdynamo blackdynamo commented Nov 2, 2017

Just as a follow up, if you are having this issue, the files are probably missing from this path:

~/Library/Developer/Xcode/iOS\ DeviceSupport/

If that is the case, which fixed things for me, make sure your phone is attached to your mac and open xcode. The files will automatically appear and things should work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
8 participants
You can’t perform that action at this time.