Refactor property names for computing .deb/.rpm file names and dependencies
This commit is contained in:
parent
a5981cb09f
commit
5f0b4e1322
|
|
@ -37,12 +37,8 @@
|
||||||
<!-- In an orchestrated build, this may be overriden to other Azure feeds. -->
|
<!-- In an orchestrated build, this may be overriden to other Azure feeds. -->
|
||||||
<DotNetAssetRootUrl Condition="'$(DotNetAssetRootUrl)'==''">$(PublicCoreFeedPrefix)</DotNetAssetRootUrl>
|
<DotNetAssetRootUrl Condition="'$(DotNetAssetRootUrl)'==''">$(PublicCoreFeedPrefix)</DotNetAssetRootUrl>
|
||||||
|
|
||||||
<DotnetRuntimePackageName>dotnet-runtime</DotnetRuntimePackageName>
|
<DotnetRuntimeFileNamePrefix>dotnet-runtime-$(MicrosoftNETCoreAppPackageVersion)</DotnetRuntimeFileNamePrefix>
|
||||||
<DotnetRuntimeInstallerPrefix>$(DotnetRuntimePackageName)-$(MicrosoftNETCoreApp21PackageVersion)</DotnetRuntimeInstallerPrefix>
|
<RuntimeArchiveLinkPrefix>$(DotNetAssetRootUrl)Runtime/$(MicrosoftNETCoreAppPackageVersion)/$(DotnetRuntimeFileNamePrefix)</RuntimeArchiveLinkPrefix>
|
||||||
<MicrosoftNETCoreApp21IdVersion>2.1</MicrosoftNETCoreApp21IdVersion>
|
|
||||||
<MicrosoftNETCoreApp21InstallerVersion>$(MicrosoftNETCoreApp21PackageVersion.Split('-')[0])</MicrosoftNETCoreApp21InstallerVersion>
|
|
||||||
<DotnetRuntimeInstallerPrefix>$(DotnetRuntimePackageName)-$(MicrosoftNETCoreApp21IdVersion)</DotnetRuntimeInstallerPrefix>
|
|
||||||
<RuntimeArchiveLinkPrefix>$(DotNetAssetRootUrl)Runtime/$(MicrosoftNETCoreApp21PackageVersion)/$(DotnetRuntimeInstallerPrefix)</RuntimeArchiveLinkPrefix>
|
|
||||||
|
|
||||||
<SharedFxIntermediateArchiveFilePrefix>$(_SharedFxSourceDir)$(SharedFxIntermediateArchiveBaseName)-$(PackageVersion)</SharedFxIntermediateArchiveFilePrefix>
|
<SharedFxIntermediateArchiveFilePrefix>$(_SharedFxSourceDir)$(SharedFxIntermediateArchiveBaseName)-$(PackageVersion)</SharedFxIntermediateArchiveFilePrefix>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -25,12 +25,12 @@
|
||||||
<MakeDir Directories="$(_InstallerSourceDir)" />
|
<MakeDir Directories="$(_InstallerSourceDir)" />
|
||||||
<KoreBuild.Tasks.DownloadFile
|
<KoreBuild.Tasks.DownloadFile
|
||||||
Uri="$(RuntimeArchiveLinkPrefix)-%(WindowsSharedFxRIDs.Identity).zip$(DotNetAssetRootAccessTokenSuffix)"
|
Uri="$(RuntimeArchiveLinkPrefix)-%(WindowsSharedFxRIDs.Identity).zip$(DotNetAssetRootAccessTokenSuffix)"
|
||||||
DestinationPath="$(_InstallerSourceDir)$(DotnetRuntimeInstallerPrefix)-%(WindowsSharedFxRIDs.Identity).zip"
|
DestinationPath="$(_InstallerSourceDir)$(DotnetRuntimeFileNamePrefix)-%(WindowsSharedFxRIDs.Identity).zip"
|
||||||
Condition="!Exists('$(_InstallerSourceDir)$(DotnetRuntimeInstallerPrefix)-%(WindowsSharedFxRIDs.Identity).zip')" />
|
Condition="!Exists('$(_InstallerSourceDir)$(DotnetRuntimeFileNamePrefix)-%(WindowsSharedFxRIDs.Identity).zip')" />
|
||||||
<KoreBuild.Tasks.DownloadFile
|
<KoreBuild.Tasks.DownloadFile
|
||||||
Uri="$(RuntimeArchiveLinkPrefix)-%(NonWindowsSharedFxRIDs.Identity).tar.gz$(DotNetAssetRootAccessTokenSuffix)"
|
Uri="$(RuntimeArchiveLinkPrefix)-%(NonWindowsSharedFxRIDs.Identity).tar.gz$(DotNetAssetRootAccessTokenSuffix)"
|
||||||
DestinationPath="$(_InstallerSourceDir)$(DotnetRuntimeInstallerPrefix)-%(NonWindowsSharedFxRIDs.Identity).tar.gz"
|
DestinationPath="$(_InstallerSourceDir)$(DotnetRuntimeFileNamePrefix)-%(NonWindowsSharedFxRIDs.Identity).tar.gz"
|
||||||
Condition="!Exists('$(_InstallerSourceDir)$(DotnetRuntimeInstallerPrefix)-%(NonWindowsSharedFxRIDs.Identity).tar.gz')" />
|
Condition="!Exists('$(_InstallerSourceDir)$(DotnetRuntimeFileNamePrefix)-%(NonWindowsSharedFxRIDs.Identity).tar.gz')" />
|
||||||
</Target>
|
</Target>
|
||||||
|
|
||||||
<Target Name="_GenerateCumulativeArchive">
|
<Target Name="_GenerateCumulativeArchive">
|
||||||
|
|
@ -48,14 +48,14 @@
|
||||||
Command="tar -xzf $(SharedFxIntermediateArchiveFilePrefix)-$(SharedFxPlatform)$(ArchiveExtension) -C $(_WorkRoot)"
|
Command="tar -xzf $(SharedFxIntermediateArchiveFilePrefix)-$(SharedFxPlatform)$(ArchiveExtension) -C $(_WorkRoot)"
|
||||||
Condition="'$(ArchiveExtension)' == '.tar.gz'"/>
|
Condition="'$(ArchiveExtension)' == '.tar.gz'"/>
|
||||||
<Exec
|
<Exec
|
||||||
Command="tar -xzf $(_InstallerSourceDir)$(DotnetRuntimeInstallerPrefix)-$(SharedFxPlatform)$(ArchiveExtension) -C $(_WorkRoot)"
|
Command="tar -xzf $(_InstallerSourceDir)$(DotnetRuntimeFileNamePrefix)-$(SharedFxPlatform)$(ArchiveExtension) -C $(_WorkRoot)"
|
||||||
Condition="'$(ArchiveExtension)' == '.tar.gz'"/>
|
Condition="'$(ArchiveExtension)' == '.tar.gz'"/>
|
||||||
<UnzipArchive
|
<UnzipArchive
|
||||||
File="$(SharedFxIntermediateArchiveFilePrefix)-$(SharedFxPlatform)$(ArchiveExtension)"
|
File="$(SharedFxIntermediateArchiveFilePrefix)-$(SharedFxPlatform)$(ArchiveExtension)"
|
||||||
Destination="$(_WorkRoot)"
|
Destination="$(_WorkRoot)"
|
||||||
Condition="'$(ArchiveExtension)' == '.zip'" />
|
Condition="'$(ArchiveExtension)' == '.zip'" />
|
||||||
<UnzipArchive
|
<UnzipArchive
|
||||||
File="$(_InstallerSourceDir)$(DotnetRuntimeInstallerPrefix)-$(SharedFxPlatform)$(ArchiveExtension)"
|
File="$(_InstallerSourceDir)$(DotnetRuntimeFileNamePrefix)-$(SharedFxPlatform)$(ArchiveExtension)"
|
||||||
Destination="$(_WorkRoot)"
|
Destination="$(_WorkRoot)"
|
||||||
Condition="'$(ArchiveExtension)' == '.zip'" />
|
Condition="'$(ArchiveExtension)' == '.zip'" />
|
||||||
|
|
||||||
|
|
@ -142,13 +142,15 @@
|
||||||
<Image>rhel.7</Image>
|
<Image>rhel.7</Image>
|
||||||
<RpmVendor>.NET Foundation</RpmVendor>
|
<RpmVendor>.NET Foundation</RpmVendor>
|
||||||
<RHInstallRoot>/opt/rh/rh-dotnet20/root/usr/lib64/dotnet</RHInstallRoot>
|
<RHInstallRoot>/opt/rh/rh-dotnet20/root/usr/lib64/dotnet</RHInstallRoot>
|
||||||
|
<Rpm_DotnetRuntimeDependencyId>dotnet-runtime-$(AspNetCoreMajorVersion).$(AspNetCoreMinorVersion)</Rpm_DotnetRuntimeDependencyId>
|
||||||
|
<Rpm_DotnetRuntimeDependencyVersion>$(MicrosoftNETCoreAppPackageVersion.Split('-')[0])</Rpm_DotnetRuntimeDependencyVersion>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<!-- Build Docker Image -->
|
<!-- Build Docker Image -->
|
||||||
<MSBuild Projects="$(MSBuildProjectFullPath)" Targets="_BuildDockerImage" Properties="Image=$(Image)" />
|
<MSBuild Projects="$(MSBuildProjectFullPath)" Targets="_BuildDockerImage" Properties="Image=$(Image)" />
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<RpmSharedFxDependencies Include="$(DotnetRuntimeInstallerPrefix)" Version="$(MicrosoftNETCoreApp21InstallerVersion)" />
|
<RpmSharedFxDependencies Include="$(Rpm_DotnetRuntimeDependencyId)" Version="$(Rpm_DotnetRuntimeDependencyVersion)" />
|
||||||
<RpmRHSharedFxDirectories Include="$(RHInstallRoot)/shared" />
|
<RpmRHSharedFxDirectories Include="$(RHInstallRoot)/shared" />
|
||||||
<RpmGenericSharedFxDirectories Include="$(InstallRoot)/shared" />
|
<RpmGenericSharedFxDirectories Include="$(InstallRoot)/shared" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
@ -245,14 +247,15 @@
|
||||||
</Target>
|
</Target>
|
||||||
|
|
||||||
<Target Name="GenerateDebs" DependsOnTargets="_EnsureInstallerPrerequisites">
|
<Target Name="GenerateDebs" DependsOnTargets="_EnsureInstallerPrerequisites">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<NETCoreApp21DebVersion>$(MicrosoftNETCoreApp21PackageVersion)</NETCoreApp21DebVersion>
|
<Deb_DotnetRuntimeDependencyId>dotnet-runtime-$(AspNetCoreMajorVersion).$(AspNetCoreMinorVersion)</Deb_DotnetRuntimeDependencyId>
|
||||||
|
<Deb_DotnetRuntimeDependencyVersion>$(MicrosoftNETCoreAppPackageVersion)</Deb_DotnetRuntimeDependencyVersion>
|
||||||
<!-- Needed some creativity to convert the PackageVersion M.N.P-Build to the installer version M.N.P~Build, The conditional handles stabilized builds -->
|
<!-- Needed some creativity to convert the PackageVersion M.N.P-Build to the installer version M.N.P~Build, The conditional handles stabilized builds -->
|
||||||
<NETCoreApp21DebVersion Condition="$(NETCoreApp21DebVersion.Contains('-'))">$(NETCoreApp21DebVersion.Substring(0, $(NETCoreApp21DebVersion.IndexOf('-'))))~$(NETCoreApp21DebVersion.Substring($([MSBuild]::Add($(NETCoreApp21DebVersion.IndexOf('-')), 1))))</NETCoreApp21DebVersion>
|
<Deb_DotnetRuntimeDependencyVersion Condition="$(Deb_DotnetRuntimeDependencyVersion.Contains('-'))">$(Deb_DotnetRuntimeDependencyVersion.Substring(0, $(Deb_DotnetRuntimeDependencyVersion.IndexOf('-'))))~$(Deb_DotnetRuntimeDependencyVersion.Substring($([MSBuild]::Add($(Deb_DotnetRuntimeDependencyVersion.IndexOf('-')), 1))))</Deb_DotnetRuntimeDependencyVersion>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<_DebSharedFxDependencies Include="$(DotnetRuntimeInstallerPrefix)" Version="$(NETCoreApp21DebVersion)"/>
|
<_DebSharedFxDependencies Include="$(Deb_DotnetRuntimeDependencyId)" Version="$(Deb_DotnetRuntimeDependencyVersion)"/>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue