Skip to content

Add Nano Server to the list #1014

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

Closed
wants to merge 10 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions VERSIONS.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ HarfBuzzSharp file 2.6.1.0
SkiaSharp nuget 1.68.2
SkiaSharp.NativeAssets.Linux nuget 1.68.2
SkiaSharp.NativeAssets.Linux.NoDependencies nuget 1.68.2
SkiaSharp.NativeAssets.NanoServer nuget 1.68.2
SkiaSharp.Views nuget 1.68.2
SkiaSharp.Views.Desktop.Common nuget 1.68.2
SkiaSharp.Views.Gtk2 nuget 1.68.2
Expand Down
28 changes: 15 additions & 13 deletions build.cake
Original file line number Diff line number Diff line change
Expand Up @@ -74,19 +74,21 @@ var AZURE_BUILD_SUCCESS = "https://dev.azure.com/xamarin/6fd3d886-57a5-4e31-8db7
var AZURE_BUILD_URL = "https://dev.azure.com/xamarin/6fd3d886-57a5-4e31-8db7-52a1b47c07a8/_apis/build/builds/{0}/artifacts?artifactName={1}&%24format=zip&api-version=5.1";

var TRACKED_NUGETS = new Dictionary<string, Version> {
{ "SkiaSharp", new Version (1, 57, 0) },
{ "SkiaSharp.NativeAssets.Linux", new Version (1, 57, 0) },
{ "SkiaSharp.Views", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Desktop.Common", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Gtk2", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Gtk3", new Version (1, 57, 0) },
{ "SkiaSharp.Views.WindowsForms", new Version (1, 57, 0) },
{ "SkiaSharp.Views.WPF", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Forms", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Forms.WPF", new Version (1, 57, 0) },
{ "HarfBuzzSharp", new Version (1, 0, 0) },
{ "HarfBuzzSharp.NativeAssets.Linux", new Version (1, 0, 0) },
{ "SkiaSharp.HarfBuzz", new Version (1, 57, 0) },
{ "SkiaSharp", new Version (1, 57, 0) },
{ "SkiaSharp.NativeAssets.Linux", new Version (1, 57, 0) },
{ "SkiaSharp.NativeAssets.Linux.NoDependencies", new Version (1, 57, 0) },
{ "SkiaSharp.NativeAssets.NanoServer", new Version (1, 57, 0) },
{ "SkiaSharp.Views", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Desktop.Common", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Gtk2", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Gtk3", new Version (1, 57, 0) },
{ "SkiaSharp.Views.WindowsForms", new Version (1, 57, 0) },
{ "SkiaSharp.Views.WPF", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Forms", new Version (1, 57, 0) },
{ "SkiaSharp.Views.Forms.WPF", new Version (1, 57, 0) },
{ "HarfBuzzSharp", new Version (1, 0, 0) },
{ "HarfBuzzSharp.NativeAssets.Linux", new Version (1, 0, 0) },
{ "SkiaSharp.HarfBuzz", new Version (1, 57, 0) },
};

#load "cake/UtilsManaged.cake"
Expand Down
52 changes: 52 additions & 0 deletions nuget/SkiaSharp.NativeAssets.NanoServer.nuspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
<?xml version="1.0" encoding="utf-8"?>
<package>
<metadata>

<!-- package -->
<id>SkiaSharp.NativeAssets.NanoServer</id>
<title>SkiaSharp - Native Assets for Microsoft Nano Server</title>
<version>1.0.0</version>
<description>
SkiaSharp is a cross-platform 2D graphics API for .NET platforms based on Google's Skia Graphics Library.
It provides a comprehensive 2D API that can be used across mobile, server and desktop models to render images.
</description>
<summary>
SkiaSharp is a cross-platform 2D graphics API for .NET platforms that can be used across mobile, server and desktop models to render images.
</summary>
<releaseNotes>
Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release notes.
</releaseNotes>
<projectUrl>https://go.microsoft.com/fwlink/?linkid=868515</projectUrl>
<iconUrl>https://go.microsoft.com/fwlink/?linkid=868516</iconUrl>
<tags>xamarin graphics ios android linux windows uwp tvos watchos macos tizen cross-platform skiasharp</tags>

<!-- legal -->
<licenseUrl>https://go.microsoft.com/fwlink/?linkid=868514</licenseUrl>
<authors>Microsoft</authors>
<owners>Microsoft</owners>
<requireLicenseAcceptance>true</requireLicenseAcceptance>
<copyright>© Microsoft Corporation. All rights reserved.</copyright>

<dependencies>
<dependency id="SkiaSharp" version="1.0.0" />
</dependencies>

</metadata>
<files>

<!-- the build bits -->
<file src="build/net45/SkiaSharp.targets" target="build/net45/SkiaSharp.NativeAssets.NanoServer.targets" />

<!-- libSkiaSharp.dll and other native files -->
<file platform="windows" src="runtimes/win-x64/native/libSkiaSharp.dll" />

<!-- placeholders -->
<file src="_._" target="lib/net45/_._" />
<file src="_._" target="lib/netstandard/_._" />

<!-- legal -->
<file src="LICENSE.txt" />
<file src="THIRD-PARTY-NOTICES.txt" />

</files>
</package>
68 changes: 67 additions & 1 deletion scripts/azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,13 @@ stages:
vmImage: $(VM_IMAGE_WINDOWS)
target: externals-windows
additionalArgs: --buildarch=x64
- template: azure-templates-bootstrapper.yml # Build Native Win32|x64 [NanoServer] (Windows)
parameters:
name: native_win32_x64_nanoserver_windows
displayName: Build Native Win32|x64 [NanoServer] (Windows)
vmImage: $(VM_IMAGE_WINDOWS)
target: externals-windows
additionalArgs: --buildarch=x64 --additionalGnArgs="extra_cflags+=[''''-DSK_BUILD_FOR_NANOSERVER'''']"
# NATIVE JOBS - MAC
- template: azure-templates-bootstrapper.yml # Build Native Android|x86 (macOS)
parameters:
Expand Down Expand Up @@ -250,6 +257,25 @@ stages:
- native_uwp_arm64_windows
- native_win32_x86_windows
- native_win32_x64_windows
- template: azure-templates-bootstrapper.yml # Build Managed [NanoServer] (Windows)
parameters:
name: managed_nanoserver_windows
displayName: Build Managed [NanoServer] (Windows)
vmImage: $(VM_IMAGE_WINDOWS)
target: libs-only
requiredArtifacts:
- native_android_x86_windows
- native_android_x64_windows
- native_android_arm_windows
- native_android_arm64_windows
# - native_tizen_windows
- native_tizen_linux
- native_uwp_x86_windows
- native_uwp_x64_windows
- native_uwp_arm_windows
- native_uwp_arm64_windows
- native_win32_x86_windows
- native_win32_x64_nanoserver_windows
- template: azure-templates-bootstrapper.yml # Build Managed (macOS)
parameters:
name: managed_macos
Expand Down Expand Up @@ -292,6 +318,39 @@ stages:
displayName: Package NuGets
dependsOn: managed
jobs:
- template: azure-templates-bootstrapper.yml # Package NuGets [NanoServer]
parameters:
name: package_nanoserver_windows
displayName: Package NuGets [NanoServer]
vmImage: $(VM_IMAGE_WINDOWS)
target: nuget-only
additionalArgs: --packall=true
shouldPublish: false
requiredArtifacts:
- managed_linux
- managed_macos
- managed_nanoserver_windows
postBuildSteps:
- pwsh: |
$platforms = (Get-ChildItem -Path ./output/native/*) | Where-Object { $_.Name -NotMatch "windows" }
Write-Host "Removing the following platforms:"
$platforms | Foreach-Object { Write-Host $_.Name }
$platforms | ForEach-Object { Remove-Item -Path $_ -Recurse -Force }
$nupkgs = (Get-ChildItem -Path ./output/nugets/*) | Where-Object { $_.Name -NotMatch "NanoServer" }
Write-Host "Removing the following packages:"
$nupkgs | Foreach-Object { Write-Host $_.Name }
$nupkgs | ForEach-Object { Remove-Item -Path $_ -Recurse -Force }
displayName: Remove all unrelated files
- task: PublishBuildArtifacts@1
displayName: Publish the native-nanoserver artifacts
inputs:
artifactName: native-nanoserver
pathToPublish: 'output/native'
- task: PublishBuildArtifacts@1
displayName: Publish the nuget-nanoserver artifacts
inputs:
artifactName: nuget-nanoserver
pathToPublish: 'output/nugets'
- template: azure-templates-bootstrapper.yml # Package NuGets [No Dependencies]
parameters:
name: package_nodependencies_windows
Expand Down Expand Up @@ -339,7 +398,7 @@ stages:
- managed_windows
postBuildSteps:
- pwsh: |
$nupkgs = (Get-ChildItem -Path ./output/nugets/*) | Where-Object { $_.Name -Match "NoDependencies" }
$nupkgs = (Get-ChildItem -Path ./output/nugets/*) | Where-Object { ($_.Name -Match "NoDependencies") -or ($_.Name -Match "NanoServer") }
Write-Host "Removing the following packages:"
$nupkgs | Foreach-Object { Write-Host $_.Name }
$nupkgs | ForEach-Object { Remove-Item -Path $_ -Recurse -Force }
Expand All @@ -358,6 +417,7 @@ stages:
displayName: Combine Packaged NuGets
dependsOn:
- package_nodependencies_windows
- package_nanoserver_windows
- package_windows
pool:
name: $(VM_IMAGE_LINUX)
Expand All @@ -367,6 +427,11 @@ stages:
inputs:
artifactName: nuget-nodependencies
downloadPath: 'download-temp'
- task: DownloadBuildArtifacts@0
displayName: Download the nuget-nanoserver artifacts
inputs:
artifactName: nuget-nanoserver
downloadPath: 'download-temp'
- task: DownloadBuildArtifacts@0
displayName: Download the nuget-default artifacts
inputs:
Expand All @@ -375,6 +440,7 @@ stages:
- pwsh: |
New-Item '.\output\nugets' -Type Directory -Force | Out-Null
Get-ChildItem '.\download-temp\nuget-nodependencies\' | Copy-Item -Destination '.\output\nugets' -Recurse -Force
Get-ChildItem '.\download-temp\nuget-nanoserver\' | Copy-Item -Destination '.\output\nugets' -Recurse -Force
Get-ChildItem '.\download-temp\nuget-default\' | Copy-Item -Destination '.\output\nugets' -Recurse -Force
Remove-Item '.\download-temp\' -Recurse -Force
displayName: Move the nuget-* artifacts to the output directory
Expand Down