Repository navigation
Seg3D resurrection: umbrella tracking issue (build, CI, Qt6, modernization) #423
Description
Why this issue
Seg3D has not had continuous maintenance since 2021. master's last commit is 2023-04-07 (a typo fix); the last substantive work was February 2022, and the last release was v2.5.1 in May 2021. In the meantime the toolchain moved and the build rotted out from under the repo.
As of today, Seg3D does not configure at all on a current CMake. It fails on lines 27 and 30 of Superbuild/CMakeLists.txt before doing anything else.
This is an umbrella tracking issue. It is deliberately one giant checklist so we can see the whole shape of the problem in one place; individual items will be spun out into sub-issues as they get picked up. Nothing here needs to be done in one go, and Stage 0 alone is most of the value.
The honest framing: this is volunteer effort, so the plan is optimized for getting to a green build fast and then not rotting again, rather than for doing the most interesting work first.
Reproducing the current state
$ cmake ../Superbuild
CMake Error at CMakeLists.txt:27 (cmake_minimum_required):
Compatibility with CMake < 3.5 has been removed from CMake.
$ cmake ../Superbuild -DCMAKE_POLICY_VERSION_MINIMUM=3.5
CMake Error at CMakeLists.txt:30 (cmake_policy):
Policy CMP0053 may not be set to OLD behavior because this version of CMake
no longer supports it.
(Tested with CMake 4.3.3 / AppleClang 17.)
Inventory of what is stale
| Component | Pinned at | Status |
|---|---|---|
| CMake minimum | 2.8.12 (CMakeLists.txt:27), CMP0053 OLD (:30) |
Hard failure on CMake ≥ 4 |
| Tetgen | SVN from gforge.sci.utah.edu (TetgenExternal.cmake:51) |
Host is gone — connection times out |
| Python | 3.4.3 (PythonExternal.cmake:32-34) |
EOL March 2019 |
| Boost | 1.67, 1.58 fallback (BoostExternal.cmake:67-69) |
2018 |
| Qt | Qt5 only, min 5.9/5.12 (Superbuild.cmake:146-155) |
Qt5 is EOL |
| ITK | v5.2.0 (ITKExternal.cmake:92) |
current is v5.4.6 |
| Eigen | 3.3.7 tarball from eigenteam/eigen-git-mirror |
Mirror frozen since 2022 |
| C++ standard | -std=c++11 (Superbuild.cmake:185) |
|
| macOS minimum | 10.12 (Superbuild.cmake:47) |
No Apple Silicon story |
Externals pinned to origin/master |
Data, Freetype, SQLite, ImplicitFunction, Glew, LibPNG, Zlib, Teem, Python | Builds are not reproducible |
Note that Tetgen is added unconditionally (Superbuild.cmake:262) — there is no option guarding it. The SVN fetch happens at build time, so this surfaces as a build failure rather than a configure failure.
CI is entirely non-functional
All three workflows fail. The most recent runs (January 2026) are all failure or cancelled.
linux.yml— targetsubuntu-18.04, a runner image GitHub retiredwindows.yml— targetswindows-2016, VS 2017 generator,win64_msvc2017_64, and builds withBUILD_WITH_PYTHON=OFFso Python is never exercised on Windowsmac.yml— symlinks a macOS 10.14 SDK path that does not exist on current runners- All three use
actions/checkout@v2,jurplel/install-qt-action@v2, andactions/upload-artifact@v2(the v2 artifact backend was shut down in January 2025 — this is a hard failure regardless of anything else) - A dead
.travis.ymlis still in the tree
Guiding principle: take it from SCIRun
Seg3D and SCIRun already share most of their external dependency fork set:
CIBC-Internal/{freetype, glew, libpng, python, sqlite, zlib}, SCIInstitute/teem, and CIBC-Internal/Seg3DData.
SCIRun has kept these current and has already been through the CMake 4 wall, the Python bump, and the Qt6 migration. It also carries CIBC-Internal/TetGen.git — a live git repository that directly replaces Seg3D's dead gforge SVN checkout.
So a large fraction of Stage 0 is porting SCIRun's Superbuild external files across, not solving new problems. Where SCIRun has an answer, we should take the answer rather than invent a second one.
Stage 0 — Make it build again
Goal: green CI on all three platforms plus a downloadable installer artifact. This is where nearly all the value is. Until this is done, no other contribution to Seg3D can even be evaluated.
CMake unblocking
- Raise
cmake_minimum_requiredto a3.16...3.28-style range inSuperbuild/CMakeLists.txtandsrc/CMakeLists.txt - Delete
cmake_policy(SET CMP0053 OLD); fix any variable-expansion fallout the NEW behavior exposes - Audit remaining
cmake_policy(... OLD)calls across the tree - Add
-DCMAKE_POLICY_VERSION_MINIMUM=3.5shims for externals too old to fix upstream (SCIRun uses exactly this inTnyExternal.cmakeandOsprayExternal.cmake) - Set
CMP0135(DOWNLOAD_EXTRACT_TIMESTAMP) explicitly for URL-based externals - Confirm a clean configure end-to-end with no
-DCMAKE_POLICY_VERSION_MINIMUMescape hatch at the top level
Dependency rehabilitation
- Replace the Tetgen SVN external with
CIBC-Internal/TetGen.git, or make Tetgen optional and default it off — decide which - Bump Python off 3.4.3 (
CIBC-Internal/pythonhas newer; align the version with SCIRun's) — closes Upgrade Python version #315 - Bump Boost; rebase the existing
upgrade-externalsbranch work (see Salvage below) — closes Upgrade boost #174 - Repoint Eigen away from the dead
eigen-git-mirrorto a current upstream release - Bump ITK 5.2.0 → 5.4.x — relates to Full ITK5 Upgrade #383
- Port SCIRun's versions of the shared externals (freetype, glew, libpng, sqlite, zlib, teem)
- Replace every
GIT_TAG "origin/master"with a real tag or SHA — aVERSIONS.cmakesingle source of truth, mirroring SCIRun's dependency-manifest work - Audit
src/ThirdParty/(MRC2000IO,MatlabIO,tinyxml,submodules) — decide keep / replace with upstream / delete - Resolve the GDCM build failure in Linux build fails on error in ThirdParty/GDCM #417
CI reconstruction
- Merge or rebase PR Simplify build system and add python as dependency #407 first — it already does much of this
- Move to current runner images (
ubuntu-latest/ubuntu-22.04,windows-latest,macos-latest) - Bump
actions/checkout,actions/upload-artifact, andinstall-qt-actionto current major versions - Remove the macOS 10.14 SDK symlink hack
- Build Windows with Python enabled — relates to Broken windows build without python #332
- Add arm64 / universal2 macOS builds; raise
OSX_MINIMUM_OS_VERSIONoff 10.12 — relates to Propagate OS X SDK and version CMake settings #204 - Delete
.travis.yml - Add concurrency cancellation for repeated pushes (in PR Simplify build system and add python as dependency #407)
- Get CPack packaging working again on all three platforms — closes Fix CPack package build #367
- Publish installer artifacts from CI
Housekeeping
- Add a root
LICENSEfile — GitHub currently reports the repo as unlicensed because the license only lives atsrc/License.txt - Update
README.mdwith build instructions that actually work - Triage the 137 open issues; close what the rebuild fixes, label the rest
Stage 1 — Qt6
Qt5 is end-of-life. SCIRun already supports both; copy its approach rather than inventing one.
- Adopt SCIRun's dual-version pattern — a
QT_MIN_VERSIONcache variable with a version list andQt${QT_VERSION_MAJOR}indirection, so Qt5 and Qt6 can coexist during the migration - Replace hardcoded
Qt5::link targets withQt${QT_VERSION_MAJOR}::(src/CMakeLists.txt:265-270,src/Resources/CMakeLists.txt:93,src/QtUtils/Utils/CMakeLists.txt:98, and others) -
QGLWidget→QOpenGLWidget(5 files;Renderer.ccandQtRenderWidget.ccare the load-bearing ones) — closes unlink Qt OpenGL module after converting from QGLWidget to QOpenGLWidget #119, relates to Qt 5 OpenGL updates #150 -
QGLFormat→QSurfaceFormat(5 files) -
QGLContext→QOpenGLContext(1 file) -
QRegExp→QRegularExpression(5 files) -
QDesktopWidget→QScreen(2 files) -
setMargin→setContentsMargins(1 file) - Regenerate/verify the 73
.uifiles underuic6 - Verify the Qt bridge layer (
src/QtUtils/Bridge/detail/*) against Qt6 signal/slot changes - Fix
Qt5_PATHnot overriding Linux CMake defaults — closes Linux CMake defaults for QT binaries not overwritten by Qt5_PATH #235 - Resolve Windows build QT #422 (Windows build Qt)
Stage 2 — Modernization
Not blocking anything; do it opportunistically once CI is green and can actually catch regressions.
- C++11 → C++17 (SCIRun is already there)
- Collapse Boost into std where C++17 covers it — the bulk is mechanical:
-
boost::shared_ptr→std::shared_ptr(110 includes) -
boost::filesystem→std::filesystem(84 includes) -
boost::thread/mutex/condition_variable→<thread>,<mutex>(~60 includes) -
boost::bind/boost::lambda→ lambdas (~50 includes) -
BOOST_FOREACH→ range-for (9 includes) -
boost::unordered_map→std::unordered_map(6 includes) -
boost::tuple→std::tuple— closes Replace boost tuple with std #142 -
boost::thread::hardware_concurrency→std::thread::hardware_concurrency— closes Switch from boost hardware_concurrency to C++11 #95 - Keep
boost::signals2(no std equivalent) and re-evaluate the rest
-
- Take PR Use GrowCut now available in ITK #405 — deletes vendored GrowCut in favour of upstream ITK's
- Complete the ITK5 upgrade — Full ITK5 Upgrade #383
- Turn on
BUILD_TESTINGin CI (currently defaults OFF and there is essentially no test coverage); port SCIRun's CI test approach - Python API items: Python Macro/Script Editor Feature Request #351 (macro/script editor), Building with existing python installations #354 (existing interpreters), Add Seg3D specific PYTHONPATH environment variable #102/Add methods to extract raw data from data block classes for Python #103/Build seg3d python module for custom built interpreter #105, Add scipy stack to python #177 (scipy stack), exportsegmentation python call needs to pass index values #411 (export index values)
- Evaluate a conda build — conda build #201
Stage 3 — Renderer (do not start yet)
15 files still use fixed-function OpenGL (glBegin, glMatrixMode, glPushMatrix, glVertex3), including Renderer.cc, VolumeRendererOcclusion.cc, and most of src/Application/Tools/.
This is blocked on a decision, not on effort. SCIRun is currently evaluating a VTK-based renderer on its own branch. Seg3D has a parallel vtk_rendering branch from 2021. Whether Seg3D goes to modern core-profile GL or to VTK is the same decision as SCIRun's, and it should be made once and applied to both.
- Decide: modern GL vs. VTK — jointly with the SCIRun renderer decision
- Separate rendering/viewers from the Qt UI layer — separate rendering and viewers from QT UI layers #413 (worth doing under either outcome)
- Port or retire the
vtk_renderingbranch depending on the outcome
Salvage: work that already exists and was never merged
Three people showed up with patches and they were never landed. This is the cheapest work available.
- PR Simplify build system and add python as dependency #407 — Simplify build system and add python as dependency (@jcfr). Open since Feb 2022, still mergeable. +56/−121 across 16 files: removes Travis, bumps all Actions, adds concurrency cancellation, makes
QT_MIN_VERSIONoverridable. Should be the first thing merged. - PR Use GrowCut now available in ITK #405 — Use GrowCut now available in ITK (@dzenanz). Deletes vendored code in favour of upstream ITK.
- PR Better font rendering on OSX #353 — Better font rendering on OSX (@allywarner).
-
upgrade-externalsbranch — Boost + Python bumps andboost::bindnamespace fixes. 134 files, +2193/−1990. A large fraction of the Boost migration is already written and just needs rebasing. -
vtk_renderingbranch — see Stage 3. - Other unmerged branches to triage:
openglwidget,font_rendering,debug-renderer,python,osx_double_click,seed_points_preference,reading-LHS-images,implicit-model-kernel-update,implicit-model-layer-option,docs_build,docs-update
Existing issues this umbrella covers
Build and dependencies: #33, #37, #62, #201, #204, #235, #315, #332, #354, #367, #368, #373, #414, #415, #417, #422
Qt and rendering: #119, #150, #413
Boost and C++: #95, #142, #174
ITK: #383
Python: #102, #103, #105, #177, #351, #411
Several of these are ten years old and describe exactly the problems above. They should be linked as sub-issues rather than duplicated.
Not rotting again
The technical debt above accumulated because maintenance stopped and nothing in the repo noticed. The rebuild should leave behind guardrails that fail loudly:
- Every dependency pinned to an explicit version in one file, so "what changed?" is always answerable
- CI that builds all three platforms on every PR, so breakage surfaces in days rather than years
- A scheduled build so the repo notices rot even during quiet periods with no PRs
- A build that works from a clean checkout with documented prerequisites, so a new contributor's first hour is not spent on archaeology
- Shared infrastructure kept genuinely shared with SCIRun, so dependency maintenance is done once rather than twice
Open questions
- Is Tetgen still needed at all, or can it be dropped?
- Which Qt6 minimum should we target, and do we keep Qt5 support after the migration or cut it?
- Do the vendored
src/ThirdParty/components have live upstreams worth tracking? - Renderer direction — see Stage 3
- What is the minimum platform matrix we are willing to commit to supporting?
Activity
dcwhite commentedon Aug 4, 2026
Do not start. Focus is SCIRun.