From 794add16c3b45dd8ef6092c0f909c615dde78167 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Thu, 26 Mar 2026 23:40:23 +0100 Subject: [PATCH 01/10] Add a call of reusable modules CI workflow --- .github/workflows/module-ci.yml | 24 +++++++ CMakePresets.json | 111 ++++++++++++++++++++++++++++++++ opendaq_ref | 2 +- 3 files changed, 136 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/module-ci.yml create mode 100644 CMakePresets.json diff --git a/.github/workflows/module-ci.yml b/.github/workflows/module-ci.yml new file mode 100644 index 0000000..da98640 --- /dev/null +++ b/.github/workflows/module-ci.yml @@ -0,0 +1,24 @@ +name: Module CI + +on: + workflow_dispatch: + inputs: + opendaq-ref: + description: "openDAQ SDK commit, branch or tag" + required: false + default: "" + pull_request: + +jobs: + call-opendaq-modules-ci: + name: Call module CI + uses: openDAQ/actions/.github/workflows/reusable-module-ci.yml@jira/TBBAS-3013-resusable-workflow-ci-module + with: + opendaq-ref: ${{ github.event.inputs.opendaq-ref || '' }} + packages: > + [ + { + "preset-pattern": "ci-build-ubuntu-*", + "packages": {"apt": ["libpcap-dev"]} + } + ] diff --git a/CMakePresets.json b/CMakePresets.json new file mode 100644 index 0000000..cbfa40f --- /dev/null +++ b/CMakePresets.json @@ -0,0 +1,111 @@ +{ + "version": 4, + "configurePresets": [ + { + "name": "ci", + "hidden": true, + "binaryDir": "build/${presetName}", + "cacheVariables": { + "ASAM_CMP_ENABLE_EXAMPLE": false + } + }, + { + "name": "ci-build-type-release", + "hidden": true, + "cacheVariables": { + "CMAKE_BUILD_TYPE": "Release" + } + }, + { + "name": "ci-build-type-debug", + "hidden": true, + "cacheVariables": { + "CMAKE_BUILD_TYPE": "Debug" + } + }, + { + "name": "ci-build-ubuntu-latest-release", + "displayName": "CI Ubuntu Release", + "inherits": ["ci", "ci-build-type-release"], + "generator": "Ninja" + }, + { + "name": "ci-generator-msvc", + "hidden": true, + "generator": "Visual Studio 17 2022", + "architecture": "x64" + }, + { + "name": "ci-build-windows-latest-release", + "displayName": "CI Windows Release", + "inherits": ["ci", "ci-generator-msvc"] + }, + { + "name": "ci-build-ubuntu-latest-debug", + "displayName": "CI Ubuntu Debug", + "inherits": ["ci", "ci-build-type-debug"], + "generator": "Ninja" + }, + { + "name": "ci-build-windows-latest-debug", + "displayName": "CI Windows Debug", + "inherits": ["ci", "ci-generator-msvc"] + } + ], + "buildPresets": [ + { + "name": "ci-build-ubuntu-latest-release", + "configurePreset": "ci-build-ubuntu-latest-release", + "configuration": "Release" + }, + { + "name": "ci-build-windows-latest-release", + "configurePreset": "ci-build-windows-latest-release", + "configuration": "Release" + }, + { + "name": "ci-build-ubuntu-latest-debug", + "configurePreset": "ci-build-ubuntu-latest-debug", + "configuration": "Debug" + }, + { + "name": "ci-build-windows-latest-debug", + "configurePreset": "ci-build-windows-latest-debug", + "configuration": "Debug" + } + ], + "testPresets": [ + { + "name": "ci-test-ubuntu-latest-release", + "configurePreset": "ci-build-ubuntu-latest-release", + "configuration": "Release", + "output": { + "outputOnFailure": true + } + }, + { + "name": "ci-test-windows-latest-release", + "configurePreset": "ci-build-windows-latest-release", + "configuration": "Release", + "output": { + "outputOnFailure": true + } + }, + { + "name": "ci-test-ubuntu-latest-debug", + "configurePreset": "ci-build-ubuntu-latest-debug", + "configuration": "Debug", + "output": { + "outputOnFailure": true + } + }, + { + "name": "ci-test-windows-latest-debug", + "configurePreset": "ci-build-windows-latest-debug", + "configuration": "Debug", + "output": { + "outputOnFailure": true + } + } + ] +} diff --git a/opendaq_ref b/opendaq_ref index 88d050b..232eb11 100644 --- a/opendaq_ref +++ b/opendaq_ref @@ -1 +1 @@ -main \ No newline at end of file +c33debb93c33c950e80e2bc019dcc75172b58b3f \ No newline at end of file From bea8b94f14b5103e758870ca5a8c58c25b6b9072 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika Date: Mon, 30 Mar 2026 23:30:24 +0200 Subject: [PATCH 02/10] Adapt to centralized preset generation in reusable workflow --- .github/workflows/module-ci.yml | 3 +- CMakePresets.json | 97 +-------------------------------- 2 files changed, 5 insertions(+), 95 deletions(-) diff --git a/.github/workflows/module-ci.yml b/.github/workflows/module-ci.yml index da98640..110178f 100644 --- a/.github/workflows/module-ci.yml +++ b/.github/workflows/module-ci.yml @@ -15,10 +15,11 @@ jobs: uses: openDAQ/actions/.github/workflows/reusable-module-ci.yml@jira/TBBAS-3013-resusable-workflow-ci-module with: opendaq-ref: ${{ github.event.inputs.opendaq-ref || '' }} + exclude-configs: '["macos-*"]' packages: > [ { - "preset-pattern": "ci-build-ubuntu-*", + "runners": ["ubuntu-*"], "packages": {"apt": ["libpcap-dev"]} } ] diff --git a/CMakePresets.json b/CMakePresets.json index cbfa40f..6df8dd7 100644 --- a/CMakePresets.json +++ b/CMakePresets.json @@ -2,107 +2,16 @@ "version": 4, "configurePresets": [ { - "name": "ci", - "hidden": true, - "binaryDir": "build/${presetName}", + "name": "module", "cacheVariables": { "ASAM_CMP_ENABLE_EXAMPLE": false } - }, - { - "name": "ci-build-type-release", - "hidden": true, - "cacheVariables": { - "CMAKE_BUILD_TYPE": "Release" - } - }, - { - "name": "ci-build-type-debug", - "hidden": true, - "cacheVariables": { - "CMAKE_BUILD_TYPE": "Debug" - } - }, - { - "name": "ci-build-ubuntu-latest-release", - "displayName": "CI Ubuntu Release", - "inherits": ["ci", "ci-build-type-release"], - "generator": "Ninja" - }, - { - "name": "ci-generator-msvc", - "hidden": true, - "generator": "Visual Studio 17 2022", - "architecture": "x64" - }, - { - "name": "ci-build-windows-latest-release", - "displayName": "CI Windows Release", - "inherits": ["ci", "ci-generator-msvc"] - }, - { - "name": "ci-build-ubuntu-latest-debug", - "displayName": "CI Ubuntu Debug", - "inherits": ["ci", "ci-build-type-debug"], - "generator": "Ninja" - }, - { - "name": "ci-build-windows-latest-debug", - "displayName": "CI Windows Debug", - "inherits": ["ci", "ci-generator-msvc"] - } - ], - "buildPresets": [ - { - "name": "ci-build-ubuntu-latest-release", - "configurePreset": "ci-build-ubuntu-latest-release", - "configuration": "Release" - }, - { - "name": "ci-build-windows-latest-release", - "configurePreset": "ci-build-windows-latest-release", - "configuration": "Release" - }, - { - "name": "ci-build-ubuntu-latest-debug", - "configurePreset": "ci-build-ubuntu-latest-debug", - "configuration": "Debug" - }, - { - "name": "ci-build-windows-latest-debug", - "configurePreset": "ci-build-windows-latest-debug", - "configuration": "Debug" } ], "testPresets": [ { - "name": "ci-test-ubuntu-latest-release", - "configurePreset": "ci-build-ubuntu-latest-release", - "configuration": "Release", - "output": { - "outputOnFailure": true - } - }, - { - "name": "ci-test-windows-latest-release", - "configurePreset": "ci-build-windows-latest-release", - "configuration": "Release", - "output": { - "outputOnFailure": true - } - }, - { - "name": "ci-test-ubuntu-latest-debug", - "configurePreset": "ci-build-ubuntu-latest-debug", - "configuration": "Debug", - "output": { - "outputOnFailure": true - } - }, - { - "name": "ci-test-windows-latest-debug", - "configurePreset": "ci-build-windows-latest-debug", - "configuration": "Debug", + "name": "module-test", + "configurePreset": "module", "output": { "outputOnFailure": true } From 458750bb3eb440dd7dc39d369c6097a5acf3eb11 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika Date: Tue, 31 Mar 2026 09:22:58 +0200 Subject: [PATCH 03/10] Add macOS runner config --- .github/workflows/module-ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/module-ci.yml b/.github/workflows/module-ci.yml index 110178f..ae258eb 100644 --- a/.github/workflows/module-ci.yml +++ b/.github/workflows/module-ci.yml @@ -15,7 +15,6 @@ jobs: uses: openDAQ/actions/.github/workflows/reusable-module-ci.yml@jira/TBBAS-3013-resusable-workflow-ci-module with: opendaq-ref: ${{ github.event.inputs.opendaq-ref || '' }} - exclude-configs: '["macos-*"]' packages: > [ { From 8afd7cc933ac480835fad37c599819c350bb1b53 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika Date: Tue, 31 Mar 2026 19:27:26 +0200 Subject: [PATCH 04/10] Disable unknown warning option for Clang < 10 --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 5c8efcf..0e2b4ba 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -33,6 +33,10 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON) opendaq_common_compile_targets_settings() opendaq_setup_compiler_flags(${REPO_OPTION_PREFIX}) +if (CMAKE_CXX_COMPILER_ID MATCHES "Clang|AppleClang" AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 10) + add_compile_options(-Wno-unknown-warning-option) +endif() + if (${REPO_OPTION_PREFIX}_ENABLE_TESTS) message(STATUS "Unit tests in ${REPO_NAME} are ENABLED") set(OPENDAQ_ENABLE_TEST_UTILS ON CACHE BOOL "Enable testing utils library") From ee925ef0c2aac31434703989e835c4cea894051c Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika Date: Wed, 1 Apr 2026 10:06:44 +0200 Subject: [PATCH 05/10] Restore opendaq_ref back to main --- opendaq_ref | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opendaq_ref b/opendaq_ref index 232eb11..88d050b 100644 --- a/opendaq_ref +++ b/opendaq_ref @@ -1 +1 @@ -c33debb93c33c950e80e2bc019dcc75172b58b3f \ No newline at end of file +main \ No newline at end of file From 105a21c0dc7a15b97e739f0e450711cffab77e4e Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika Date: Wed, 1 Apr 2026 18:44:58 +0200 Subject: [PATCH 06/10] Fix test dependencies on Windows Debug --- modules/asam_cmp_capture_module/tests/CMakeLists.txt | 5 +++++ modules/asam_cmp_data_sink/tests/CMakeLists.txt | 6 ++++++ 2 files changed, 11 insertions(+) diff --git a/modules/asam_cmp_capture_module/tests/CMakeLists.txt b/modules/asam_cmp_capture_module/tests/CMakeLists.txt index b4a620a..e0ab703 100644 --- a/modules/asam_cmp_capture_module/tests/CMakeLists.txt +++ b/modules/asam_cmp_capture_module/tests/CMakeLists.txt @@ -33,6 +33,11 @@ target_link_libraries(${TEST_APP} PRIVATE ${OPENDAQ_SDK_TARGET_NAMESPACE}::opend asam_cmp_capture_module_lib ) +if (MSVC) + target_link_options(${TEST_APP} PRIVATE /DELAYLOAD:wpcap.dll /DELAYLOAD:packet.dll) + target_link_libraries(${TEST_APP} PRIVATE delayimp) +endif() + add_test(NAME ${TEST_APP} COMMAND $ ) diff --git a/modules/asam_cmp_data_sink/tests/CMakeLists.txt b/modules/asam_cmp_data_sink/tests/CMakeLists.txt index 37fc1fd..20d8c1a 100644 --- a/modules/asam_cmp_data_sink/tests/CMakeLists.txt +++ b/modules/asam_cmp_data_sink/tests/CMakeLists.txt @@ -24,6 +24,12 @@ target_link_libraries(${TEST_APP} PRIVATE ${OPENDAQ_SDK_TARGET_NAMESPACE}::opend asam_cmp_data_sink_lib ) +if (MSVC) + target_link_options(${TEST_APP} PRIVATE /DELAYLOAD:wpcap.dll /DELAYLOAD:packet.dll) + target_link_libraries(${TEST_APP} PRIVATE delayimp) +endif() + + add_test(NAME ${TEST_APP} COMMAND $ ) From 027f3333ae7720e9afe07c87708ab6ab8a762cdd Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika Date: Fri, 3 Apr 2026 19:57:15 +0200 Subject: [PATCH 07/10] Change resusable workflow package argument --- .github/workflows/module-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/module-ci.yml b/.github/workflows/module-ci.yml index ae258eb..f13dd32 100644 --- a/.github/workflows/module-ci.yml +++ b/.github/workflows/module-ci.yml @@ -18,7 +18,7 @@ jobs: packages: > [ { - "runners": ["ubuntu-*"], - "packages": {"apt": ["libpcap-dev"]} + "jobs": ["ubuntu-*"], + "apt-install": ["libpcap-dev"] } ] From 54bdf51aff742c50fb6529360c073f7a09eb7483 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika Date: Tue, 7 Apr 2026 08:51:14 +0200 Subject: [PATCH 08/10] Pass presets names explicitly to reusable workflow --- .github/workflows/module-ci.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/module-ci.yml b/.github/workflows/module-ci.yml index f13dd32..c4bdbf0 100644 --- a/.github/workflows/module-ci.yml +++ b/.github/workflows/module-ci.yml @@ -18,7 +18,16 @@ jobs: packages: > [ { - "jobs": ["ubuntu-*"], + "match-jobs": ["ubuntu-*"], "apt-install": ["libpcap-dev"] } ] + cmake-presets: > + [ + { + "match-jobs": ["*"], + "configure-preset": "module", + "test-preset": "module-test" + } + ] + From 138fc35372df14e2399a1c9e7c07b546d0fd8c23 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika Date: Tue, 7 Apr 2026 18:37:48 +0200 Subject: [PATCH 09/10] Rename reusable workflow reference --- .github/workflows/{module-ci.yml => ci-downstream.yml} | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) rename .github/workflows/{module-ci.yml => ci-downstream.yml} (76%) diff --git a/.github/workflows/module-ci.yml b/.github/workflows/ci-downstream.yml similarity index 76% rename from .github/workflows/module-ci.yml rename to .github/workflows/ci-downstream.yml index c4bdbf0..000c756 100644 --- a/.github/workflows/module-ci.yml +++ b/.github/workflows/ci-downstream.yml @@ -1,4 +1,4 @@ -name: Module CI +name: CI Downstream - ASAM CMP on: workflow_dispatch: @@ -10,9 +10,9 @@ on: pull_request: jobs: - call-opendaq-modules-ci: - name: Call module CI - uses: openDAQ/actions/.github/workflows/reusable-module-ci.yml@jira/TBBAS-3013-resusable-workflow-ci-module + call-opendaq-reusable: + name: ASAM CMP + uses: openDAQ/openDAQ-CI/.github/workflows/reusable.yml@jira/TBBAS-3031-reusable-ci with: opendaq-ref: ${{ github.event.inputs.opendaq-ref || '' }} packages: > From cb746a3c7ae6d23708d27f59a7631f1791c670e6 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika Date: Wed, 15 Apr 2026 17:02:06 +0200 Subject: [PATCH 10/10] Change unified workflow ref --- .github/workflows/ci-downstream.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-downstream.yml b/.github/workflows/ci-downstream.yml index 000c756..faae53e 100644 --- a/.github/workflows/ci-downstream.yml +++ b/.github/workflows/ci-downstream.yml @@ -12,7 +12,7 @@ on: jobs: call-opendaq-reusable: name: ASAM CMP - uses: openDAQ/openDAQ-CI/.github/workflows/reusable.yml@jira/TBBAS-3031-reusable-ci + uses: openDAQ/openDAQ-CI/.github/workflows/reusable.yml@v1 with: opendaq-ref: ${{ github.event.inputs.opendaq-ref || '' }} packages: >