From 8f36dedc17689f3c1498014dc99ff98bd5a6bf4e Mon Sep 17 00:00:00 2001 From: "Hans J. Johnson" Date: Mon, 21 Sep 2026 10:05:34 -0500 Subject: [PATCH 1/3] COMP: Build against ITK 6 Two changes, both of which keep the module building against ITK 5.4 as well. The module pinned CMAKE_CXX_STANDARD to 14 before find_package(ITK). ITK 6 carries its own requirement on its imported targets, so the module's library compiled as C++17 regardless, but the wrapping subdirectory reads CMAKE_CXX_STANDARD directly to pick castxml's -std flag. castxml then parsed ITK 6 headers as C++14 and failed on std::is_convertible_v in itkSmartPointer.h. Take the standard from ITK_CXX_STANDARD, which both 5.4 and 6 export, and only when the caller has not already chosen one. ITK 6 also turns ITK_DISALLOW_COPY_AND_ASSIGN into a static assertion asking for ITK_DISALLOW_COPY_AND_MOVE, which ITK 5.4 defines as well. --- CMakeLists.txt | 4 +++- include/itkStructurePreservingColorNormalizationFilter.h | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8e3884a..ac05eb9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,9 +1,11 @@ cmake_minimum_required(VERSION 3.16.3) project(StructurePreservingColorNormalization) -set(CMAKE_CXX_STANDARD 14) if(NOT ITK_SOURCE_DIR) find_package(ITK REQUIRED) + if(NOT DEFINED CMAKE_CXX_STANDARD AND DEFINED ITK_CXX_STANDARD) + set(CMAKE_CXX_STANDARD ${ITK_CXX_STANDARD}) + endif() list(APPEND CMAKE_MODULE_PATH ${ITK_CMAKE_DIR}) include(ITKModuleExternal) else() diff --git a/include/itkStructurePreservingColorNormalizationFilter.h b/include/itkStructurePreservingColorNormalizationFilter.h index 7aaba5f..a7ed129 100644 --- a/include/itkStructurePreservingColorNormalizationFilter.h +++ b/include/itkStructurePreservingColorNormalizationFilter.h @@ -74,7 +74,7 @@ template class StructurePreservingColorNormalizationFilter : public ImageToImageFilter { public: - ITK_DISALLOW_COPY_AND_ASSIGN(StructurePreservingColorNormalizationFilter); + ITK_DISALLOW_COPY_AND_MOVE(StructurePreservingColorNormalizationFilter); /** Specific class typedefs */ using ImageType = TImage; From 71d2161d861b0a2a84f99405f25f0c800479fd7c Mon Sep 17 00:00:00 2001 From: "Hans J. Johnson" Date: Thu, 24 Sep 2026 10:18:52 -0500 Subject: [PATCH 2/3] COMP: Update the reusable CI workflow to a current, tagged release Pinned to a raw commit SHA from before ITKRemoteModuleBuildTestPackageAction had version tags, which carries a runner-image matrix (ubuntu-20.04, macos-11) that GitHub has since retired, failing every job at VM allocation. v5.4.4 is the latest tagged release, matching what sibling remote modules already use. --- .github/workflows/build-test-package.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-test-package.yml b/.github/workflows/build-test-package.yml index ffdfa24..ba3306a 100644 --- a/.github/workflows/build-test-package.yml +++ b/.github/workflows/build-test-package.yml @@ -4,9 +4,9 @@ on: [push,pull_request] jobs: cxx-build-workflow: - uses: InsightSoftwareConsortium/ITKRemoteModuleBuildTestPackageAction/.github/workflows/build-test-cxx.yml@36e33ec40332bb8fd85bfcd3ee899f82aa108e79 + uses: InsightSoftwareConsortium/ITKRemoteModuleBuildTestPackageAction/.github/workflows/build-test-cxx.yml@v5.4.4 python-build-workflow: - uses: InsightSoftwareConsortium/ITKRemoteModuleBuildTestPackageAction/.github/workflows/build-test-package-python.yml@36e33ec40332bb8fd85bfcd3ee899f82aa108e79 + uses: InsightSoftwareConsortium/ITKRemoteModuleBuildTestPackageAction/.github/workflows/build-test-package-python.yml@v5.4.4 secrets: pypi_password: ${{ secrets.pypi_password }} From c5142ad5016c67f5601676de85e140c07642c0df Mon Sep 17 00:00:00 2001 From: "Hans J. Johnson" Date: Thu, 24 Sep 2026 10:18:52 -0500 Subject: [PATCH 3/3] COMP: Point the clang-format lint action at its current branch InsightSoftwareConsortium/ITKClangFormatLinterAction renamed its default branch from master to main, so @master no longer resolves and the lint job fails before running. Also bumps actions/checkout from the deprecated v2 to v4, matching sibling remote modules. --- .github/workflows/clang-format-linter.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/clang-format-linter.yml b/.github/workflows/clang-format-linter.yml index ab5019f..7aa066c 100644 --- a/.github/workflows/clang-format-linter.yml +++ b/.github/workflows/clang-format-linter.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: InsightSoftwareConsortium/ITKClangFormatLinterAction@master + - uses: actions/checkout@v4 + - uses: InsightSoftwareConsortium/ITKClangFormatLinterAction@main with: error-message: 'Code is inconsistent with ITK Coding Style. Add the *action:ApplyClangFormat* PR label to correct.'