Bug 34897 - Can't reference PCL from Apple Watch Extension
Summary: Can't reference PCL from Apple Watch Extension
Status: RESOLVED FIXED
Alias: None
Product: iOS
Classification: Xamarin
Component: General ()
Version: XI 9.3 (xcode 7.1 previews)
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: WatchOS 2.0
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2015-10-15 05:50 UTC by Tom Gilder
Modified: 2015-11-03 09:43 UTC (History)
5 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Tom Gilder 2015-10-15 05:50:51 UTC
With the latest preview release of watchOS 2 support, you can't reference PCL projects from the watchOS Extension project.

Error: "Incompatible target framework: .NETPortable,Version=v4.5,Profile=Profile78"


Repro:

1. Create iOS solution
2. Add watchOS 2 project
3. Add PCL project
4. Try to add reference to PCL from watchOS project


Xamarin Studio 5.10.0.913 
Xamarin.iOS 9.3.0.243
Mono 4.2.1
Comment 1 Jeffrey Stedfast 2015-10-16 13:07:39 UTC
I'm pretty sure that if Xamarin.WatchOS is supposed to be compatible with that PCL profile, then the Xamarin.iOS product needs to install the proper framework xml files, so I don't think this is a bug in Xamarin Studio.
Comment 2 Rolf Bjarne Kvinge [MSFT] 2015-10-16 14:02:53 UTC
@Jeff, what's the proper framework xml files? WatchOS does exactly the same thing iOS does.
Comment 3 Jeffrey Stedfast 2015-10-16 14:50:26 UTC
I don't know.
Comment 4 Rolf Bjarne Kvinge [MSFT] 2015-10-19 05:36:57 UTC
@Michael, do you know what we have to do for watchOS projects to be able to reference PCL projects? Or do you know who might know?
Comment 5 Mikayla Hutchinson [MSFT] 2015-10-27 18:34:26 UTC
@rolf you need SupportedFrameworks files, same as for iOS: https://github.com/mono/bockbuild/blob/master/packages/pcl-reference-assemblies.py#L46
Comment 6 Rolf Bjarne Kvinge [MSFT] 2015-11-03 09:43:21 UTC
@mhutch, thanks!

So from that link it's clear PCL support for WatchOS is already implemented, we just need to ship a new Mono version with this included (which will most likely be Mono 4.4).