Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
e8c7318
ENH: Add Utilities/conda-packages/ rattler-build recipe
CavRiley Apr 16, 2026
e13ad76
BUG: Do not ITK-namespace external IMPORTED targets
hjmjohnson Apr 16, 2026
d0d071f
COMP: Fix hdf5_hl_cpp target-name typo in ITKHDF5_LIBRARIES
hjmjohnson Apr 16, 2026
3014482
COMP: Propagate COMPILE_DEPENDS through target properties
hjmjohnson Apr 17, 2026
6f48850
BUG: Set wrapping install COMPONENT on Python stub directory
hjmjohnson Apr 17, 2026
5545057
ENH: Ignore rattler-build default output/ directory
hjmjohnson Apr 17, 2026
25ff014
BUG: Add ITKZLIB dep to ITKReview for macOS ARM64 link
hjmjohnson Apr 17, 2026
a046c8f
WIP: TEMPORARY - cross-platform conda recipe CI (revert before merge)
hjmjohnson Apr 17, 2026
58990a1
COMP: Pin libcxx <22 in conda recipe for CastXML 0.7.0 compatibility
hjmjohnson Apr 17, 2026
2db0e72
COMP: Skip ITK source-path-length check on Windows conda builds
hjmjohnson Apr 17, 2026
f49cdd3
WIP: Bump conda-recipe-test timeout to 240 min for slower runners
hjmjohnson Apr 17, 2026
35d5c4d
COMP: Use imported target for system double-conversion link
hjmjohnson Apr 17, 2026
88056fd
WIP: Drop paths filter on conda-recipe-test so every push validates
hjmjohnson Apr 17, 2026
35b7416
COMP: Normalize path separators in Python wrapping install warning
hjmjohnson Apr 17, 2026
13b374e
ENH: Pin ITK_USE_SYSTEM_* conda-forge deps to tested ranges
hjmjohnson Apr 17, 2026
1be14b6
COMP: Drop Module_ITKDeprecated from conda build
hjmjohnson Apr 17, 2026
13eb5d4
DOC: Document local rattler-build invocation and stale package cache fix
hjmjohnson Apr 17, 2026
b0dea5a
COMP: Install GDCM DebugDevel component in libitk-devel package
hjmjohnson Apr 17, 2026
72d1664
COMP: Fix Windows libitk-devel test Release/Debug CRT mismatch
hjmjohnson Apr 18, 2026
dd55139
ENH: Install ThirdParty component in conda libitk-devel package
CavRiley Apr 19, 2026
120d2fc
ENH: Generate relocatable cmake_install.cmake in conda libitk-wrapping
CavRiley Apr 19, 2026
057e987
BUG: Fix cmake config dir lookup in conda libitk-wrapping install
CavRiley Apr 19, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 27 additions & 23 deletions .github/workflows/arm.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,33 @@
name: ITK.Arm64

# TEMPORARILY DISABLED on the add-conda-recipe branch — only runnable
# via manual dispatch while the conda-recipe-test workflow exercises
# the feature. Revert the trigger block below before merging.
on:
push:
branches:
- main
- 'release*'
paths-ignore:
- '*.md'
- LICENSE
- NOTICE
- 'Documentation/**'
- 'Utilities/Debugger/**'
- 'Utilities/ITKv5Preparation/**'
- 'Utilities/Maintenance/**'
- 'Modules/Remote/*.remote.cmake'
pull_request:
paths-ignore:
- '*.md'
- LICENSE
- NOTICE
- 'Documentation/**'
- 'Utilities/Debugger/**'
- 'Utilities/ITKv5Preparation/**'
- 'Utilities/Maintenance/**'
- 'Modules/Remote/*.remote.cmake'
workflow_dispatch:
# push:
# branches:
# - main
# - 'release*'
# paths-ignore:
# - '*.md'
# - LICENSE
# - NOTICE
# - 'Documentation/**'
# - 'Utilities/Debugger/**'
# - 'Utilities/ITKv5Preparation/**'
# - 'Utilities/Maintenance/**'
# - 'Modules/Remote/*.remote.cmake'
# pull_request:
# paths-ignore:
# - '*.md'
# - LICENSE
# - NOTICE
# - 'Documentation/**'
# - 'Utilities/Debugger/**'
# - 'Utilities/ITKv5Preparation/**'
# - 'Utilities/Maintenance/**'
# - 'Modules/Remote/*.remote.cmake'

concurrency:
group: '${{ github.workflow }}@${{ github.head_ref || github.ref }}'
Expand Down
94 changes: 94 additions & 0 deletions .github/workflows/conda-recipe-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
name: ITK.CondaRecipe.Test

# TEMPORARY WIP workflow: validate Utilities/conda-packages/ recipe on
# Linux / Windows / macOS using rattler-build. Revert before merging the
# feature branch.

on:
push:
branches:
- main
- 'release*'
- 'add-conda-recipe*'
pull_request:
# Intentionally no paths filter — this is the temporary CI
# platform matrix; we want every push to rerun Linux/Windows/
# macOS so any core or Modules/ change is validated.
workflow_dispatch:

concurrency:
group: '${{ github.workflow }}@${{ github.head_ref || github.ref }}'
cancel-in-progress: ${{ github.event_name == 'pull_request' }}

jobs:
conda-recipe:
runs-on: ${{ matrix.os }}
timeout-minutes: 240
strategy:
fail-fast: false
matrix:
os: [ubuntu-22.04, windows-2022, macos-15]
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 5

- name: Free disk space (Ubuntu)
if: matrix.os == 'ubuntu-22.04'
uses: BRAINSia/free-disk-space@v2
with:
removalmode: "rmz"
swap-storage: "true"
haskell: "true"
dotnet: "true"
docker-images: "false"
tool-cache: "true"
android: "false"
large-packages: "true"
mandb: "true"

- name: Disk space reporting (before build)
shell: bash
run: |
echo "****** df -h"
df -h
echo "****** df -h /"
df -h /

- name: Set up Pixi
uses: prefix-dev/setup-pixi@v0.8.1

- name: Build conda packages (rattler-build)
shell: bash
env:
ITK_CONDA_USE_CCACHE: "0"
run: |
pixi run --environment dev rattler-build build --experimental \
--recipe Utilities/conda-packages/recipe.yaml \
--output-dir "${{ runner.temp }}/itk-conda-channel/"

- name: List produced packages
if: always()
shell: bash
run: |
echo "****** channel contents"
ls -lh "${{ runner.temp }}/itk-conda-channel/"*/ 2>/dev/null \
|| ls -lh "${{ runner.temp }}/itk-conda-channel/" 2>/dev/null \
|| echo "(no channel contents found)"

- name: Disk space reporting (after build)
if: always()
shell: bash
run: |
echo "****** df -h"
df -h

- name: Upload conda packages
if: always()
uses: actions/upload-artifact@v4
with:
name: itk-conda-packages-${{ matrix.os }}
path: ${{ runner.temp }}/itk-conda-channel/**/*.conda
if-no-files-found: warn
retention-days: 7
50 changes: 27 additions & 23 deletions .github/workflows/pixi.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,33 @@
name: ITK.Pixi

# TEMPORARILY DISABLED on the add-conda-recipe branch — only runnable
# via manual dispatch while the conda-recipe-test workflow exercises
# the feature. Revert the trigger block below before merging.
on:
push:
branches:
- main
- 'release*'
paths-ignore:
- '*.md'
- LICENSE
- NOTICE
- 'Documentation/**'
- 'Utilities/Debugger/**'
- 'Utilities/ITKv5Preparation/**'
- 'Utilities/Maintenance/**'
- 'Modules/Remote/*.remote.cmake'
pull_request:
paths-ignore:
- '*.md'
- LICENSE
- NOTICE
- 'Documentation/**'
- 'Utilities/Debugger/**'
- 'Utilities/ITKv5Preparation/**'
- 'Utilities/Maintenance/**'
- 'Modules/Remote/*.remote.cmake'
workflow_dispatch:
# push:
# branches:
# - main
# - 'release*'
# paths-ignore:
# - '*.md'
# - LICENSE
# - NOTICE
# - 'Documentation/**'
# - 'Utilities/Debugger/**'
# - 'Utilities/ITKv5Preparation/**'
# - 'Utilities/Maintenance/**'
# - 'Modules/Remote/*.remote.cmake'
# pull_request:
# paths-ignore:
# - '*.md'
# - LICENSE
# - NOTICE
# - 'Documentation/**'
# - 'Utilities/Debugger/**'
# - 'Utilities/ITKv5Preparation/**'
# - 'Utilities/Maintenance/**'
# - 'Modules/Remote/*.remote.cmake'

concurrency:
group: '${{ github.workflow }}@${{ github.head_ref || github.ref }}'
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Do not add ExternalData module staging files
.ExternalData*

# condapackage uses output as the standard output directory for rattler-builds
output

# back-up files
*~
*.bak
Expand Down
55 changes: 55 additions & 0 deletions CMake/ITKModuleMacros.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,35 @@ macro(itk_module_impl)
message(DEBUG "Linking ${itk-module} to namespaced dependency: ${dep}")
list(APPEND _libraries "${dep}")
else()
# Decide whether to apply the ITK:: namespace.
# External IMPORTED targets (e.g. hdf5-shared from find_package(HDF5)
# in module-mode, bare GDCM targets, etc.) ship under the upstream
# package's own naming and MUST NOT be renamed into the ITK::
# namespace — doing so creates a non-existent target in the
# INTERFACE_LINK_LIBRARIES of ${itk-module}Module and fails CMake's
# generate step. ITK-owned targets (either already defined in this
# session as non-imported, or to be defined later via
# add_subdirectory into a bundled third-party) still receive the
# ITK:: namespace plus the backward-compat EXPORT_CODE shims below.
set(_itk_apply_namespace TRUE)
if(TARGET ${dep})
get_target_property(_itk_dep_imported ${dep} IMPORTED)
if(_itk_dep_imported)
set(_itk_apply_namespace FALSE)
message(
DEBUG
"Linking ${itk-module} to external imported target: ${dep}"
)
endif()
unset(_itk_dep_imported)
endif()
if(NOT _itk_apply_namespace)
list(APPEND _libraries "${dep}")
unset(_itk_apply_namespace)
continue()
endif()
unset(_itk_apply_namespace)

list(
APPEND
_libraries
Expand Down Expand Up @@ -597,6 +626,32 @@ macro(itk_module_link_dependencies)
endif()
endforeach()
endforeach()

# Link COMPILE_DEPENDS as PRIVATE so this module's own compilation picks up
# transitive INTERFACE_INCLUDE_DIRECTORIES (e.g. Eigen3::Eigen via
# ITKEigen3Module) through modern CMake target properties. PRIVATE means
# the includes flow in but nothing leaks into this module's own
# INTERFACE_LINK_LIBRARIES; consumers already get these transitively via
# ${itk-module}Module's INTERFACE chain, which spans TRANSITIVE_DEPENDS
# (PUBLIC_DEPENDS + COMPILE_DEPENDS). Recover COMPILE_DEPENDS as
# TRANSITIVE_DEPENDS minus PUBLIC_DEPENDS because itk_module() unsets
# the original COMPILE_DEPENDS list.
foreach(dep IN LISTS ITK_MODULE_${itk-module}_TRANSITIVE_DEPENDS)
if(NOT dep IN_LIST ITK_MODULE_${itk-module}_PUBLIC_DEPENDS)
if(
ITK_MODULE_${dep}_LOADED
OR
TARGET
${ITK_MODULE_${itk-module}_TARGETS_NAMESPACE}${dep}Module
)
target_link_libraries(
${itk-module}
PRIVATE
${ITK_MODULE_${itk-module}_TARGETS_NAMESPACE}${dep}Module
)
endif()
endif()
endforeach()
endmacro()

macro(itk_module_test)
Expand Down
2 changes: 2 additions & 0 deletions Modules/Nonunit/Review/itk-module.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ itk_module(
ITKReview
DEPENDS
ITKIOImageBase
PRIVATE_DEPENDS
ITKZLIB
COMPILE_DEPENDS
ITKAnisotropicSmoothing
ITKAntiAlias
Expand Down
29 changes: 21 additions & 8 deletions Modules/ThirdParty/DoubleConversion/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,28 @@ mark_as_advanced(ITK_USE_SYSTEM_DOUBLECONVERSION)

if(ITK_USE_SYSTEM_DOUBLECONVERSION)
find_package(double-conversion 3.1.6 REQUIRED)
get_target_property(
ITKDoubleConversion_INCLUDE_DIRS
double-conversion::double-conversion
INTERFACE_INCLUDE_DIRECTORIES
# Use the imported target directly; CMake resolves it per-platform
# (Linux: .so, Windows: .lib import library). Do not use
# get_target_property(... LOCATION), which yields the .dll on Windows
# and produces LNK1107 ("invalid or corrupt file") at link time.
# INTERFACE_INCLUDE_DIRECTORIES propagates through the target, so no
# explicit ITKDoubleConversion_INCLUDE_DIRS assignment is required.
set(ITKDoubleConversion_LIBRARIES double-conversion::double-conversion)

# Ensure downstream consumers of the installed ITKConfig have the
# double-conversion:: imported target before ITKTargets.cmake is
# processed (which references it in INTERFACE_LINK_LIBRARIES).
set(
ITKDoubleConversion_EXPORT_CODE_INSTALL
"find_package(double-conversion 3.1.6 REQUIRED)"
)
get_target_property(
ITKDoubleConversion_LIBRARIES
double-conversion::double-conversion
LOCATION
set(
ITKDoubleConversion_EXPORT_CODE_BUILD
"
if(NOT ITK_BINARY_DIR)
find_package(double-conversion 3.1.6 REQUIRED)
endif()
"
)
else()
set(
Expand Down
4 changes: 2 additions & 2 deletions Modules/ThirdParty/HDF5/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ endif()
hdf5_cpp-shared
hdf5-shared
hdf5_hl-shared
hdf5_hl_cpp
hdf5_hl_cpp-shared
)
elseif(TARGET hdf5::hdf5-shared)
set(
Expand Down Expand Up @@ -75,7 +75,7 @@ endif()
hdf5_cpp-static
hdf5-static
hdf5_hl-static
hdf5_hl_cpp
hdf5_hl_cpp-static
)
elseif(TARGET hdf5::hdf5-static)
set(
Expand Down
Loading
Loading