strong signing build tools binaries#5071
strong signing build tools binaries#5071shahabhijeet wants to merge 2 commits intoAzure:LTSBuildToolsfrom
Conversation
| @@ -0,0 +1,11 @@ | |||
| <Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | |||
| <PropertyGroup> | |||
There was a problem hiding this comment.
nit: Most msbuild xml files use 2 space indention without tabs.
There was a problem hiding this comment.
@weshaggard I need to fix my indentation just for xml files in all the various editors I use. I have not been able to get set those defaults just for xml across VS, VSCode and notepad++
I will fix this very soon.
| <PropertyGroup> | ||
| <TargetFramework>net46</TargetFramework> | ||
| <OutputPath>$(TaskBinaryOutput)</OutputPath> | ||
| <DelaySign>false</DelaySign> |
There was a problem hiding this comment.
You shouldn't need this because you set it in buildtools.props
| <IsBuildToolsProject>true</IsBuildToolsProject> | ||
| </PropertyGroup> | ||
|
|
||
| <PropertyGroup Condition=" '$(IsBuildToolsProject)' == 'true' "> |
There was a problem hiding this comment.
Why condition this here? I don't see any way that IsBuildToolsProject isn't true from this spot.
There was a problem hiding this comment.
@weshaggard there are often times when the build scripts evolve and properties get rearranged.
This is just to keep clear that this property group is applicable only under the certain condition.
So in case ever the property group above (line 3) ever get's into any other file, having the condition check right now will save me lot of headache, if I ever forget to add that condition back in.
There was a problem hiding this comment.
OK that seems a little overkill to me but I don't have an issue with it. I would have just put both of them in the same property group to indicate that they are connected.
| There are certain projects that needs internals visible for test purpose | ||
| <!-- AND ('$(CodeSign)' == 'true') | ||
| <PropertyGroup Condition=" ('$(IsBuildToolsProject)' == 'false' OR '$(IsBuildToolsProject)' == '') "> |
There was a problem hiding this comment.
If you only ever set IsBuildToolsProject to true I would change this condition to '$(IsBuildToolsProject)' != 'true'
There was a problem hiding this comment.
Sorry I did not realized in the PR that the code was comment out.
There is no condition for IsBuildToolsProject == false anymore. The code that you see is commented out, so we are good.
| </PropertyGroup> | ||
| --> | ||
| <PropertyGroup> | ||
| <GenerateAssemblyInfo>false</GenerateAssemblyInfo> |
There was a problem hiding this comment.
Do you still need to set GenerateAssemblyInfo = false?
| @@ -18,38 +18,29 @@ | |||
| <BuildWideDebugTrace Condition=" '$(DebugTrace)' == '' ">false</BuildWideDebugTrace> | |||
There was a problem hiding this comment.
You probably need to condition DelaySign property above to make sure it doesn't override something setting it before like the buildtools.props.
There was a problem hiding this comment.
@weshaggard you mean, check for if it's set to false and if yes, set it to true? Is that what you mean by conditioning the setter for the DelaySign?
Also buildtools.props is not included in any build workflow, unless you are building the buildtools projects. Do you still anticipate buildtools.prop overriding any defaults for normal workflow?
Also buildtools.props will never be merged to the master repo.
There was a problem hiding this comment.
I was meaning something like <DelaySign Condition="'$(DelaySign)' == ''>true</DelaySign> . Just default it to true if it isn't already set to something else.
There was a problem hiding this comment.
@weshaggard but dont' we want to just set it to true by default regardless of what the existing value is?
And it will get overridden while building build tools project to false.
Maybe I am missing to understand why it has to be conditioned in the global scope?
There was a problem hiding this comment.
Assuming nothing imported before this is expected to set DelaySign then it is fine to always set it explicitly.
|
@weshaggard I will merge #5071 once all your PRs are merged. Please let me know if there is anything that I have not addressed to your feedback. |
| <PropertyGroup> | ||
| <TargetFramework>net46</TargetFramework> | ||
| <OutputPath>$(TaskBinaryOutput)</OutputPath> | ||
| <AssemblyOriginatorKeyFile>D:\myFork\LTSBuild\tools\BuildTools.snk</AssemblyOriginatorKeyFile> |
There was a problem hiding this comment.
Isn't this redundant with what is is in buildtools.props?
|
Closing this PR in lieu of #5076 |
Strong signing build tools binaries