Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
101 commits
Select commit Hold shift + click to select a range
5288c27
fixing cmake and externals
basisunus Jan 14, 2026
d808f56
boost builds on windows with vs 2022
basisunus Jan 15, 2026
b9358db
fixing qt errors
basisunus Jan 15, 2026
8ef9b25
fixing boost include dir
basisunus Jan 21, 2026
e9dcbbd
cleaned boost issues
basisunus Jan 22, 2026
c3e0c04
fixing python new version
basisunus Jan 22, 2026
4d7ffbc
udpated cmakes for externals
basisunus Jan 26, 2026
18d684c
issues with externals
basisunus Jan 26, 2026
e948db0
updated tetgen to install
basisunus Jan 27, 2026
64ec713
removed errors from cleaver2
basisunus Jan 27, 2026
f5ef94d
updating external cmakes
basisunus Jan 27, 2026
336571d
external cmakes
basisunus Jan 29, 2026
056c4d1
fixing freetype
basisunus Jan 29, 2026
7b788d5
making cmake changes
basisunus Jan 29, 2026
92bb6cb
Merge branch 'master' into refactor
basisunus Jan 29, 2026
5efaeb8
fixing dependency on zlib for external libs
basisunus Jan 30, 2026
1d869a5
fixing zlib interdependency
basisunus Jan 30, 2026
0ecda93
updated teem
basisunus Jan 30, 2026
cb8a5f2
fixed teem
basisunus Feb 2, 2026
01b54f0
scirun cmake errors
basisunus Feb 3, 2026
3ff41f9
making sure paths generated in superbuild are correct. need to check …
basisunus Feb 3, 2026
103f83b
finding boost in scirun src
basisunus Feb 4, 2026
6d0402a
installing boost headers
basisunus Feb 4, 2026
bac6179
fixed glm headers but there are more for boost, glew, tny, lodepng
basisunus Feb 5, 2026
e432dd0
cmake
basisunus Feb 6, 2026
1168d71
cmake
basisunus Feb 6, 2026
a013417
headers
basisunus Feb 6, 2026
ab20c05
header copy
basisunus Feb 6, 2026
41d0e34
tny header path
basisunus Feb 6, 2026
65ec892
default qt path on my computer
basisunus Feb 6, 2026
13ae258
boost lib version names
basisunus Feb 6, 2026
227012c
sqlite issue
basisunus Feb 9, 2026
358c89d
sqlite
basisunus Feb 9, 2026
8ac87b7
python
basisunus Feb 10, 2026
f395200
python issues
basisunus Feb 10, 2026
6d914fa
link error
basisunus Feb 11, 2026
3925747
more errors
basisunus Feb 11, 2026
74506a8
freetype
basisunus Feb 11, 2026
9fb63dd
more errors
basisunus Feb 11, 2026
9a2449d
cmake
basisunus Feb 11, 2026
50e6318
teem linking error
basisunus Feb 13, 2026
c1a0d96
linking errors of modules
basisunus Feb 14, 2026
362c781
cleaver path
basisunus Feb 17, 2026
876f951
boost python
basisunus Feb 17, 2026
17875f1
Merge branch 'master' into refactor
basisunus Feb 17, 2026
7ca6d58
removed some linking errors
basisunus Feb 17, 2026
e24d46a
adding libs to link
basisunus Feb 18, 2026
c07019a
teem link
basisunus Feb 18, 2026
b7b1972
fixing python linking errors
basisunus Feb 20, 2026
a8ae911
python issues in boost and scirun python api
basisunus Feb 21, 2026
af32588
linking errors, python lib, zlib used by teem
basisunus Feb 23, 2026
3dffada
remove system python from superbuild and stick with external python
basisunus Feb 23, 2026
e4e52d4
python path and external lib paths
basisunus Feb 24, 2026
0df70da
tetgen inlcude path
basisunus Feb 24, 2026
b976d40
tetgen not found issue
basisunus Feb 27, 2026
2b2312a
python and qwt
basisunus Mar 2, 2026
593be22
ctk deprecated functions
basisunus Mar 3, 2026
ab2cc98
qwt wrapper
basisunus Mar 3, 2026
83a75c2
qwt build
basisunus Mar 3, 2026
f64bd7e
Pin googletest submodule to v1.14.0 (replace missing ref 8565cc5...)
basisunus Mar 5, 2026
2aa633a
boost exception
basisunus Mar 5, 2026
359021a
vc143.pdb conflicts
basisunus Mar 5, 2026
2bef99c
vc debug-release mismatch
basisunus Mar 5, 2026
97ba8fc
release vs debug crt settings
basisunus Mar 6, 2026
957ec59
qwt lib linking
basisunus Mar 6, 2026
d35e377
updated tetgen call to 1.6 signature
basisunus Mar 9, 2026
1ca8c0a
glew and tny missing
basisunus Mar 9, 2026
6675770
glew not found
basisunus Mar 9, 2026
e8ad94f
python update error
basisunus Mar 9, 2026
2efffc7
freetype lib not found
basisunus Mar 10, 2026
e559ab0
added Core_Algorithm_Legacy_Fields to where it's needed
basisunus Mar 10, 2026
f6c24fc
typos in lib name
basisunus Mar 10, 2026
c4f05eb
more missing libs in link
basisunus Mar 11, 2026
30130a1
lodepng not found for linking
basisunus Mar 11, 2026
a302be3
qt flag not passed to modules
basisunus Mar 12, 2026
8e8f84d
python lib in main
basisunus Mar 12, 2026
b373624
startup crash
basisunus Mar 12, 2026
cc83885
Merge branch 'master' into refactor
basisunus Mar 16, 2026
4b589cf
lodepng on mac
basisunus Mar 17, 2026
a4741ce
added default qt path for easy testing on current macbook
basisunus Mar 17, 2026
b69f06a
boost on mac
basisunus Mar 17, 2026
d483a85
boost update
basisunus Mar 17, 2026
cfc1ba2
freetype include path on macos
basisunus Mar 18, 2026
d248c56
freetype path was still incorrect on macos
basisunus Mar 18, 2026
ca24387
lodepng path incorrect on macos similar to freetype
basisunus Mar 18, 2026
8c9258d
lodepng lib not set correctly for mac
basisunus Mar 18, 2026
3b7de4b
python verification incorrect for mac
basisunus Mar 18, 2026
5e5df62
python lib path still incorrect
basisunus Mar 18, 2026
3f5dd25
bin dir for python not found
basisunus Mar 18, 2026
837022b
tetgen lib not found
basisunus Mar 18, 2026
4668d22
lodepng and glew not defined for mac
basisunus Mar 18, 2026
497086b
glew not built on mac
basisunus Mar 20, 2026
4d399f8
glew copy failed on mac
basisunus Mar 20, 2026
a52aff2
glew dependency order
basisunus Mar 20, 2026
a2a867e
glew win and mac settings difference
basisunus Mar 20, 2026
e2f9f61
case mismatch of glew file name on mac
basisunus Mar 20, 2026
8b76fff
still not right case
basisunus Mar 20, 2026
5a7e702
glew install cross platform
basisunus Mar 20, 2026
fe61d7a
find_package for glew in scirun cmake
basisunus Mar 20, 2026
accab9d
lode png not configed correctly for mac
basisunus Mar 20, 2026
6c30d81
boost include dir
basisunus Mar 20, 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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,4 @@ cmake

# Sphinx builds
docs/_build/
/build
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[submodule "src/Externals/submodules/googletest"]
path = src/Externals/submodules/googletest
url = https://github.com/CIBC-Internal/googletest.git
url = https://github.com/google/googletest.git
305 changes: 214 additions & 91 deletions Superbuild/BoostExternal.cmake
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# For more information, please see: http://software.sci.utah.edu
# For more information, please see: http://software.sci.utah.edu
#
# The MIT License
#
Expand All @@ -24,103 +24,226 @@
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.

# Borrowed CMake code from the MaidSafe Boost CMake build
# found at https://github.com/maidsafe/MaidSafe/blob/master/cmake_modules/add_boost.cmake
# and code borrowed from ITK4 HDFMacros.cmake

SET_PROPERTY(DIRECTORY PROPERTY "EP_BASE" ${ep_base})

# disable auto linking
# also set in Seg3D?
SET(boost_CXX_Flags "-DBOOST_ALL_NO_LIB=1")
IF(APPLE)
LIST(APPEND boost_CXX_Flag "-DBOOST_LCAST_NO_WCHAR_T" "-DBOOST_THREAD_DONT_USE_ATOMIC")
ENDIF()
IF(WIN32)
LIST(APPEND boost_CXX_Flag "-DBOOST_BIND_ENABLE_STDCALL")
ENDIF()

SET( boost_DEPENDENCIES )

# explicitly set library list
SET(boost_Libraries
"atomic"
"chrono"
"date_time"
"exception"
"filesystem"
"program_options"
"regex"
"serialization"
#"system"
"thread"
CACHE INTERNAL "Boost library name.")

IF(BUILD_WITH_PYTHON)
ADD_DEFINITIONS(-DBOOST_PYTHON_STATIC_LIB=1)
LIST(APPEND boost_Libraries python)
LIST(APPEND boost_DEPENDENCIES Python_external)
LIST(APPEND boost_CXX_Flag "-DBOOST_PYTHON_STATIC_MODULE" "-DBOOST_PYTHON_STATIC_LIB")
ENDIF()

# for travis clang builds--need a narrower test
IF(UNIX)
ADD_DEFINITIONS(-DBOOST_NO_CXX11_ALLOCATOR)
ENDIF()

SET(boost_GIT_TAG "origin/v1.89.0a")

# TODO: set up 64-bit build detection
# Boost Jam needs to have 64-bit build explicitly configured
IF(WIN32)
SET(FORCE_64BIT_BUILD ON)
ENDIF()


SET(boost_GIT_URL "https://github.com/CIBC-Internal/boost.git")

# TODO: fix install step
#
# If CMake ever allows overriding the checkout command or adding flags,
# git checkout -q will silence message about detached head (harmless).
# --- Inputs ---
set(_boost_git_url "https://github.com/CIBC-Internal/boost.git")
set(_boost_git_tag "v1.90.0")

include(ExternalProject)

# ========= Compiled library selection =========
set(_BOOST_LIBS
filesystem
system
atomic
thread
program_options
serialization
)

option(BOOST_ENABLE_PYTHON "Build Boost.Python if Python is available" ON)
option(BOOST_ENABLE_MPI "Build Boost.MPI if MPI is available" OFF)
option(BOOST_ENABLE_TEST "Build Boost.Test (unit test framework)" OFF)

if(BOOST_ENABLE_PYTHON)
list(APPEND _BOOST_LIBS python)
endif()
if(BOOST_ENABLE_MPI)
list(APPEND _BOOST_LIBS mpi graph_parallel)
endif()
if(BOOST_ENABLE_TEST)
list(APPEND _BOOST_LIBS test)
endif()

set(_BOOST_LIBS_B2 "")
foreach(_bl IN LISTS _BOOST_LIBS)
list(APPEND _BOOST_LIBS_B2 "--with-${_bl}")
endforeach()

# ============================================================
# 1) Define the external project FIRST (required by CMake)
# ============================================================
ExternalProject_Add(Boost_external
DEPENDS ${boost_DEPENDENCIES}
GIT_REPOSITORY ${boost_GIT_URL}
GIT_TAG ${boost_GIT_TAG}
BUILD_IN_SOURCE ON
PATCH_COMMAND ""
INSTALL_COMMAND ""
CMAKE_CACHE_ARGS
-DCMAKE_VERBOSE_MAKEFILE:BOOL=${CMAKE_VERBOSE_MAKEFILE}
-DCMAKE_POSITION_INDEPENDENT_CODE:BOOL=ON
-DBUILD_PYTHON:BOOL=${BUILD_WITH_PYTHON}
-DPython_DIR:PATH=${Python_DIR}
-DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
-DFORCE_64BIT_BUILD:BOOL=${FORCE_64BIT_BUILD}
-DSCI_BOOST_LIBRARIES:STATIC=${boost_Libraries}
-DSCI_BOOST_CXX_FLAGS:STRING=${boost_CXX_Flags}
GIT_REPOSITORY ${_boost_git_url}
GIT_TAG ${_boost_git_tag}
GIT_SHALLOW FALSE
GIT_PROGRESS TRUE

UPDATE_COMMAND ${CMAKE_COMMAND} -E chdir <SOURCE_DIR> git submodule update --init --recursive

BUILD_IN_SOURCE OFF

CONFIGURE_COMMAND ""
BUILD_COMMAND ""
INSTALL_COMMAND ""
)

ExternalProject_Get_Property(Boost_external INSTALL_DIR)
# ============================================================
# 2) Retrieve SOURCE_DIR, BINARY_DIR, INSTALL_DIR
# ============================================================
ExternalProject_Get_Property(Boost_external SOURCE_DIR)
SET(SCI_BOOST_INCLUDE ${SOURCE_DIR})
SET(SCI_BOOST_LIBRARY_DIR ${SOURCE_DIR}/lib)
SET(SCI_BOOST_USE_FILE ${INSTALL_DIR}/UseBoost.cmake)
ExternalProject_Get_Property(Boost_external BINARY_DIR)
ExternalProject_Get_Property(Boost_external INSTALL_DIR)

SET(BOOST_PREFIX "boost_")
SET(THREAD_POSTFIX "-mt")
# ============================================================
# 3) Optional Boost.Python config
# ============================================================
set(_B2_PY_ARGS "")
if(BOOST_ENABLE_PYTHON)
set(_PY_LIBDIR "")

if(DEFINED PYTHON_LIBRARY_DEBUG AND EXISTS "${PYTHON_LIBRARY_DEBUG}")
get_filename_component(_PY_LIBDIR "${PYTHON_LIBRARY_DEBUG}" DIRECTORY)
elseif(DEFINED PYTHON_LIBRARY_RELEASE AND EXISTS "${PYTHON_LIBRARY_RELEASE}")
get_filename_component(_PY_LIBDIR "${PYTHON_LIBRARY_RELEASE}" DIRECTORY)
elseif(DEFINED PYTHON_RUNTIME_DIR AND EXISTS "${PYTHON_RUNTIME_DIR}")
set(_PY_LIBDIR "${PYTHON_RUNTIME_DIR}")
endif()

if(PYTHON_INCLUDE_DIR AND EXISTS "${PYTHON_INCLUDE_DIR}" AND
_PY_LIBDIR AND EXISTS "${_PY_LIBDIR}")
list(APPEND _B2_PY_ARGS
"include=${PYTHON_INCLUDE_DIR}"
"library-path=${_PY_LIBDIR}"
)
message(STATUS "[Boost_ext] Will build Boost.Python against include='${PYTHON_INCLUDE_DIR}', libdir='${_PY_LIBDIR}'")
else()
message(WARNING "[Boost_ext] BOOST_ENABLE_PYTHON=ON but Python paths incomplete.")
endif()
endif()

# ============================================================
# 4) Cross‑platform Boost toolset detection
# ============================================================
if(WIN32)
set(_B2_TOOLSET "msvc")
elseif(APPLE)
set(_B2_TOOLSET "clang-darwin")
else()
if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
set(_B2_TOOLSET "gcc")
elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
set(_B2_TOOLSET "clang")
else()
message(FATAL_ERROR "Unsupported compiler '${CMAKE_CXX_COMPILER_ID}' for Boost build")
endif()
endif()

message(STATUS "[Boost_ext] Auto-selected b2 toolset: ${_B2_TOOLSET}")

if(DEFINED B2_TOOLSET)
message(STATUS "[Boost_ext] Overriding toolset with B2_TOOLSET=${B2_TOOLSET}")
set(_B2_TOOLSET "${B2_TOOLSET}")
endif()

# ============================================================
# 5) Link options
# ============================================================
if(BOOST_USE_STATIC_LIBS)
set(_B2_LINK "link=static")
else()
set(_B2_LINK "link=shared")
endif()

if(BOOST_USE_STATIC_RUNTIME)
set(_B2_RUNTIME_LINK "runtime-link=static")
else()
set(_B2_RUNTIME_LINK "runtime-link=shared")
endif()

set(_B2_VARIANTS "variant=debug,release")

# ============================================================
# 6) b2 executable and build dir
# ============================================================
if(WIN32)
set(_B2_BOOTSTRAP_CMD cmd /c bootstrap.bat)
set(_B2_CMD cmd /c .\\b2)
else()
set(_B2_BOOTSTRAP_CMD ./bootstrap.sh)
set(_B2_CMD ./b2)
endif()

set(_B2_BUILD_DIR ${BINARY_DIR}/b2-build)

# ============================================================
# 7) bootstrap b2
# ============================================================
ExternalProject_Add_Step(Boost_external bootstrap_b2
COMMAND ${_B2_BOOTSTRAP_CMD}
WORKING_DIRECTORY ${SOURCE_DIR}
DEPENDEES update
COMMENT "Bootstrapping b2"
)

# ============================================================
# 8) Run b2 headers
# ============================================================
ExternalProject_Add_Step(Boost_external stage_headers
COMMAND ${_B2_CMD} headers
WORKING_DIRECTORY ${SOURCE_DIR}
DEPENDEES bootstrap_b2
COMMENT "Generating Boost headers (b2 headers)"
)

# ============================================================
# 9) Build Boost libraries
# ============================================================
ExternalProject_Add_Step(Boost_external build_b2_libs
COMMAND ${_B2_CMD}
-j${CMAKE_BUILD_PARALLEL_LEVEL}
toolset=${_B2_TOOLSET}
threading=multi
${_B2_LINK}
${_B2_RUNTIME_LINK}
${_B2_VARIANTS}
--layout=tagged
${_BOOST_LIBS_B2}
${_B2_PY_ARGS}
--build-dir=${_B2_BUILD_DIR}
stage
WORKING_DIRECTORY ${SOURCE_DIR}
DEPENDEES stage_headers
COMMENT "Building Boost libs"
)

# ============================================================
# 10) Install b2-built libs
# ============================================================
ExternalProject_Add_Step(Boost_external install_b2_libs
COMMAND ${CMAKE_COMMAND} -E make_directory <INSTALL_DIR>/lib
COMMAND ${CMAKE_COMMAND} -E copy_directory ${SOURCE_DIR}/stage/lib <INSTALL_DIR>/lib
DEPENDEES build_b2_libs
COMMENT "Installing Boost libs"
)

# ============================================================
# 11) Install full header tree
# ============================================================
ExternalProject_Add_Step(Boost_external install_full_headers
COMMAND ${CMAKE_COMMAND} -E make_directory <INSTALL_DIR>/include
COMMAND ${CMAKE_COMMAND} -E remove_directory <INSTALL_DIR>/include/boost
COMMAND ${CMAKE_COMMAND} -E copy_directory ${SOURCE_DIR}/boost <INSTALL_DIR>/include/boost
DEPENDEES stage_headers
COMMENT "Installing Boost headers"
)

SET(SCI_BOOST_LIBRARY)
# ============================================================
# 12) Export paths to superbuild
# ============================================================
set(SCI_BOOST_PREFIX "${INSTALL_DIR}")

FOREACH(lib ${boost_Libraries})
SET(LIB_NAME "${BOOST_PREFIX}${lib}${THREAD_POSTFIX}")
LIST(APPEND SCI_BOOST_LIBRARY ${LIB_NAME})
ENDFOREACH()
set(SCI_BOOST_INCLUDE "${SCI_BOOST_PREFIX}/include" CACHE PATH "Boost include dir" FORCE)

# Boost is special case - normally this should be handled in external library repo
CONFIGURE_FILE(${SUPERBUILD_DIR}/BoostConfig.cmake.in ${INSTALL_DIR}/BoostConfig.cmake @ONLY)
CONFIGURE_FILE(${SUPERBUILD_DIR}/UseBoost.cmake ${SCI_BOOST_USE_FILE} COPYONLY)
if(EXISTS "${SCI_BOOST_PREFIX}/lib64")
set(SCI_BOOST_LIBRARY_DIR "${SCI_BOOST_PREFIX}/lib64")
else()
set(SCI_BOOST_LIBRARY_DIR "${SCI_BOOST_PREFIX}/lib")
endif()

SET(Boost_DIR ${INSTALL_DIR} CACHE PATH "")
set(SCI_BOOST_LIBRARY_DIR "${SCI_BOOST_LIBRARY_DIR}" CACHE PATH "Boost library dir" FORCE)

MESSAGE(STATUS "Boost_DIR: ${Boost_DIR}")
set(Boost_DIR "" CACHE PATH "" FORCE)
set(Boost_NO_BOOST_CMAKE ON CACHE BOOL "" FORCE)
set(Boost_ROOT "${SCI_BOOST_PREFIX}" CACHE PATH "" FORCE)
set(BOOST_ROOT "${SCI_BOOST_PREFIX}" CACHE PATH "" FORCE)
set(BOOST_LIBRARYDIR "${SCI_BOOST_LIBRARY_DIR}" CACHE PATH "" FORCE)
Loading
Loading