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

Feature/framework and nuget package stuff #42

Open
wants to merge 26 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
4652a29
Upgrading targeted frameworks, adjusting all consuming projects to us…
kenny-sellers Jan 24, 2022
c6c4405
Adding multi-targeted support for winforms application.
kenny-sellers Jan 24, 2022
8cef1c9
Adjusting build process to put native libraries into a runtime direct…
kenny-sellers Jan 25, 2022
21f1cb1
Benchmark changes to support multi-targetting and getting started on …
kenny-sellers Jan 25, 2022
9aff1e6
Adjusting build process to be one action for both PR and main builds.
kenny-sellers Jan 25, 2022
0eabedd
Update benchmark.yml
kenny-sellers Jan 25, 2022
a127aeb
Update benchmark.yml
kenny-sellers Jan 25, 2022
2bd0a55
Hopefully fixing builds.
kenny-sellers Jan 25, 2022
cc50608
Correcting with nugetpackage reference
kenny-sellers Jan 25, 2022
d89139e
Resolving issues with build and benchmark
kenny-sellers Jan 25, 2022
30f1d64
Resolving architecture issues
kenny-sellers Jan 25, 2022
c6b526a
Update ConsoleApp.csproj
kenny-sellers Jan 26, 2022
cbe1255
Update build.yml
kenny-sellers Jan 26, 2022
b6f005e
Fixing framework version for .net 5 and .net 6.
kenny-sellers Jan 26, 2022
75c40ec
Added Sample1.cr2 as the other image appears to be corrupt.
kenny-sellers Jan 26, 2022
b4987e6
Fixing the benchmark action logic
kenny-sellers Jan 26, 2022
8e93e10
Update benchmark.yml
kenny-sellers Jan 26, 2022
7c75f73
Fixing benchmark yml
kenny-sellers Jan 26, 2022
404e9cc
Update DcrawProcessGpu.cs
kenny-sellers Jan 27, 2022
b71f052
Update DcrawProcess.cs
kenny-sellers Jan 27, 2022
89b17eb
Update DcrawProcessWhiteBalance.cs
kenny-sellers Jan 27, 2022
d9d2cf7
Update DcrawProcessWhiteBalanceGpu.cs
kenny-sellers Jan 27, 2022
ba70f29
Update Thumbnail.cs
kenny-sellers Jan 27, 2022
13a580a
Merging main into feature branch to get benchmark results and the ben…
kenny-sellers Jan 27, 2022
14485f1
Upgrading nuget package reference
kenny-sellers Jan 27, 2022
31b72b4
Adding benchmarks
kenny-sellers Jan 27, 2022
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
283 changes: 229 additions & 54 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,55 +3,33 @@ name: FileOnQ.Imaging.Raw
on:
push:
branches: [ main ]
tags: [ 'v*', 'v*-preview-*']
pull_request:
branches: [ main ]

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: windows-2019
cuda: 'CUDA-11.4.0'
visual_studio: 'Visual Studio 16 2019'
architecture: 'AnyCPU'
library: 'library'
- os: windows-2019
cuda: 'CUDA-11.4.0'
visual_studio: 'Visual Studio 16 2019'
architecture: 'x64'
library: 'library'
- os: windows-2019
cuda: 'CUDA-11.4.0'
visual_studio: 'Visual Studio 16 2019'
architecture: 'x86'
library: 'library'
- os: windows-2019
cuda: 'CUDA-11.4.0'
visual_studio: 'Visual Studio 16 2019'
architecture: 'AnyCPU'
library: 'nuget'
- os: windows-2019
cuda: 'CUDA-11.4.0'
visual_studio: 'Visual Studio 16 2019'
architecture: 'x64'
library: 'nuget'
- os: windows-2019
cuda: 'CUDA-11.4.0'
visual_studio: 'Visual Studio 16 2019'
architecture: 'x86'
library: 'nuget'

runs-on: windows-2019
outputs:
package_version: ${{ env.PACKAGE_VERSION }}
steps:
- uses: actions/checkout@v2
with:
submodules: 'true'
- name: Ensure .NET 5 SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.302

- name: Ensure .NET 6 SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.101

- name: Install CUDA
env:
cuda: ${{ matrix.cuda }}
visual_studio: ${{ matrix.visual_studio }}
cuda: 'CUDA-11.4.0'
visual_studio: 'Visual Studio 16 2019'
shell: powershell
run: .\build\cuda.ps1

Expand All @@ -63,27 +41,224 @@ jobs:
ls $env:CUDA_PATH\bin
ls $env:CUDA_PATH\include

- name: Setup .NET SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.302
- name: Set Version from Tag
if: startsWith(github.ref, 'refs/tags/v') == true
run: |
$version = "${{ github.ref }}" -replace "refs/tags/v", ""
echo "PACKAGE_VERSION=$version" >> $env:GITHUB_ENV
echo "Version: $version"

- name: Setup NuGet.exe
uses: NuGet/[email protected]
with:
nuget-version: 5.x
- name: Set Version
if: startsWith(github.ref, 'refs/tags/v') == false && ${{ github.event_name != 'pull_request' }}
run: echo "PACKAGE_VERSION=1.0.0-dev.${{ GITHUB.RUN_NUMBER }}" >> $env:GITHUB_ENV

- name: Set Version for PR
if: ${{ github.event_name == 'pull_request' }}
run: echo "PACKAGE_VERSION=1.0.0-pr.${{ GITHUB.RUN_NUMBER }}" >> $env:GITHUB_ENV

- name: Build
run: dotnet build src/FileOnQ.Imaging.Raw/FileOnQ.Imaging.Raw.csproj
run: dotnet build -c Release
working-directory: ./src/FileOnQ.Imaging.Raw

- name: Pack NuGet
if: ${{ matrix.library == 'nuget' }}
run: dotnet pack src/FileOnQ.Imaging.Raw/FileOnQ.Imaging.Raw.csproj -c Release -o . /p:Version=0.0.0-local.1 /p:PackageVersion=0.0.0-local.1
run: dotnet pack -c Release -o ../../ /p:ContinuousIntegrationBuild=true /p:Version=${{ env.PACKAGE_VERSION }} /p:PackageVersion=${{ env.PACKAGE_VERSION }}
working-directory: ./src/FileOnQ.Imaging.Raw

- name: Upload NuGet Package
uses: actions/upload-artifact@v2
with:
name: Packages
path: |
*.nupkg
*.snupkg

test-integration:
needs: build
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: windows-2019
architecture: 'AnyCPU'
framework: 'net48'
- os: windows-2019
architecture: 'x86'
framework: 'net48'
- os: windows-2019
architecture: 'x64'
framework: 'net48'
- os: windows-2019
architecture: 'AnyCPU'
framework: 'net5'
- os: windows-2019
architecture: 'x86'
framework: 'net5'
- os: windows-2019
architecture: 'x64'
framework: 'net5'
- os: windows-2019
architecture: 'AnyCPU'
framework: 'net6'
- os: windows-2019
architecture: 'x86'
framework: 'net6'
- os: windows-2019
architecture: 'x64'
framework: 'net6'
steps:
- name: Checkout
uses: actions/checkout@v2
with:
submodules: 'true'

- name: Ensure .NET 5 SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.302

- name: Ensure .NET 6 SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.101

- name: Download Artifacts
uses: actions/download-artifact@v2

- name: Copy Nupkg
shell: powershell
run: Copy-Item Packages\* -Destination .

- name: Test NuGet
if: ${{ matrix.library == 'nuget' }}
run: dotnet test --logger:"console;verbosity=detailed" tests/FileOnQ.Imaging.Raw.Tests.NuGet.${{ matrix.architecture }}/FileOnQ.Imaging.Raw.Tests.NuGet.${{ matrix.architecture }}.csproj --filter TestCategory=Integration
- name: Update NuGet
run: dotnet add package FileOnQ.Imaging.Raw --version ${{ needs.build.outputs.package_version }}
working-directory: ./tests/FileOnQ.Imaging.Raw.Tests.${{ matrix.architecture }}

- name: Test Library
if: ${{ matrix.library == 'library' }}
run: dotnet test --logger:"console;verbosity=detailed" tests/FileOnQ.Imaging.Raw.Tests.${{ matrix.architecture }}/FileOnQ.Imaging.Raw.Tests.${{ matrix.architecture }}.csproj --filter TestCategory=Integration
- name: Test ${{ matrix.architecture }}
run: dotnet test -c Release --logger:"console;verbosity=detailed" --filter TestCategory=Integration
working-directory: ./tests/FileOnQ.Imaging.Raw.Tests.${{ matrix.architecture }}
test-console-app:
needs: build
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: windows-2019
architecture: 'AnyCPU'
framework: 'net48'
- os: windows-2019
architecture: 'x86'
framework: 'net48'
- os: windows-2019
architecture: 'x64'
framework: 'net48'
- os: windows-2019
architecture: 'AnyCPU'
framework: 'net5.0'
- os: windows-2019
architecture: 'x86'
framework: 'net5.0'
- os: windows-2019
architecture: 'x64'
framework: 'net5.0'
- os: windows-2019
architecture: 'AnyCPU'
framework: 'net6.0'
- os: windows-2019
architecture: 'x86'
framework: 'net6.0'
- os: windows-2019
architecture: 'x64'
framework: 'net6.0'
steps:
- name: Checkout
uses: actions/checkout@v2
with:
submodules: 'true'

- name: Ensure .NET 5 SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.302

- name: Ensure .NET 6 SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.101

- name: Download Artifacts
uses: actions/download-artifact@v2

- name: Copy Nupkg
shell: powershell
run: Copy-Item Packages\* -Destination .

- name: Update NuGet
run: dotnet add package FileOnQ.Imaging.Raw --version ${{ needs.build.outputs.package_version }}
working-directory: ./samples/ConsoleApp

- name: Run Console App
run: dotnet run -c Release -f ${{ matrix.framework }} /p:Platform=${{ matrix.architecture }}
working-directory: ./samples/ConsoleApp

build-win-forms-app:
needs: build
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: windows-2019
architecture: 'AnyCPU'
framework: 'net48'
- os: windows-2019
architecture: 'x86'
framework: 'net48'
- os: windows-2019
architecture: 'x64'
framework: 'net48'
- os: windows-2019
architecture: 'AnyCPU'
framework: 'net5.0-windows'
- os: windows-2019
architecture: 'x86'
framework: 'net5.0-windows'
- os: windows-2019
architecture: 'x64'
framework: 'net5.0-windows'
- os: windows-2019
architecture: 'AnyCPU'
framework: 'net6.0-windows'
- os: windows-2019
architecture: 'x86'
framework: 'net6.0-windows'
- os: windows-2019
architecture: 'x64'
framework: 'net6.0-windows'
steps:
- name: Checkout
uses: actions/checkout@v2
with:
submodules: 'true'

- name: Ensure .NET 5 SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.302

- name: Ensure .NET 6 SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.101

- name: Download Artifacts
uses: actions/download-artifact@v2

- name: Copy Nupkg
shell: powershell
run: Copy-Item Packages\* -Destination .

- name: Update NuGet
run: dotnet add package FileOnQ.Imaging.Raw --version ${{ needs.build.outputs.package_version }}
working-directory: ./samples/WinForms

- name: Build WinForms App
run: dotnet build -c Release -f ${{ matrix.framework }} /p:Platform=${{ matrix.architecture }}
working-directory: ./samples/WinForms
63 changes: 0 additions & 63 deletions .github/workflows/build_libraw.yml

This file was deleted.

Loading