-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
872d1cc
commit a58e056
Showing
3 changed files
with
175 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
name: (sil-kil ci) configure build | ||
|
||
inputs: | ||
preset-name: | ||
description: "The preset name from CMakePresets.json." | ||
required: true | ||
upload-testlog: | ||
description: "Upload gtest log with same name as preset-name" | ||
required: false | ||
default: true | ||
type: boolean | ||
cmake-args: | ||
description: "Additional CMake arguments" | ||
required: false | ||
do-package-symbols: | ||
description: "In Debug builds, split symbols and provide a zip package" | ||
required: false | ||
type: boolean | ||
do-package: | ||
description: "Run `cmake --target package` and upload artifact" | ||
required: false | ||
type: boolean | ||
retention-days: | ||
description: "How long we keep the artifacts" | ||
required: false | ||
type: number | ||
default: 14 | ||
run-tests: | ||
description: "Run tests" | ||
required: false | ||
default: true | ||
type: boolean | ||
toolset: | ||
type: string | ||
default: '14.1' | ||
description: "MSVC tool set to use" | ||
required: false | ||
build-arch: | ||
type: string | ||
default: "x64" | ||
description: "MSVC build architecture to use" | ||
required: false | ||
linux-docker-image: | ||
type: string | ||
default: ghcr.io/mariusbgm/sil-kit-ci-ubuntu-22.04:main | ||
description: "Docker image used under Linux" | ||
required: false | ||
|
||
outputs: | ||
package-name: | ||
description: artifact name of the distribution zip | ||
value: "${{ steps.cmake-package.outputs.package-name }}" | ||
package-path: | ||
description: file path of the distribution zip | ||
value: "${{ steps.cmake-package.outputs.package-path }}" | ||
symbols-package-path: | ||
description: file path of the symbols zip | ||
value: "${{ steps.cmake-package.outputs.symbols-package-path }}" | ||
symbols-package-name: | ||
description: artifact name of the symbols zip | ||
value: "${{ steps.cmake-package.outputs.symbols-package-name }}" | ||
|
||
runs: | ||
using: composite | ||
steps: | ||
|
||
- name: (linux) configure cmake preset | ||
run: | | ||
docker run \ | ||
-v "${{ github.workspace }}/s/sil-kit:/s" \ | ||
-v "${{ github.workspace }}/b/linux:/b" \ | ||
"${{ inputs.linux-docker-image }}" \ | ||
gcc --version | ||
if: runner.os == 'Linux' | ||
shell: bash |
82 changes: 82 additions & 0 deletions
82
.github/actions/sil-kit-ci/setup-build-environment/action.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
name: (sil-kit ci) setup build environment | ||
|
||
inputs: | ||
preset-name: | ||
description: "The preset name from CMakePresets.json." | ||
required: true | ||
upload-testlog: | ||
description: "Upload gtest log with same name as preset-name" | ||
required: false | ||
default: true | ||
type: boolean | ||
cmake-args: | ||
description: "Additional CMake arguments" | ||
required: false | ||
do-package-symbols: | ||
description: "In Debug builds, split symbols and provide a zip package" | ||
required: false | ||
type: boolean | ||
do-package: | ||
description: "Run `cmake --target package` and upload artifact" | ||
required: false | ||
type: boolean | ||
retention-days: | ||
description: "How long we keep the artifacts" | ||
required: false | ||
type: number | ||
default: 14 | ||
run-tests: | ||
description: "Run tests" | ||
required: false | ||
default: true | ||
type: boolean | ||
toolset: | ||
type: string | ||
default: '14.1' | ||
description: "MSVC tool set to use" | ||
required: false | ||
build-arch: | ||
type: string | ||
default: "x64" | ||
description: "MSVC build architecture to use" | ||
required: false | ||
linux-docker-image: | ||
type: string | ||
default: ghcr.io/mariusbgm/sil-kit-ci-ubuntu-22.04:main | ||
description: "Docker image used under Linux" | ||
required: false | ||
|
||
outputs: | ||
package-name: | ||
description: artifact name of the distribution zip | ||
value: "${{ steps.cmake-package.outputs.package-name }}" | ||
package-path: | ||
description: file path of the distribution zip | ||
value: "${{ steps.cmake-package.outputs.package-path }}" | ||
symbols-package-path: | ||
description: file path of the symbols zip | ||
value: "${{ steps.cmake-package.outputs.symbols-package-path }}" | ||
symbols-package-name: | ||
description: artifact name of the symbols zip | ||
value: "${{ steps.cmake-package.outputs.symbols-package-name }}" | ||
|
||
runs: | ||
using: composite | ||
steps: | ||
|
||
- name: (all) checkout sil-kit sources | ||
uses: actions/checkout@v4 | ||
with: | ||
path: s/sil-kit | ||
submodules: true | ||
|
||
- name: (linux) create build directory | ||
run: mkdir -p b/linux | ||
if: runner.os == 'Linux' | ||
shell: bash | ||
|
||
- name: (linux) pull docker image for building via cmake | ||
run: docker pull "${{ inputs.linux-docker-image }}" | ||
if: runner.os == 'Linux' | ||
shell: bash | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters