# Fire: Building solution containing watchkit app

**URL:** https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955
**Category:** EBuild
**Created:** [November 29, 2017, 3:46am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955 "2017-11-29T03:46:08Z")
**Posts on this page:** 20
**Page:** 5

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 10, 2017, 10:45pm UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/81 "2017-12-10T22:45:13Z")

</div>

I think that’s it.

Looking at the watchos binary.

The one I created with xbuild is Mach-O executable arm\_v7k and the one with ebuild is x86\_64 and i386.

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 10, 2017, 11:33pm UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/82 "2017-12-10T23:33:23Z")

</div>

Ive sent you the log output and the app it created.

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [December 11, 2017, 1:40am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/83 "2017-12-11T01:40:23Z")

</div>

k, will have a look in the am…

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [December 11, 2017, 2:08am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/84 "2017-12-11T02:08:52Z")

</div>

This should not cause a problem per se (ie its still a bug), but this is freaky, from the command line. Can you check what CrossBox Device is selected for each of your projects? How many projects to you have in the SLN?

`--setting:Device=True --setting:Simulator=True --setting:Device=True --setting:Simulator=True --setting:Device=True --setting:Simulator=True`

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [December 11, 2017, 2:18am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/85 "2017-12-11T02:18:00Z")

</div>

Fixed, I think.

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 11, 2017, 2:19am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/86 "2017-12-11T02:19:40Z")

</div>

I have 17 projects. Its 2 ios and 2 watch apps, the rest are shared projects.

How do I check from the command line ?

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [December 11, 2017, 2:23am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/87 "2017-12-11T02:23:25Z")

</div>

Workaround: don’t do a _rebuild_/ Do a clean, then a regular build. that should only build Device, not both, and avoid the bug.

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 11, 2017, 3:07am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/88 "2017-12-11T03:07:30Z")

</div>

That fixed the deployment issues. I have everything installed.

Unfortunately the apps on the watch are crashing on startup. I’m also back to not having access to the watch log s.  
I’m not sure what I did last time to get them to appear. My watch shows in console but has an exclamation mark against it.

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 11, 2017, 5:57am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/89 "2017-12-11T05:57:01Z")

</div>

A file called Partial.plist also appears to be missing from the watchos app. It looks like it contains icon information.

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [December 11, 2017, 11:02am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/90 "2017-12-11T11:02:08Z")

</div>

you don’t want the partial.plist. that was always a bug/artifact of msbuild that those made it in. the partial plasts get merged into the main info.plist.

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [December 11, 2017, 11:03am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/91 "2017-12-11T11:03:31Z")

</div>

> [@](#):
>
> My watch shows in console but has an exclamation mark against it.

ok. that‘ll be an issue unrelated to Elements, im afraid.

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 22, 2017, 6:20am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/92 "2017-12-22T06:20:28Z")

</div>

Finally able to get something in console. When I attempt to launch the app on the watch I get this

Dec 22 00:48:28 John-s-AppleWatch iSailedWatchOSExtension(Foundation)[29668] : \*\*\* Assertion failure in void \_UIApplicationMainPreparations(int, char \*\*, NSString \*\_\_strong, NSString \*\_\_strong)(), /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKit/UIKit-3698.33.3.601/UIApplication.m:3851  
Dec 22 00:48:28 John-s-AppleWatch iSailedWatchOSExtension(CoreFoundation)[29668] : \*\*\* Terminating app due to uncaught exception ‘NSInternalInconsistencyException’, reason: ‘Unable to instantiate the UIApplication subclass instance. No class named SPApplication is loaded.’

I haven’t changed any of the classnames, so I’m not sure where it gets SPApplication from.

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 29, 2017, 4:53am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/93 "2017-12-29T04:53:54Z")

</div>

I dont suppose you have been able to look at this issue ?

Also using the latest external deployment is failing. It looks like this is the error.

```
                           -- Task RemObjects.EBuild.Elements.ElementsPreparePlatforms skipped for iSailedWatchOS.
                           -> Task RemObjects.EBuild.Elements.ElementsCheckForTargetlessReferences started for iSailedWatchOS.
                           <- Task RemObjects.EBuild.Elements.ElementsCheckForTargetlessReferences finished for iSailedWatchOS, took 0.0002s (0.0002s).
                           -> Target Toffee-watchOS started.
                              -> Task RemObjects.EBuild.Elements.ElementsResolveToffeeReferencesForTarget started for iSailedWatchOS, Toffee-watchOS.
D: Using target Toffee-watchOS of project reference iSailedWatchOS Extension
D: Adding AppResourceReference-Device '/Users/JohnMoshakis/Library/Application Support/RemObjects/EBuild/Obj/iSailedWatchOS Extension-B24882C1-C836-49ED-A9FA-7E6C6BA94ED5/Debug/Toffee-watchOS/Device/iSailedWatchOSExtension.appex'
                              <- Task RemObjects.EBuild.Elements.ElementsResolveToffeeReferencesForTarget failed for iSailedWatchOS, Toffee-watchOS, took 0.0141s (0.0148s).
                           <- Target Toffee-watchOS failed.
                        <- Task RemObjects.EBuild.Elements.ElementsResolveReferences failed for iSailedWatchOS, took 0.0163s (0.0167s).

```

Thanks,  
John

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [December 29, 2017, 11:58am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/94 "2017-12-29T11:58:59Z")

</div>

> [@JohnMoshakis](#):
>
> I dont suppose you have been able to look at this issue ?

Nothing actionable for me at this point really, afaict ☹

> [@JohnMoshakis](#):
>
> Also using the latest external deployment is failing. It looks like this is the error.

hm, thats a build error, not a deployment error though. Looks like something goes wring with the project reference (could be a regression from my other non-extension-related project ref fixes). does this repro with the version of your project I have?

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [December 29, 2017, 12:14pm UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/95 "2017-12-29T12:14:07Z")

</div>

> [@mh](#):
>
> hm, thats a build error, not a deployment error though. Looks like something goes wring with the project reference (could be a regression from my other non-extension-related project ref fixes). does this repro with the version of your project I have?

Reproduced and fixed for `20171229-121846-elements-develop`. was indeed a regression from fixing/implementing regular project refs for iOS.

For the other issue, we’ll have to work together to gather more details. With the info I have so far, I can’t say why it would (or indeed on what it does) crash…

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 29, 2017, 10:35pm UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/96 "2017-12-29T22:35:23Z")

</div>

I installed 130910.

Im getting

65% PreflightingApplication  
65% InstallingEmbeddedProfile  
70% VerifyingApplication  
Error: AMDeviceInstallApplication | e8008016 (-402620394)  
DetailedError: Failed to verify code signature: the executable was signed with invalid entitlements.  
Deployment of app bundle failed.

| default | 17:26:02.923985 -0500 | crossboxhelper | AMDeviceInstallApplication (thread 0x7fff8b40a340): ENTRY |
| --- | --- | --- | --- |
| default | 17:26:04.175170 -0500 | crossboxhelper | AMDErrorForMobileInstallationCallbackDict (thread 0x7fff8b40a340): GOT AN ERROR 0xe800003a |
| default | 17:26:04.175276 -0500 | crossboxhelper | perform\_command (thread 0x7fff8b40a340): There was an error communicating with the service agent: 0xe8008016 |
| default | 17:26:04.175345 -0500 | crossboxhelper | AMDeviceSecureInstallApplication (thread 0x7fff8b40a340): Old style install failed for (PublicStaging/SailingLogiOS.app) |
| default | 17:26:04.175438 -0500 | crossboxhelper | AMDeviceSecureInstallApplication (thread 0x7fff8b40a340): Could not install package on device: e8008016 |

The firehose page could be very dangerous. I can look at through all the commits on the page and if it has your name and ebuild I feel compelled to download it 🙂

---

<div class="post-metadata">

### Author: ![mh](https://talk.remobjects.com/user_avatar/talk.remobjects.com/mh/32/18050_2.png) [@mh](https://talk.remobjects.com/u/mh)
#### Post date: [December 29, 2017, 10:48pm UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/97 "2017-12-29T22:48:11Z")

</div>

Ok, i highly doubt that something on our side changed that broke this. Chances are something IS off with tour profiles/certs/devices. But impossible to say…

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [December 30, 2017, 6:16am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/98 "2017-12-30T06:16:48Z")

</div>

it looks as though everything is still valid.

I see this in the iphone console

| default | 01:12:14.393375 -0500 | installd | 0x16f01f000 -[MIClientConnection \_doInstallationForURL:withOptions:completion:]: Install of “/var/mobile/Media/PublicStaging/SailingLogiOS.app” type Developer (LSInstallType = (null)) requested by lsd (pid 101) |
| --- | --- | --- | --- |
| default | 01:12:14.484111 -0500 | assertiond | Request to create termination assertion \<BKSTerminationAssertionCreateEvent: 0x10112f580; Identifier: 1301-DB4D9A75-FEA7-40CF-B74F-8C7B1A83A4AD; Name: FBSApplicationTerminationAssertion; Target BundleID: com.moshine.isailed; Efficacy: Unconditional\> from client \<BKClientHandle: 0x10112d8d0; installd:1301; connections: 1\> |
| default | 01:12:14.546373 -0500 | installd | Acquired termination assertion for event \<BKSTerminationAssertionCreateEvent: 0x155e1ee40; Identifier: 1301-DB4D9A75-FEA7-40CF-B74F-8C7B1A83A4AD; Name: FBSApplicationTerminationAssertion; Target BundleID: com.moshine.isailed; Efficacy: Unconditional\> |
| default | 01:12:14.880465 -0500 | installd | 0x16f01f000 -[MIInstaller performInstallationWithError:]: Installing |
| default | 01:12:14.884238 -0500 | installd | com.moshine.isailed:7:7:1:1:Start : Install (Promote From Placeholder) |
| default | 01:12:15.315731 -0500 | installd | [leaf CheckLeafMarkerOid IssuerCommonName SubjectCommonName] |
| default | 01:12:15.440957 -0500 | installd | [leaf CheckLeafMarkerOid IssuerCommonName SubjectCommonName] |
| default | 01:12:15.589004 -0500 | installd | [leaf CheckLeafMarkerOid IssuerCommonName SubjectCommonName] |
| default | 01:12:15.978996 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.979189 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.979355 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.979572 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.979713 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.980034 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.980127 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.980298 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.980497 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.980667 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.980937 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.981060 -0500 | installd | entitlement ‘’ has value not permitted by provisioning profile ‘’ |
| default | 01:12:15.987789 -0500 | installd | 0x16f01f000 +[MICodeSigningVerifier \_validateSignatureAndCopyInfoForURL:withOptions:error:]: 147: Failed to verify code signature of /private/var/installd/Library/Caches/com.apple.mobile.installd.staging/temp.MYtlCV/extracted/SailingLogiOS.app : 0xe8008016 (The executable was signed with invalid entitlements.) |
| default | 01:12:15.988284 -0500 | installd | 0x16f01f000 -[MIInstaller performInstallationWithError:]: Verification stage failed |
| default | 01:12:16.759870 -0500 | installd | com.moshine.isailed:7:7:2:0:Fail (End) : Install (Promote From Placeholder) |
| default | 01:12:16.776340 -0500 | mobile\_installation\_proxy | 0x16f8db000 handle\_install: Installation failed: Error Domain=MIInstallerErrorDomain Code=13 “Failed to verify code signature of /private/var/installd/Library/Caches/com.apple.mobile.installd.staging/temp.MYtlCV/extracted/SailingLogiOS.app : 0xe8008016 (The executable was signed with invalid entitlements.)” UserInfo={LibMISErrorNumber=-402620394, LegacyErrorString=ApplicationVerificationFailed, SourceFileLine=147, FunctionName=+[MICodeSigningVerifier \_validateSignatureAndCopyInfoForURL:withOptions:error:], NSLocalizedDescription=Failed to verify code signature of /private/var/installd/Library/Caches/com.apple.mobile.installd.staging/temp.MYtlCV/extracted/SailingLogiOS.app : 0xe8008016 (The executable was signed with invalid entitlements.)} |

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [January 1, 2018, 10:49pm UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/99 "2018-01-01T22:49:58Z")

</div>

Can you install onto your iphone ?

It seems ok with xcode.

---

<div class="post-metadata">

### Author: ![JohnMoshakis](https://talk.remobjects.com/user_avatar/talk.remobjects.com/johnmoshakis/32/2286_2.png) [@JohnMoshakis](https://talk.remobjects.com/u/JohnMoshakis)
#### Post date: [January 7, 2018, 6:26am UTC](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955/100 "2018-01-07T06:26:19Z")

</div>

I created a new provisioning profile and was able to deploy without any problems in xcode.

Using that profile and the internal tools with Fire I get

Error: AMDeviceInstallApplication | e8000067 (-402653081)  
Deployment of app bundle failed.

I also see these errors from crossboxhelper

| default | 01:25:34.707956 -0500 | crossboxhelper | skipping upgrade for locked keychain /Users/JohnMoshakis/Library/Keychains/Microsoft\_Intermediate\_Certificates |
| --- | --- | --- | --- |
| default | 01:25:34.709600 -0500 | crossboxhelper | skipping upgrade for locked keychain /Users/JohnMoshakis/Library/Keychains/Microsoft\_Intermediate\_Certificates |
| default | 01:25:34.711091 -0500 | crossboxhelper | skipping upgrade for locked keychain /Users/JohnMoshakis/Library/Keychains/Microsoft\_Intermediate\_Certificates |
| default | 01:25:39.082207 -0500 | crossboxhelper | AMDeviceTransferApplication (thread 0x7fff92d75340): ENTRY |
| default | 01:25:39.092321 -0500 | crossboxhelper | nuke\_path (thread 0x7fff92d75340): AFCRemovePath of ‘PublicStaging/DarkSkySimpleApp.app’ returned 8 |
| default | 01:25:39.723537 -0500 | crossboxhelper | AMDeviceInstallApplication (thread 0x7fff92d75340): ENTRY |
| default | 01:25:39.942635 -0500 | crossboxhelper | AMDErrorForMobileInstallationCallbackDict (thread 0x7fff92d75340): GOT AN ERROR 0xe8000067 |
| default | 01:25:39.942719 -0500 | crossboxhelper | perform\_command (thread 0x7fff92d75340): There was an error communicating with the service agent: 0xe8000067 |
| default | 01:25:39.942783 -0500 | crossboxhelper | AMDeviceSecureInstallApplication (thread 0x7fff92d75340): Old style install failed for (PublicStaging/DarkSkySimpleApp.app) |
| default | 01:25:39.942871 -0500 | crossboxhelper | AMDeviceSecureInstallApplication (thread 0x7fff92d75340): Could not install package on device: kAMDAPIInternalError |
| default | 01:32:43.618736 -0500 | crossboxhelper | UNIX error exception: 17 |
| default | 01:32:43.626956 -0500 | crossboxhelper | UNIX error exception: 17 |
| default | 01:32:43.633170 -0500 | crossboxhelper | UNIX error exception: 17 |
| default | 01:32:43.640533 -0500 | crossboxhelper | UNIX error exception: 17 |
| default | 01:32:43.647156 -0500 | crossboxhelper | UNIX error exception: 17 |
| default | 01:32:43.653246 -0500 | crossboxhelper | UNIX error exception: 17 |
| default | 01:32:43.763845 -0500 | crossboxhelper | skipping upgrade for locked keychain /Users/JohnMoshakis/Library/Keychains/Microsoft\_Intermediate\_Certificates |

and this from the iphone console

0x16f5c7000 handle\_install: Installation failed: Error Domain=MIInstallerErrorDomain Code=13 “Failed to verify code signature of /private/var/installd/Library/Caches/com.apple.mobile.installd.staging/temp.9p1ouD/extracted/DarkSkySimpleApp.app : 0xe8008016 (The executable was signed with invalid entitlements.)” UserInfo={LibMISErrorNumber=-402620394, LegacyErrorString=ApplicationVerificationFailed, SourceFileLine=147, FunctionName=+[MICodeSigningVerifier \_validateSignatureAndCopyInfoForURL:withOptions:error:], NSLocalizedDescription=Failed to verify code signature of /private/var/installd/Library/Caches/com.apple.mobile.installd.staging/temp.9p1ouD/extracted/DarkSkySimpleApp.app : 0xe8008016 (The executable was signed with invalid entitlements.)}

[Previous page](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955.md?page=4)

[Next page](https://talk.remobjects.com/t/fire-building-solution-containing-watchkit-app/14955.md?page=6)
