Skip to content
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

Add Alpine Native Libraries #1339

Merged
merged 7 commits into from
Jun 17, 2020
Merged

Add Alpine Native Libraries #1339

merged 7 commits into from
Jun 17, 2020

Conversation

mattleibow
Copy link
Contributor

@mattleibow mattleibow commented Jun 17, 2020

Description of Change

Adding a build for Alpine linux.

Builds on Alpine 3.9, tested all the way back to Alpine 3.7.

Bugs Fixed

API Changes

None.

Behavioral Changes

The *.NativeAssets.Linux NuGet packages will now have an Alpine linux binary.

PR Checklist

  • Has tests (if omitted, state reason in description)
  • Rebased on top of master at time of PR
  • Changes adhere to coding standard
  • Updated documentation

@mattleibow mattleibow merged commit c23eab0 into master Jun 17, 2020
@mattleibow mattleibow deleted the dev/alpine branch June 17, 2020 17:15
@mattleibow mattleibow mentioned this pull request Jun 17, 2020
5 tasks
@@ -61,7 +61,7 @@ void GnNinja(DirectoryPath outDir, string target, string skiaArgs)

// build native skia
RunProcess(NINJA_EXE, new ProcessSettings {
Arguments = $"{target} -C out/{outDir}",
Arguments = $"-C out/{outDir} {target}",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems some version of ninja don't like this order.

Copy link
Contributor Author

@mattleibow mattleibow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only a few places to add a new platform.

Comment on lines +1 to +8
FROM amd64/alpine:3.9

RUN apk add --no-cache bash curl ca-certificates python git build-base ninja fontconfig-dev
RUN apk add --no-cache samurai --repository http://dl-cdn.alpinelinux.org/alpine/edge/main
RUN apk add --no-cache mono clang gn --repository http://dl-cdn.alpinelinux.org/alpine/edge/testing
RUN cert-sync /etc/ssl/certs/ca-certificates.crt

WORKDIR /work
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the Docker file to run on.

Comment on lines +252 to +259
- template: azure-templates-bootstrapper.yml # Build Native Linux [Alpine] (Linux)
parameters:
name: native_linux_alpine_linux
displayName: Build Native Linux [Alpine] (Linux)
vmImage: $(VM_IMAGE_LINUX)
docker: scripts/Docker/alpine/amd64
target: externals-linux
additionalArgs: --buildarch=x64 --gn=gn --ninja=ninja --variant=alpine
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add an entry to the CI build

Comment on lines +335 to +336
- native_linux_alpinenodependencies_linux
- native_linux_alpine_linux
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Include it in the managed build/packaging.

@@ -45,6 +45,7 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release

<!-- libSkiaSharp.dll and other native files -->
<file platform="linux" src="runtimes/linux-x64/native/libSkiaSharp.so" />
<file platform="linux" src="runtimes/linux-musl-x64/native/libSkiaSharp.so" />
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add the asset to the NuGet package

Comment on lines +33 to +34
<None Include="..\..\output\native\alpine\x64\libSkiaSharp.so" Link="nuget\runtimes\linux-musl-x64\native\libSkiaSharp.so"
Condition=" Exists('..\..\output\native\alpine\x64\libSkiaSharp.so') or '$(IsLinux)' == 'true' " />
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add the asset to the project.

@mattleibow mattleibow added this to the v2.80.0 milestone Jul 9, 2020
ScrubN added a commit to ScrubN/TwitchDownloader that referenced this pull request Aug 30, 2023
According to mono/SkiaSharp#1339, the alpine binary should be included in the standard NativeAssets.Linux package.
Needs testing.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant