v4.2.0-rc2 #35
Workflow file for this run
This file contains hidden or 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
# Copyright (c) 2025 Devexperts LLC. | ||
# SPDX-License-Identifier: MPL-2.0 | ||
name: release | ||
on: | ||
workflow_dispatch: | ||
inputs: | ||
publish: | ||
description: 'Publish The Release' | ||
default: true | ||
required: true | ||
type: boolean | ||
use_latest_tag: | ||
description: 'Try To Use The Latest Git Tag' | ||
default: false | ||
required: true | ||
type: boolean | ||
push: | ||
tags: | ||
- 'v*.*.*' | ||
jobs: | ||
get_version: | ||
name: Get Version | ||
runs-on: ubuntu-latest | ||
outputs: | ||
version: ${{ steps.set_version.outputs.version }} | ||
tag_name: ${{ steps.set_version.outputs.tag_name }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: 'true' | ||
fetch-tags: 'true' | ||
fetch-depth: '0' | ||
show-progress: 'true' | ||
- id: get_latest_tag | ||
run: | | ||
echo "tag=$(git describe --abbrev=0 --tags)" >> $GITHUB_OUTPUT | ||
- id: set_version | ||
run: | | ||
if [[ "${{ !inputs.use_latest_tag && startsWith(github.ref, 'refs/tags/') }}" == "true" ]] | ||
then | ||
echo "version=${{github.ref_name}}" >> $GITHUB_OUTPUT | ||
echo "tag_name=${{github.ref}}" >> $GITHUB_OUTPUT | ||
else | ||
echo "version=${{ steps.get_latest_tag.outputs.tag }}" >> $GITHUB_OUTPUT | ||
echo "tag_name=${{ format('refs/tags/{0}', steps.get_latest_tag.outputs.tag) }}" >> $GITHUB_OUTPUT | ||
fi | ||
build_package_and_upload: | ||
name: "${{ matrix.config.name }}-${{matrix.buildType}}: Build, Package & Upload" | ||
needs: [ get_version ] | ||
strategy: | ||
matrix: | ||
config: | ||
- name: win-vs2022 | ||
image: windows-latest | ||
os: windows | ||
cores: 4 | ||
cc: 'cl' | ||
cxx: 'cl' | ||
- name: macos-13-xcode-15 | ||
image: macos-13 | ||
os: macos | ||
cores: 4 | ||
xcode: '15.0' | ||
cc: 'clang' | ||
cxx: 'clang++' | ||
- name: ubuntu-24.04-gcc-14 | ||
image: ubuntu-24.04 | ||
os: linux | ||
cores: 4 | ||
cc: 'gcc-14' | ||
cxx: 'g++-14' | ||
- name: macos-14-xcode-15 | ||
image: macos-14 | ||
os: macos | ||
cores: 3 | ||
xcode: '15.0' | ||
cc: 'clang' | ||
cxx: 'clang++' | ||
buildType: [ Release, Debug, RelWithDebInfo ] | ||
runs-on: ${{ matrix.config.image }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
ref: ${{needs.get_version.outputs.tag_name}} | ||
- name: Select Xcode version | ||
if: ${{ contains(matrix.config.os, 'macos') }} | ||
run: sudo xcode-select -s '/Applications/Xcode_${{matrix.config.xcode}}.app/Contents/Developer' | ||
- name: Prepare build [Lib] | ||
run: | | ||
ls | ||
mkdir ${{github.workspace}}/build-${{matrix.buildType}} | ||
- name: Prepare build [Lib][Win with static with MT] | ||
if: ${{ contains(matrix.config.os, 'win') }} | ||
run: | | ||
ls | ||
mkdir ${{github.workspace}}/build-${{matrix.buildType}}-mt | ||
- name: Prepare build [Samples][Tools] | ||
if: ${{ !contains(matrix.buildType, 'Deb') }} | ||
run: | | ||
ls | ||
mkdir ${{github.workspace}}/build-Samples | ||
mkdir ${{github.workspace}}/build-Tools | ||
- name: Configure CMake [Lib] | ||
if: ${{ contains(matrix.config.os, 'win') }} | ||
run: > | ||
cmake -B ${{github.workspace}}/build-${{matrix.buildType}} | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DDXFCXX_VERSION="${{needs.get_version.outputs.version}}" | ||
-DDXFCXX_PACKAGE_SUFFIX="-${{matrix.buildType}}" | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_SAMPLES=OFF | ||
-DDXFCXX_BUILD_TOOLS=OFF | ||
-DDXFCXX_INSTALL_SAMPLES=OFF | ||
-DDXFCXX_INSTALL_TOOLS=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
- name: Configure CMake [Lib][Win with static with MT] | ||
if: ${{ contains(matrix.config.os, 'win') }} | ||
run: > | ||
cmake -B ${{github.workspace}}/build-${{matrix.buildType}}-mt | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DDXFCXX_VERSION="${{needs.get_version.outputs.version}}" | ||
-DDXFCXX_PACKAGE_SUFFIX="-${{matrix.buildType}}-static-mt" | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_SAMPLES=OFF | ||
-DDXFCXX_BUILD_TOOLS=OFF | ||
-DDXFCXX_INSTALL_SAMPLES=OFF | ||
-DDXFCXX_INSTALL_TOOLS=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
-DDXFCXX_LINK_STATIC_RUNTIME=ON | ||
- name: Configure CMake [Samples][Tools] | ||
if: ${{ contains(matrix.config.os, 'windows') && !contains(matrix.buildType, 'Deb') }} | ||
run: > | ||
cmake -B ${{github.workspace}}/build-Samples | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DDXFCXX_VERSION="${{needs.get_version.outputs.version}}" | ||
-DDXFCXX_PACKAGE_SUFFIX="-Samples" | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_TOOLS=OFF | ||
-DDXFCXX_INSTALL_LIB=OFF | ||
-DDXFCXX_INSTALL_TOOLS=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
cmake -B ${{github.workspace}}/build-Tools | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DDXFCXX_VERSION="${{needs.get_version.outputs.version}}" | ||
-DDXFCXX_PACKAGE_SUFFIX="-Tools" | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_SAMPLES=OFF | ||
-DDXFCXX_INSTALL_LIB=OFF | ||
-DDXFCXX_INSTALL_SAMPLES=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
- name: Configure CMake [Lib] | ||
if: ${{ contains(matrix.config.os, 'macos') }} | ||
run: > | ||
cmake -B ${{github.workspace}}/build-${{matrix.buildType}} | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DCMAKE_C_COMPILER=${{matrix.config.cc}} | ||
-DCMAKE_CXX_COMPILER=${{matrix.config.cxx}} | ||
-DDXFCXX_VERSION=${{needs.get_version.outputs.version}} | ||
-DDXFCXX_PACKAGE_SUFFIX=-${{matrix.buildType}} | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_SAMPLES=OFF | ||
-DDXFCXX_BUILD_TOOLS=OFF | ||
-DDXFCXX_INSTALL_SAMPLES=OFF | ||
-DDXFCXX_INSTALL_TOOLS=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
- name: Configure CMake [Samples][Tools] | ||
if: ${{ contains(matrix.config.os, 'macos') && !contains(matrix.buildType, 'Deb') }} | ||
run: > | ||
cmake -B ${{github.workspace}}/build-Samples | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DCMAKE_C_COMPILER=${{matrix.config.cc}} | ||
-DCMAKE_CXX_COMPILER=${{matrix.config.cxx}} | ||
-DDXFCXX_VERSION=${{needs.get_version.outputs.version}} | ||
-DDXFCXX_PACKAGE_SUFFIX=-Samples | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_TOOLS=OFF | ||
-DDXFCXX_INSTALL_LIB=OFF | ||
-DDXFCXX_INSTALL_TOOLS=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
cmake -B ${{github.workspace}}/build-Tools | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DCMAKE_C_COMPILER=${{matrix.config.cc}} | ||
-DCMAKE_CXX_COMPILER=${{matrix.config.cxx}} | ||
-DDXFCXX_VERSION=${{needs.get_version.outputs.version}} | ||
-DDXFCXX_PACKAGE_SUFFIX=-Tools | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_SAMPLES=OFF | ||
-DDXFCXX_INSTALL_LIB=OFF | ||
-DDXFCXX_INSTALL_SAMPLES=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
- name: Configure CMake [Lib] | ||
if: ${{ contains(matrix.config.os, 'linux') }} | ||
run: > | ||
cmake -B ${{github.workspace}}/build-${{matrix.buildType}} | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DCMAKE_C_COMPILER=${{matrix.config.cc}} | ||
-DCMAKE_CXX_COMPILER=${{matrix.config.cxx}} | ||
-DDXFCXX_VERSION=${{needs.get_version.outputs.version}} | ||
-DDXFCXX_PACKAGE_SUFFIX=-${{matrix.buildType}} | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_SAMPLES=OFF | ||
-DDXFCXX_BUILD_TOOLS=OFF | ||
-DDXFCXX_INSTALL_SAMPLES=OFF | ||
-DDXFCXX_INSTALL_TOOLS=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
- name: Configure CMake [Samples][Tools] | ||
if: ${{ contains(matrix.config.os, 'linux') && !contains(matrix.buildType, 'Deb') }} | ||
run: > | ||
cmake -B ${{github.workspace}}/build-Samples | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DCMAKE_C_COMPILER=${{matrix.config.cc}} | ||
-DCMAKE_CXX_COMPILER=${{matrix.config.cxx}} | ||
-DDXFCXX_VERSION=${{needs.get_version.outputs.version}} | ||
-DDXFCXX_PACKAGE_SUFFIX=-Samples | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_TOOLS=OFF | ||
-DDXFCXX_INSTALL_LIB=OFF | ||
-DDXFCXX_INSTALL_TOOLS=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
cmake -B ${{github.workspace}}/build-Tools | ||
-DCMAKE_BUILD_TYPE=${{matrix.buildType}} | ||
-DCMAKE_C_COMPILER=${{matrix.config.cc}} | ||
-DCMAKE_CXX_COMPILER=${{matrix.config.cxx}} | ||
-DDXFCXX_VERSION=${{needs.get_version.outputs.version}} | ||
-DDXFCXX_PACKAGE_SUFFIX=-Tools | ||
-DDXFCXX_BUILD_UNIT_TESTS=OFF | ||
-DDXFCXX_BUILD_SAMPLES=OFF | ||
-DDXFCXX_INSTALL_LIB=OFF | ||
-DDXFCXX_INSTALL_SAMPLES=OFF | ||
-DDXFCXX_BUILD_DOC=OFF | ||
-DDXFCXX_FEATURE_STACKTRACE=ON | ||
- name: Build [Lib] | ||
if: ${{ !contains(matrix.config.os, 'win') }} | ||
run: > | ||
cmake --build ${{github.workspace}}/build-${{matrix.buildType}} | ||
--config ${{matrix.buildType}} -j ${{matrix.config.cores}} | ||
- name: Build [Lib] | ||
if: ${{ contains(matrix.config.os, 'win') }} | ||
run: > | ||
cmake --build ${{github.workspace}}/build-${{matrix.buildType}} | ||
--config ${{matrix.buildType}} -j ${{matrix.config.cores}} | ||
-- | ||
/p:CL_MPCount=${{matrix.config.cores}} | ||
- name: Build [Lib][Win with static with MT] | ||
if: ${{ contains(matrix.config.os, 'win') }} | ||
run: > | ||
cmake --build ${{github.workspace}}/build-${{matrix.buildType}}-mt | ||
--config ${{matrix.buildType}} -j ${{matrix.config.cores}} | ||
-- | ||
/p:CL_MPCount=${{matrix.config.cores}} | ||
- name: Build [Samples][Tools] | ||
if: ${{ !contains(matrix.buildType, 'Deb') && !contains(matrix.config.os, 'win') }} | ||
run: | | ||
cmake --build ${{github.workspace}}/build-Samples --config ${{matrix.buildType}} -j ${{matrix.config.cores}} | ||
cmake --build ${{github.workspace}}/build-Tools --config ${{matrix.buildType}} -j ${{matrix.config.cores}} | ||
- name: Build [Samples][Tools] | ||
if: ${{ !contains(matrix.buildType, 'Deb') && contains(matrix.config.os, 'win') }} | ||
run: > | ||
cmake --build ${{github.workspace}}/build-Samples | ||
--config ${{matrix.buildType}} | ||
-j ${{matrix.config.cores}} | ||
-- | ||
/p:CL_MPCount=${{matrix.config.cores}} | ||
cmake --build ${{github.workspace}}/build-Tools | ||
--config ${{matrix.buildType}} | ||
-j ${{matrix.config.cores}} | ||
-- | ||
/p:CL_MPCount=${{matrix.config.cores}} | ||
- name: Pack [Lib] | ||
working-directory: "${{github.workspace}}/build-${{matrix.buildType}}" | ||
run: cpack -G ZIP -C ${{matrix.buildType}} --config ./dxFeedGraalCxxApiPackConfig.cmake | ||
- name: Pack [Lib][Win with static with MT] | ||
if: ${{ contains(matrix.config.os, 'win') }} | ||
working-directory: "${{github.workspace}}/build-${{matrix.buildType}}-mt" | ||
run: cpack -G ZIP -C ${{matrix.buildType}} --config ./dxFeedGraalCxxApiPackConfig.cmake | ||
- name: Pack [Samples] | ||
if: ${{ !contains(matrix.buildType, 'Deb') }} | ||
working-directory: ${{github.workspace}}/build-Samples | ||
run: cpack -G ZIP -C ${{matrix.buildType}} --config ./dxFeedGraalCxxApiPackConfig.cmake | ||
- name: Pack [Tools] | ||
if: ${{ !contains(matrix.buildType, 'Deb') }} | ||
working-directory: ${{github.workspace}}/build-Tools | ||
run: cpack -G ZIP -C ${{matrix.buildType}} --config ./dxFeedGraalCxxApiPackConfig.cmake | ||
- name: Upload [Lib] | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: artifacts-lib-${{matrix.config.name}}-${{matrix.buildType}} | ||
path: build-${{matrix.buildType}}/*.zip | ||
- name: Upload [Lib][Win with static with MT] | ||
if: ${{ contains(matrix.config.os, 'win') }} | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: artifacts-lib-${{matrix.config.name}}-${{matrix.buildType}}-mt | ||
path: build-${{matrix.buildType}}-mt/*.zip | ||
- name: Upload [Samples][Tools] | ||
if: ${{ !contains(matrix.buildType, 'Deb') }} | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: artifacts-samples-and-tools-${{matrix.config.name}}-${{matrix.buildType}} | ||
path: | | ||
build-Samples/*.zip | ||
build-Tools/*.zip | ||
build_docs_and_upload_and_deploy_gh_pages: | ||
name: "${{ matrix.config.name }}: Build Docs & Upload" | ||
needs: [ get_version ] | ||
strategy: | ||
matrix: | ||
config: | ||
- name: ubuntu-24.04 | ||
image: ubuntu-24.04 | ||
runs-on: ${{ matrix.config.image }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
ref: ${{needs.get_version.outputs.tag_name}} | ||
- uses: mattnotmitt/doxygen-action@v1.12.0 | ||
with: | ||
doxyfile-path: './docs/Doxyfile' | ||
working-directory: '${{github.workspace}}/docs' | ||
- name: Pack | ||
run: | | ||
zip -r dxFeedGraalCxxApi-${{needs.get_version.outputs.version}}.zip ${{github.workspace}}/docs/html | ||
- name: Upload Docs | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: artifacts-docs | ||
path: | | ||
${{github.workspace}}/*.zip | ||
- name: Upload docs as gh pages artifact | ||
id: deployment | ||
uses: actions/upload-pages-artifact@v3 | ||
with: | ||
path: ${{github.workspace}}/docs/html | ||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
Check failure on line 383 in .github/workflows/release.yml
|
||
uses: actions/deploy-pages@v4 | ||
build_full_src_bundle_and_upload: | ||
name: "${{ matrix.config.name }}: Build Full Source Bundle & Upload" | ||
needs: [ get_version ] | ||
strategy: | ||
matrix: | ||
config: | ||
- name: win-vs2022 | ||
image: windows-latest | ||
runs-on: ${{ matrix.config.image }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
ref: ${{needs.get_version.outputs.tag_name}} | ||
- uses: mattnotmitt/doxygen-action@v1.12.0 | ||
with: | ||
doxyfile-path: './docs/Doxyfile' | ||
working-directory: '${{github.workspace}}/docs' | ||
- name: Prepare build [Full Source Bundle] | ||
run: | | ||
ls | ||
mkdir ${{github.workspace}}/build-bundle | ||
- name: Build [Full Source Bundle] | ||
shell: pwsh | ||
run: | | ||
${{github.workspace}}/scripts/make-source-bundle.ps1 ${{needs.get_version.outputs.version}} | ||
- name: Upload [Full Source Bundle] | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: artifacts-full-source-bundle-${{matrix.config.name}} | ||
path: | | ||
build-bundle/*.zip | ||
publish_release: | ||
if: ${{ inputs.publish || contains(github.event_name, 'push')}} | ||
runs-on: ubuntu-latest | ||
name: Publish Release | ||
needs: [ get_version, build_package_and_upload, build_full_src_bundle_and_upload, build_docs_and_upload_and_deploy_gh_pages ] | ||
permissions: | ||
contents: write | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
path: artifacts | ||
pattern: artifacts-* | ||
merge-multiple: true | ||
- name: 'Echo download path' | ||
run: echo ${{steps.download.outputs.download-path}} | ||
- name: Display structure of downloaded files | ||
run: ls -R | ||
- uses: softprops/action-gh-release@4634c16e79c963813287e889244c50009e7f0981 | ||
with: | ||
files: | | ||
artifacts/*.zip | ||
artifacts/build-Samples/*.zip | ||
artifacts/build-Tools/*.zip | ||
artifacts/build-bundle/*.zip | ||
prerelease: > | ||
${{ contains(needs.get_version.outputs.version, 'alpha') | ||
|| contains(needs.get_version.outputs.version, 'beta') | ||
|| contains(needs.get_version.outputs.version, 'pre') | ||
|| contains(needs.get_version.outputs.version, 'rc') }} | ||
tag_name: ${{ needs.get_version.outputs.tag_name }} | ||
name: ${{ needs.get_version.outputs.version }} | ||
draft: ${{ contains(needs.get_version.outputs.version, 'draft') }} | ||