-
Notifications
You must be signed in to change notification settings - Fork 1.9k
#3533 Bring back uap10.0/netstandard1.4 support #7079
Conversation
Can't we keep both? netstandard 1.0 and 2.0 ? using multi target ? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Build error
D:\a\1\s\Xamarin.Forms.Controls\Xamarin.Forms.Controls.csproj : error : C:\Program Files\dotnet\sdk\2.2.105\Sdks\Msbuild.Sdk.Extras\Sdk not found. Check that a recent enough .NET Core SDK is installed and/or increase the version specified in global.json.
D:\a\1\s\Xamarin.Forms.Controls\Xamarin.Forms.Controls.csproj : error MSB4236: The SDK 'Msbuild.Sdk.Extras/1.3.1' specified could not be found.)
Should we multi target the UWP platform as well to minimize breaking changes?
+1 For multi-targeting .NET Standard 2.0 is always better if possible. Citations from the .NET Standard documentation.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should keep both netstandard 1.0 and 2.0 ? using multi target since this will only build on windows we are fine I think.
<PackageReference Include="Xam.Plugin.DeviceInfo" Version="3.0.2" /> | ||
<PackageReference Include="Microsoft.NETCore.UniversalWindowsPlatform" Version="6.0.6" Condition="$(TargetFramework) == 'uap10.0.14393'" /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this reference necessary from the shared .NET library (Xamarin.Forms.Controls)?
The Build is failing: "Sdk not found". |
I have that issue with the azure pipeline if you use the VS2019 image. Since it's technically no longer supported, that SDK isn't available there. |
be42983
to
15c1fb9
Compare
|
daf82b4
to
8b42df8
Compare
A test is failing, but it is not related with the changes (it is from iOS, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, tested the packages and they worked fine on update and run the app.
Notice that it installed WindowsUI package
Not sure my comment in #2859 is placed right: Hi, I shoud be doing something wrong, but still no working... My steps (probably more than are needed and less than required): Updated to VS2019 (16.4.0) |
Honestly I am seeing this same error and I haven't figured out how to resolve it. I'm fairly positive there's some combination netstandard libraries, fallbacks, or nuget packages that have to be added but I haven't figured it out. I'm going to poke around (possibly log a bug) see if I can figure out how you're supposed to setup the NS 1.4 library so that it works with UWP What does (annoyingly) work is if you use a PCL library instead of a netstandard library |
@Borjamao another way you can get it to work is to use multitargeting. If you setup your netstandard library like this, UWP consumes the 14393 target and it runs without any issues <Project Sdk="Msbuild.Sdk.Extras/2.0.54">
<PropertyGroup>
<TargetFramework Condition=" '$(OS)' != 'Windows_NT' ">netstandard2.0</TargetFramework>
<TargetFrameworks Condition=" '$(OS)' == 'Windows_NT' ">netstandard2.0;uap10.0.14393</TargetFrameworks>
<TargetPlatformVersion Condition="$(TargetFramework) == 'uap10.0.14393'">10.0.16299.0</TargetPlatformVersion>
<ProduceReferenceAssembly>true</ProduceReferenceAssembly>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<DebugType>portable</DebugType>
<DebugSymbols>true</DebugSymbols>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Xamarin.Forms" Version="4.4.0.991220-pre3" />
</ItemGroup>
</Project> |
Thanks @PureWeen, i've been working on this since you wrote, sorry for the delay, i'm facing so many problems with this issue, It seems that the support 1.4 has been bringed back, but nobody propertly tested it, this is my oppinion, because nothing is working as supposed. It was supposed to work (i think) as my first comment, but it isn't:
I worked on your suggestion, installed so many SDKs to support this:
After a succesful buid in Debug i tested on dev computer. It worked... exciting! Time to deploy to device with windows 14393, getting an error: Error 0x80073CFD, wich i found that "is the result of trying to install an app that requires a more updated windows 10 build than what your machine has." So, the objective of beeing able to deploy UWP to devices with Windows 10 ioT Ent2016 LTSB is not reached... This devices are not able to update, so please, do not suggest it... :( |
I haven't tested on the IoT builds but I have tested on a build of 14393 and it works for me |
@PureWeen, that means the problem is me! XD Please, could you tell me wich strategy did you follow to get it working? (multi-target, netstandard1.4, ...). Also, is it a debug or is a appxbundle deploy? An upload of the proyect will be nice I'm trying to push my organization to use XF in some proyects, but working in this kind of tablets is a must have as they are wide used at industrial environments, your help is appreciated. Thanks in advance! |
Here you go @Borjamao When you open the SLN you'll see it has a NS project and a PCL project Right now only the NS project is added to the UWP project. I was just testing out both scenarios For deploying I was just using the remote debugger features of Visual Studio to deploy to the VM I have setup with the 14393 build of windows |
Thanks! I've been playing with your project and creating new projects... All seems to be ok using multitargeting (in debug mode, as release is also having problems, but is not because of this issue) Thanks for your help! |
Description of Change
Target netstandard 1.4 in order to support uap10.0.
Issues Resolved
fixes #3533
API Changes
None
Platforms Affected
Behavioral/Visual Changes
None
Before/After Screenshots
Not applicable
Testing Procedure
PR Checklist