Repository navigation
Conversation
check_nifti_mangled.cmake only looked for nifti_image_read. The minc-toolkit superbuild builds the ITK nifti_clib fork (f24a607) with this repository's nifti_mangle.h, which was written for v3.0.0. Three exports the fork added -- nifti_image_write_status, nifti_image_write_bricks_status and nifti_set_fix_floats -- are left unprefixed, and a develop-1.9.18 toolkit build exports them so from libminc2.so. That is the collision the rename exists to prevent, and this test did not see it. The test now fails on any defined global symbol without the minc_ prefix, and runs on libznz.a as well as libniftiio.a. The positive check becomes "the archive defines at least one symbol", so it applies to both archives and still catches an archive with no NIfTI code in it (a slim-LTO object with its IR stripped is one). Verified: on this branch (standalone, nifti_clib v3.0.0) all 102 symbols of libniftiio.a and all 8 of libznz.a pass, and ctest passes 60/60. Against a develop-1.9.18 toolkit install the script names exactly the three symbols above. It fails an archive that defines nifti_foo, and one that holds no code. No list(TRANSFORM), which needs CMake 3.12; libminc requires 3.10. Fixes BIC-MNI/minc-toolkit-v2#246, together with the nifti_mangle.h update in the nifti_clib pin bump. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RCrjXCD1KiTWLtah7wmySX
This was referenced Sep 21, 2026
gdevenyi
marked this pull request as draft
September 21, 2026 19:24
gdevenyi
marked this pull request as ready for review
September 21, 2026 22:08
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
BIC-MNI/minc-toolkit-v2#246.
testdir/check_nifti_mangled.cmakechecks onlynifti_image_read. The minc-toolkit superbuild builds the ITK nifti_clib fork (f24a607) with this repository'snifti_mangle.h, which was written for v3.0.0. Three symbols that the fork added have nominc_prefix, and adevelop-1.9.18toolkit build exports them fromlibminc2.so:This is the collision that the rename must prevent, and the test did not find it.
What
minc_prefix.libznz.aas well aslibniftiio.a(new testznz_mangle_symbols).Verification
libniftiio.aand all 8 oflibznz.apass. ctest passes 60/60.develop-1.9.18toolkit install, the script names exactly the three symbols above.nifti_foo, and an archive that has no code.list(TRANSFORM), which needs CMake 3.12. libminc requires 3.10.Notes
nifti_mangle.hfor the new pin. This PR and NIfTI: track the maintained nifti_clib fork, drop the dead vendored copy #152 together fix minc-toolkit-v2#246. This PR alone passes ondevelop-1.9.18, because standalone libminc still pins v3.0.0 there.🤖 Generated with Claude Code
https://claude.ai/code/session_01RCrjXCD1KiTWLtah7wmySX