Skip to content

Commit bd92101

Browse files
committed
ENH: Pin ITK_USE_SYSTEM_* conda-forge deps to tested ranges
conda-forge packages advance at roughly monthly cadence while ITK's vendored third-party copies advance roughly annually. An unpinned recipe picks up the newest conda-forge version at build time, so an HDF5 2.0 / TBB 2023 / Eigen 3.5 upload silently breaks the next build. Pin each ITK_USE_SYSTEM_*-eligible dep in the build-cache host: block with floor = ITK's vendored version and ceiling = next expected ABI break. Apply matching pins to libitk.run: and libitk-devel.run:; tbb ceiling reflects the oneTBB 2022 stable line pre-dating the 2023 rewrite. Python floor raised to 3.10 to track PEP 719 support status. Also replace the two conda-forge metapackages (zlib, expat) with the concrete libs (libzlib, libexpat). The metapackages emit run_exports for the real lib, which was producing spurious "Overdepending against libzlib/libexpat" warnings in every build.
1 parent 35b7416 commit bd92101

File tree

1 file changed

+42
-28
lines changed

1 file changed

+42
-28
lines changed

Utilities/conda-packages/recipe.yaml

Lines changed: 42 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,18 @@ outputs:
3030
then: bash Utilities/conda-packages/build.sh
3131
else: call Utilities\conda-packages\build.bat
3232
requirements:
33+
# Version pin policy: floors match ITK's vendored third-party
34+
# versions (Modules/ThirdParty/*/src/); ceilings stop at the
35+
# next expected ABI / API break (major version). conda-forge
36+
# packages move faster than ITK's vendored copies, so explicit
37+
# ranges are required to keep builds deterministic as upstream
38+
# packages advance. Revisit at each ITK release.
3339
build:
34-
- cmake >=3.16.3
40+
- cmake >=3.22.1,<5
3541
- ninja
3642
- ${{ compiler('c') }}
3743
- ${{ compiler('cxx') }}
38-
- castxml >=0.7.0
44+
- castxml >=0.7.0,<0.8
3945
# castxml 0.7.0 bundles Clang 20, which cannot parse the
4046
# __acquire_capability__ pack-expansion syntax introduced in
4147
# libc++ 22's <mutex>. Pin libc++ to <22 until a castxml release
@@ -45,21 +51,26 @@ outputs:
4551
- if: env.get("ITK_CONDA_USE_CCACHE", default="0") == "1"
4652
then: ccache
4753
- if: build_platform != target_platform
48-
then: python
54+
then: python >=3.10,<3.15
4955
host:
56+
# Use the concrete conda-forge lib names (libzlib / libexpat)
57+
# rather than the legacy metapackages (zlib / expat); the
58+
# metapackages caused "Overdepending against libzlib/libexpat"
59+
# warnings in earlier builds because run_exports point at the
60+
# lib*.
5061
- if: unix
5162
then:
52-
- expat
53-
- libpng
54-
- zlib
55-
- fftw
56-
- hdf5
57-
- libjpeg-turbo
58-
- libtiff
59-
- eigen
60-
- double-conversion
61-
- tbb-devel
62-
- python
63+
- libexpat >=2.5,<3
64+
- libpng >=1.6.43,<1.7
65+
- libzlib >=1.2.13,<2
66+
- fftw >=3.3.10,<3.4
67+
- hdf5 >=1.14.5,<2
68+
- libjpeg-turbo >=3.0,<4
69+
- libtiff >=4.6,<5
70+
- eigen >=3.4,<3.5
71+
- double-conversion >=3.3,<4
72+
- tbb-devel >=2022.2.0,<2023
73+
- python >=3.10,<3.15
6374
source:
6475
path: ../..
6576

@@ -75,17 +86,20 @@ outputs:
7586
else: call Utilities\conda-packages\libitk_install.bat
7687
requirements:
7788
run:
89+
# Most of these are already carried by run_exports from the
90+
# host pins above, but being explicit keeps the recipe
91+
# self-documenting and independent of feedstock behavior.
7892
- if: unix
7993
then:
80-
- expat
81-
- libpng
82-
- zlib
83-
- fftw
84-
- hdf5
85-
- libjpeg-turbo
86-
- libtiff
87-
- double-conversion
88-
- tbb
94+
- libexpat >=2.5,<3
95+
- libpng >=1.6.43,<1.7
96+
- libzlib >=1.2.13,<2
97+
- fftw >=3.3.10,<3.4
98+
- hdf5 >=1.14.5,<2
99+
- libjpeg-turbo >=3.0,<4
100+
- libtiff >=4.6,<5
101+
- double-conversion >=3.3,<4
102+
- tbb >=2022.2.0,<2023
89103
tests:
90104
- script:
91105
- if: osx
@@ -112,9 +126,9 @@ outputs:
112126
- ${{ pin_subpackage('libitk', exact=True) }}
113127
run:
114128
- ${{ pin_subpackage('libitk', exact=True) }}
115-
- tbb-devel
116-
- cmake
117-
- eigen
129+
- tbb-devel >=2022.2.0,<2023
130+
- cmake >=3.22.1,<5
131+
- eigen >=3.4,<3.5
118132
tests:
119133
- script:
120134
- if: unix
@@ -152,10 +166,10 @@ outputs:
152166
requirements:
153167
host:
154168
- ${{ pin_subpackage('libitk', exact=True) }}
155-
- python >=3.9
169+
- python >=3.10,<3.15
156170
run:
157171
- ${{ pin_subpackage('libitk', exact=True) }}
158-
- python >=3.9
172+
- python >=3.10,<3.15
159173
- numpy
160174
tests:
161175
- python:

0 commit comments

Comments
 (0)