mirror of https://github.com/OpenRCT2/OpenRCT2.git
Avoid signing when build has not changed
This commit is contained in:
parent
bd006de77b
commit
a3e4bd1af4
|
@ -148,6 +148,7 @@
|
|||
<CleanItems Include="$(ArtifactsDir)openrct2-symbols-$(Configuration)-$(Platform)*.zip" />
|
||||
</ItemGroup>
|
||||
<Delete Files="@(CleanItems)" />
|
||||
<Delete Files="%(SignItems.Identity).signed" />
|
||||
<RemoveDir Directories="$(TargetDir)data" />
|
||||
</Target>
|
||||
|
||||
|
@ -192,24 +193,27 @@
|
|||
|
||||
<!-- Target to sign OpenRCT2 (exe and dll)
|
||||
This requires the project parameter SIGN_PASSWORD to be set -->
|
||||
<Target Name="Sign" DependsOnTargets="Build" Inputs="@(SignItems)" Outputs="%(Identity).bogus">
|
||||
<Target Name="Sign" AfterTargets="Build" Inputs="@(SignItems)" Outputs="%(SignItems.Identity).signed">
|
||||
<Warning Condition="'$(SIGN_PASSWORD)'==''" Text="SIGN_PASSWORD was not set, skipping signing of %(SignItems.Filename)%(SignItems.Extension)." />
|
||||
<Message Condition="'$(SIGN_PASSWORD)'!=''" Text="Signing %(SignItems.Filename)%(SignItems.Extension)"
|
||||
Importance="high" />
|
||||
<Exec Condition="'$(SIGN_PASSWORD)'!=''"
|
||||
Command="signtool.exe sign /f $(SignCertificate) /p $(SIGN_PASSWORD) /t $(SignTimestampUrl) %(SignItems.Identity)"
|
||||
StandardOutputImportance="low" />
|
||||
|
||||
<!-- Create a dummy file so that msbuild can use it to determine if the binary is newer than the last sign time -->
|
||||
<Touch AlwaysCreate="true" Files="%(SignItems.Identity).signed" />
|
||||
</Target>
|
||||
|
||||
<!-- Target to publish OpenRCT2 as a portable zip -->
|
||||
<Target Name="PublishPortable" DependsOnTargets="Build;g2;Sign" Inputs="@(PublishItems)" Outputs="$(PublishZip)">
|
||||
<Target Name="PublishPortable" DependsOnTargets="Build;g2" Inputs="@(PublishItems)" Outputs="$(PublishZip)">
|
||||
<MakeDir Directories="$(ArtifactsDir)" />
|
||||
<Message Importance="high" Text="Creating $([System.IO.Path]::GetFileName($(PublishZip)))..." />
|
||||
<_7z Output="$(PublishZip)" Inputs="@(PublishItems)" />
|
||||
</Target>
|
||||
|
||||
<!-- Target to publish the OpenRCT2 debug symbols -->
|
||||
<Target Name="PublishSymbols" DependsOnTargets="Build;Sign" Inputs="@(SymbolItems)" Outputs="$(PublishSymbolsZip)">
|
||||
<Target Name="PublishSymbols" DependsOnTargets="Build" Inputs="@(SymbolItems)" Outputs="$(PublishSymbolsZip)">
|
||||
<MakeDir Directories="$(ArtifactsDir)" />
|
||||
<Message Importance="high" Text="Creating $([System.IO.Path]::GetFileName($(PublishSymbolsZip)))..." />
|
||||
<_7z Output="$(PublishSymbolsZip)" Inputs="@(SymbolItems)" />
|
||||
|
@ -217,7 +221,7 @@
|
|||
|
||||
<!-- Target to publish the OpenRCT2 as an NSIS installer -->
|
||||
<Target Name="PublishInstaller"
|
||||
DependsOnTargets="Build;Sign;g2"
|
||||
DependsOnTargets="Build;g2"
|
||||
Inputs="@(PublishItems);$(NsisScript)"
|
||||
Outputs="$(PublishInstallerExe)"
|
||||
Condition="'$(NO_NSIS)'!='true'">
|
||||
|
|
Loading…
Reference in New Issue