-
Notifications
You must be signed in to change notification settings - Fork 331
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
Port GenFacades, Microsft.Cci.Extensions to Arcade #477
Conversation
The most interesting files are the .csproj/.targets files, and maybe GenFacadesTask.cs, as well as the general layout/naming scheme I've chosen (which is all described in the PR description) |
@jcagme do you know what list I need to edit here? |
eng/SignToolData.json |
Is the plan for this to end up in myget? If yes then go ahead and add it to eng/SignToolData.json if not we should have a conversation |
Yes, the plan is for it to wind up in myget. |
@@ -0,0 +1,16 @@ | |||
<Project Sdk="Microsoft.NET.Sdk"> |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
<PackageReference Include="Microsoft.Composition" Version="1.0.30" /> | ||
<PackageReference Include="System.Diagnostics.Contracts" Version="4.0.0" /> | ||
<PackageReference Include="System.Diagnostics.TraceSource" Version="4.0.0" /> | ||
<PackageReference Include="NETStandard.Library" Version="1.6.0" /> |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
@@ -0,0 +1,16 @@ | |||
<Project Sdk="Microsoft.NET.Sdk"> | |||
<PropertyGroup> | |||
<TargetFrameworks>net461</TargetFrameworks> |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
You likely need to hack the targets locally to reference your targets instead of the ones in Buildtools. |
</PropertyGroup> | ||
|
||
<PropertyGroup> | ||
<NoWarn>NU1701</NoWarn> |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
eng/SignToolData.json
Outdated
@@ -4,12 +4,15 @@ | |||
"certificate": "MicrosoftSHA2", | |||
"strongName": "MsSharedLib72", | |||
"values": [ | |||
"bin/Microsoft.Cci.Extensions/net461/Microsoft.Cci.Extensions.dll", |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
Updated to address feedback. Working on local CoreFx testing now. |
I think it was monday. Take a look at PR #410
…On Thu, Aug 23, 2018, 13:24 William Godbe, ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In eng/SignToolData.json
<#477 (comment)>:
> @@ -4,12 +4,15 @@
"certificate": "MicrosoftSHA2",
"strongName": "MsSharedLib72",
"values": [
+ "bin/Microsoft.Cci.Extensions/net461/Microsoft.Cci.Extensions.dll",
Oh, awesome! How recent is that change? I was getting errors last week
from not having .dll's in this file
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#477 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ACJTsG3eS_lQ6O4tbplKlrXmVo_GsRMWks5uTw-PgaJpZM4WAtFE>
.
|
@@ -1,16 +1,20 @@ | |||
<Project Sdk="Microsoft.NET.Sdk"> | |||
<PropertyGroup> | |||
<TargetFrameworks>net461</TargetFrameworks> | |||
<TargetFrameworks>net461;netstandard2.0</TargetFrameworks> |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
Why did you remove the exe support? I'm unsure if there are any existing cases for the exe but it does provide some level of flexibility. |
@weshaggard I didn't believe there were any remaining uses of it. I'm not opposed to adding it back if we want to keep the functionality just in case. |
Currently getting the following when building with this in CoreFx, I'm investigating:
|
I'm ok excluding the exe version for now to make things easier, if we find we need it we can add it. |
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
|
||
<PropertyGroup Condition="'$(GeneratePlatformNotSupportedAssembly)' == 'true' OR '$(GeneratePlatformNotSupportedAssemblyMessage)' != ''"> |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
The error is happening here:
|
|
This happens on
We then go into https://github.com/dotnet/corefx/blob/master/src/Common/src/CoreLib/System/Version.cs#L322-L391. We then find the indices of the three periods within the version string, but then we hit https://github.com/dotnet/corefx/blob/master/src/Common/src/CoreLib/System/Version.cs#L343. Since the
Build and Revision are initialized to -1 unless otherwise set: https://github.com/dotnet/corefx/blob/master/src/Common/src/CoreLib/System/Version.cs#L23-L24. Which causes our exception when we try to left-shift productVersion.Build by 16 at
|
In the current state, shims.proj fails when calling GenFacades.exe. Debugging. |
Looks like I'm missing
There is no Some earlier (unrelated) command during If I place the contents of that folder into
|
hostpolicy isn't supposed to come with the exe. This is just an indication that you are missing the runtime you are trying to run on. What is your runtimeconfig file say is the runtime you are trying to run on? As any asside we currently override the runtimeconfig file as part of init-tools.sh (https://github.com/dotnet/buildtools/blob/master/src/Microsoft.DotNet.Build.Tasks/PackageFiles/init-tools.ps1#L11) so we might need to figure out another solution. Perhaps a roll-forward policy. |
I don't see a runtimeconfig for GenFacades in |
There is definitely a GenFacades.runtimeconfig.json file in Tools directory today. It gets generated as part of the build if there isn't one present. We may need to play with it a little to see what our best option is. |
Working on converting the call to the .exe in |
I was able to get this working with CoreFx with a few minor tweaks. For one, shims.proj now looks like this: https://github.com/wtgodbe/corefx/blob/Shims/src/shims/shims.proj We will probably also need a change to https://github.com/dotnet/buildtools/blob/master/src/Microsoft.DotNet.Build.Tasks/PackageFiles/Build.Common.targets#L220, perhaps adding a property called Also, we'll probably want to wait until we port GenApi/ApiCompat (which I'm going to do next) before consuming this in CoreFx, since otherwise the version of @weshaggard is there anything else I need to address here? |
if (!Version.TryParse(_fileVersionContents, out fileVersion)) | ||
// For the File & Product Version, we take the first portion of the string before any whitespace, | ||
// in case there is extraneous information (e.g. '@BuiltBy') after the version number. | ||
if (!Version.TryParse(_fileVersionContents.Split(null)[0], out fileVersion)) |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFrameworks>netstandard2.0</TargetFrameworks> |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
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.
Other then the last couple comments the change looks good overall. I'm fine with you getting this in and then making any necessary changes to start consuming it in corefx as a follow-up.
This ports GenFacades & Microsft.Cci.Extensions to Arcade. It does the following things:
partialfacades.task.targets
intopartialfacades.targets
GenFacades.Core
GenFacades.Core
toMicrosoft.DotNet.GenFacades
Microsoft.DotNet.GenFacades
which contains Microsoft.Cci.ExtensionsFor #185.
@joperezr @jcagme @chcosta @tmat @weshaggard PTAL
I'd also love ideas on the best way to test this package out in CoreFx.