diff --git a/.github/workflows/check_pre-merge_develop.yml b/.github/workflows/check_pre-merge_develop.yml index b4355b17..ae731e30 100644 --- a/.github/workflows/check_pre-merge_develop.yml +++ b/.github/workflows/check_pre-merge_develop.yml @@ -8,23 +8,28 @@ on: branches: - develop +# Limit concurrency to prevent job cancellations +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + env: - CMAKE_VERSION: 3.17.2 + CMAKE_VERSION: 3.25.0 jobs: cmake-win-test: name: cmake build-win - runs-on: windows-2019 + runs-on: windows-2022 strategy: matrix: - generator: ['Visual Studio 16 2019', 'MSYS Makefiles'] + generator: ['Visual Studio 17 2022', 'MSYS Makefiles'] shared: [on, off] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage + - name: cmake_generate run: cmake -S . -B build -G "${{ matrix.generator }}" -DENABLE_SHARED=${{ matrix.shared }} - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -35,17 +40,16 @@ jobs: cmake-mac-test: name: cmake build-mac - runs-on: ${{ matrix.os }} + runs-on: self-hosted strategy: matrix: - os: [macos-10.15] -# os: [macos-10.15, macos-11.0] + runner: [macos] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage-macos + - name: cmake_generate-macos run: cmake -S . -B build -G "Unix Makefiles" -DENABLE_SHARED=on -DENABLE_ELEMENTS=on - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -59,17 +63,17 @@ jobs: cmake-ubuntu-test: name: cmake build runs-on: ${{ matrix.os }} + timeout-minutes: 30 strategy: + # Reduce concurrent jobs to prevent cancellations + max-parallel: 3 matrix: - os: [ubuntu-20.04, ubuntu-18.04] + os: [ubuntu-22.04] shared: [on, off] elements: [on, off] - exclude: - - os: ubuntu-18.04 - elements: off steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -88,12 +92,12 @@ jobs: doxygen-ubuntu: name: doxygen-check - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: install_doxygen - run: sudo apt install doxygen graphviz + run: sudo apt-get update && sudo apt-get install -y doxygen graphviz - name: doxygen_check run: | cd doc diff --git a/.github/workflows/check_pre-merge_master.yml b/.github/workflows/check_pre-merge_master.yml index 53fb3588..40c247d6 100644 --- a/.github/workflows/check_pre-merge_master.yml +++ b/.github/workflows/check_pre-merge_master.yml @@ -10,23 +10,28 @@ on: - master - stable_v* +# Limit concurrency to prevent job cancellations +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + env: - CMAKE_VERSION: 3.17.2 + CMAKE_VERSION: 3.25.0 jobs: cmake-win-test: name: cmake build-win - runs-on: windows-2019 + runs-on: windows-2022 strategy: matrix: - generator: ['Visual Studio 16 2019', 'MSYS Makefiles'] + generator: ['Visual Studio 17 2022', 'MSYS Makefiles'] shared: [on, off] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage + - name: cmake_generate run: cmake -S . -B build -G "${{ matrix.generator }}" -DENABLE_SHARED=${{ matrix.shared }} - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -37,17 +42,16 @@ jobs: cmake-mac-test: name: cmake build-mac - runs-on: ${{ matrix.os }} + runs-on: self-hosted strategy: matrix: - os: [macos-10.15] -# os: [macos-10.15, macos-11.0] + runner: [macos] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage-macos + - name: cmake_generate-macos run: cmake -S . -B build -G "Unix Makefiles" -DENABLE_SHARED=on -DENABLE_ELEMENTS=on - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -61,17 +65,17 @@ jobs: cmake-ubuntu-test: name: cmake build runs-on: ${{ matrix.os }} + timeout-minutes: 30 strategy: + # Reduce concurrent jobs to prevent cancellations + max-parallel: 3 matrix: - os: [ubuntu-20.04, ubuntu-18.04] + os: [ubuntu-22.04] shared: [on, off] elements: [on, off] - exclude: - - os: ubuntu-18.04 - elements: off steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -90,12 +94,12 @@ jobs: doxygen-ubuntu: name: doxygen-check - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: install_doxygen - run: sudo apt install doxygen graphviz + run: sudo apt-get update && sudo apt-get install -y doxygen graphviz - name: doxygen_check run: | cd doc diff --git a/.github/workflows/check_pre-merge_sprint.yml b/.github/workflows/check_pre-merge_sprint.yml index 8046983b..5d7ea57c 100644 --- a/.github/workflows/check_pre-merge_sprint.yml +++ b/.github/workflows/check_pre-merge_sprint.yml @@ -8,23 +8,28 @@ on: branches: - features/sprint* +# Limit concurrency to prevent job cancellations +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + env: - CMAKE_VERSION: 3.15.5 + CMAKE_VERSION: 3.25.0 jobs: cmake-win: name: cmake build-win - runs-on: windows-2019 + runs-on: windows-2022 strategy: matrix: - generator: ['Visual Studio 16 2019', 'MSYS Makefiles'] + generator: ['Visual Studio 17 2022', 'MSYS Makefiles'] shared: [on] steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage + - name: cmake_generate run: cmake -S . -B build -G "${{ matrix.generator }}" -DENABLE_SHARED=${{ matrix.shared }} -DENABLE_TESTS=on - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -35,17 +40,16 @@ jobs: cmake-mac: name: cmake build-mac - runs-on: ${{ matrix.os }} + runs-on: self-hosted strategy: matrix: - os: [macos-10.15] - # os: [macos-10.15, macos-11.0] + runner: [macos] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage-macos + - name: cmake_generate-macos run: cmake -S . -B build -G "Unix Makefiles" -DENABLE_SHARED=on - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -57,14 +61,17 @@ jobs: cmake-ubuntu-coverage: name: cmake build-ubuntu runs-on: ${{ matrix.os }} + timeout-minutes: 45 strategy: + # Reduce concurrent jobs to prevent cancellations + max-parallel: 2 matrix: - os: [ubuntu-20.04, ubuntu-18.04] + os: [ubuntu-22.04] shared: [on] elements: [on, off] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -73,7 +80,7 @@ jobs: if: matrix.elements == 'on' run: | cat /etc/os-release - sudo apt install lcov + sudo apt-get update && sudo apt-get install -y lcov - name: cmake-build run: | cmake --version @@ -95,20 +102,20 @@ jobs: cd .. - name: upload coverage if: matrix.elements == 'on' - uses: actions/upload-artifact@v1 + uses: actions/upload-artifact@v4 with: name: output-lcov-cfdcore-${{ matrix.os }} path: ./build/lcov_cfdcore_output.zip cmake-cpp-support-test: name: cmake build-ubuntu C++ support test - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 strategy: matrix: cppversion: [11, 14, 17, 20] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -129,11 +136,11 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-18.04] + os: [ubuntu-22.04] shared: [on] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -153,19 +160,19 @@ jobs: # --valgrind-stacksize=1048576 --num-callers=12 valgrind -v --tool=memcheck --leak-check=full --valgrind-stacksize=10485760 --log-file=./valgrind.log --time-stamp=yes ./build/Debug/cfdcore_test - name: upload coverage - uses: actions/upload-artifact@v1 + uses: actions/upload-artifact@v4 with: name: valgrind-log path: ./valgrind.log doxygen-ubuntu: name: doxygen-check - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: install_doxygen - run: sudo apt install doxygen graphviz + run: sudo apt-get update && sudo apt-get install -y doxygen graphviz - name: doxygen_check run: | cd doc diff --git a/.github/workflows/code_scanner.yml b/.github/workflows/code_scanner.yml index bbf68ef6..5e53146c 100644 --- a/.github/workflows/code_scanner.yml +++ b/.github/workflows/code_scanner.yml @@ -18,7 +18,7 @@ on: jobs: analyze-CodeQL: name: CodeQL - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 strategy: fail-fast: false @@ -31,14 +31,14 @@ jobs: steps: - name: Checkout repository - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: # We must fetch at least the immediate parents so that if this is a pull request then we can checkout the head. fetch-depth: 2 # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@v1 + uses: github/codeql-action/init@v3 with: languages: ${{ matrix.language }} # If you wish to specify custom queries, you can do so here or in a config file. @@ -49,7 +49,7 @@ jobs: # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). # If this step fails, then you should remove it and run the build manually (see below) - name: Autobuild - uses: github/codeql-action/autobuild@v1 + uses: github/codeql-action/autobuild@v3 # ℹ️ Command-line programs to run using the OS shell. # https://git.io/JvXDl @@ -61,17 +61,17 @@ jobs: # make release - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v1 + uses: github/codeql-action/analyze@v3 OSSAR-Scan: # OSSAR runs on windows-latest. # ubuntu-latest and macos-latest support coming soon - runs-on: windows-2019 + runs-on: windows-2022 steps: # Checkout your code repository to scan - name: Checkout repository - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: # We must fetch at least the immediate parents so that if this is # a pull request then we can checkout the head. @@ -94,6 +94,6 @@ jobs: # Upload results to the Security tab - name: Upload OSSAR results - uses: github/codeql-action/upload-sarif@v1 + uses: github/codeql-action/upload-sarif@v3 with: sarif_file: ${{ steps.ossar.outputs.sarifFile }} diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt index 12bbcd91..f93129c8 100644 --- a/external/CMakeLists.txt +++ b/external/CMakeLists.txt @@ -61,7 +61,7 @@ if(LIBWALLY_TARGET_URL) set(LIBWALLY_TARGET_REP ${LIBWALLY_TARGET_URL}) message(STATUS "[external project local] libwally-core url=${LIBWALLY_TARGET_URL}") else() -set(LIBWALLY_TARGET_REP cryptogarageinc/libwally-core.git) +set(LIBWALLY_TARGET_REP atomicfinance/libwally-core.git) endif() if(${USE_GIT_SSH}) @@ -156,6 +156,23 @@ set(INSTALL_GTEST OFF CACHE BOOL "" FORCE) add_subdirectory(${CMAKE_SOURCE_DIR}/external/${TEMPLATE_PROJECT_NAME} ${CFD_ROOT_BINARY_DIR}/${TEMPLATE_PROJECT_NAME}/build) + +# Disable specific warnings for GoogleTest that cause issues with newer GCC versions +if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU") + if(TARGET gtest) + target_compile_options(gtest PRIVATE -Wno-maybe-uninitialized) + endif() + if(TARGET gtest_main) + target_compile_options(gtest_main PRIVATE -Wno-maybe-uninitialized) + endif() + if(TARGET gmock) + target_compile_options(gmock PRIVATE -Wno-maybe-uninitialized) + endif() + if(TARGET gmock_main) + target_compile_options(gmock_main PRIVATE -Wno-maybe-uninitialized) + endif() +endif() + set_property(GLOBAL PROPERTY ${TEMPLATE_PROJECT_NAME} 1) endif() endif() # MSVC OR ENABLE_TESTS diff --git a/local_resource/external_project_local_setting.config b/local_resource/external_project_local_setting.config index c50e145e..664b266f 100644 --- a/local_resource/external_project_local_setting.config +++ b/local_resource/external_project_local_setting.config @@ -1,3 +1,3 @@ CFDCORE_VERSION=0.3.19 LIBWALLY_TARGET_VERSION=refs/tags/cfd-0.3.8 -LIBWALLY_TARGET_URL=cryptogarageinc/libwally-core.git +LIBWALLY_TARGET_URL=atomicfinance/libwally-core.git