-
Notifications
You must be signed in to change notification settings - Fork 525
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
References are broken (sometimes) in universal app class libraries (Windows 8.1 + Windows Phone 8.1) #281
Comments
yes the targetplatformversion was a guess by me and @agross what should we emit? Or should just get rid of the targetplatform? |
Okay, the TargetPlatformVersion is not the problem. Version 7.0 is right - which is strange because I'd expect it to be 4.6 because of the reference assembly path for the profile 32 is Anyway, the problem is the TargetFrameworkProfile. msbuild tells me it's "Profile32", not "win81+wpa81" for this project. So when I change this check, it works: |
please try 0.9.0-alpha002 |
do you know what |
That's profile 259. And yes, the new version fixes the problem in my specific case. But I see another, more general problem with PCLs: Paket checks for specific profiles, which is too restrictive. If I have a portable class library for win81 and wpa81, but the package only supports "net45+win8+wp8+wpa81", this is still fine. Because this package target supports a superset of what I need. I'm afraid the whole logic for PCLs needs to be way more complicated :( I guess we need a compatibility tree with all profiles which tells us which profile is ok to include from which other profile. Then, of course, the references have to be prioritized correctly. If the package directly supports my profile, it's better to take this build than another one which supports more targets. |
Maybe there's a simpler solution than the compatibility tree. We need to have a mapping between profile numbers and the supported platforms (I think you have that already). Then when a package has a build for net45-win8-wp8-wpa81 we can use it for every profile which targets a subset of these 4 platforms. So we construct all possible subsets, get the matching profile number and include that in the csproj file. |
hehe, perfect picture :) |
if you are interested and have the time I'd love to see 2-3 examples of your idea. Then I could write test cases and try to implement it. |
Sure. I'll get back to you later. I thought a lot about this since yesterday but I need to write it down and maybe implement something to see if it actually works. |
Please see the project "UniversalClassLibrary" in https://github.com/christianlang/PaketTestProjects.
The package "reactive-core" referenced indirectly (through "reactiveui") in paket.references doesn't show up correctly in the project references. The package "Splat" (also referenced indirectly through "reactiveui") does. Both are from the same author and have a quite similar list of target frameworks they support.
I think it might be because there's a check for $(TargetPlatformVersion) == '7.0'" in the csproj file and the class library has a newer value. For Splat paket generates an "Otherwise" case instead which probably is the reason why it works.
The text was updated successfully, but these errors were encountered: