diff --git a/CMakeLists.txt b/CMakeLists.txt index 900673e..0b8bd36 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -124,7 +124,7 @@ OPTION(MT_BUILD_VISUAL_TOOLS "Build visual tools (Display, Register, postf, ray_ OPTION(USE_SYSTEM_ITK "Use System ITK" OFF) OPTION(MT_USE_OPENMP "Use OpenMP multi-threading" OFF) OPTION(MT_BUILD_IM "Build ImageMagick and dependent libraries" OFF) -OPTION(MT_BUILD_OPENBLAS "Build OpenBLAS: will require fortran" OFF) +OPTION(MT_BUILD_OPENBLAS "Build OpenBLAS: will require fortran" ON) #OPTION(MT_USE_OPENMP_BLAS "Use Build OpenBLAS with OpenMP support" OFF) # TODO: finish this to compile on some platforms SET(MT_PACKAGES_PATH "${CMAKE_BINARY_DIR}/cache" CACHE PATH "Directory containing 3rd party packages") @@ -156,7 +156,7 @@ SET(SUPERBUILD_STAGING_PREFIX ${CMAKE_BINARY_DIR}/external) file(MAKE_DIRECTORY ${SUPERBUILD_STAGING_PREFIX}/${CMAKE_INSTALL_PREFIX}/share) SET(MINC_TEST_ENVIRONMENT - "PATH=${CMAKE_CURRENT_BINARY_DIR}:${CMAKE_CURRENT_BINARY_DIR}/N3:${CMAKE_CURRENT_BINARY_DIR}/classify:${CMAKE_CURRENT_BINARY_DIR}/minctools/progs:${CMAKE_CURRENT_BINARY_DIR}/mni_autoreg/mincblur:${CMAKE_CURRENT_BINARY_DIR}/mni_autoreg/make_phantom:${CMAKE_CURRENT_BINARY_DIR}/mni_autoreg/minctracc:${SUPERBUILD_STAGING_PREFIX}/${CMAKE_INSTALL_PREFIX}/bin:$ENV{PATH}" + "PATH=${CMAKE_CURRENT_BINARY_DIR}:${CMAKE_CURRENT_BINARY_DIR}/N3:${CMAKE_CURRENT_BINARY_DIR}/classify:${CMAKE_CURRENT_BINARY_DIR}/minctools/progs:${CMAKE_CURRENT_BINARY_DIR}/mni_autoreg/mincblur:${CMAKE_CURRENT_BINARY_DIR}/mni_autoreg/make_phantom:${CMAKE_CURRENT_BINARY_DIR}/mni_autoreg/minctracc:${SUPERBUILD_STAGING_PREFIX}/${CMAKE_INSTALL_PREFIX}/bin:$ENV{PATH}" ) LIST(APPEND MINC_TEST_ENVIRONMENT "PERL5LIB=${CMAKE_SOURCE_DIR}/mni-perllib:${CMAKE_CURRENT_BINARY_DIR}/mni-perllib/perl:${CMAKE_CURRENT_BINARY_DIR}/perl-modules:$ENV{PERL5LIB}") @@ -501,7 +501,7 @@ IF(MT_BUILD_ITK_TOOLS) build_C3D(${CMAKE_INSTALL_PREFIX} ${SUPERBUILD_STAGING_PREFIX} ${ITK_DIR}) ADD_DEPENDENCIES(C3D ITKv4 minc2) ENDIF(MT_BUILD_C3D) - + IF(MT_BUILD_ELASTIX) INCLUDE(BuildElastix) build_Elastix(${CMAKE_INSTALL_PREFIX} ${SUPERBUILD_STAGING_PREFIX} ${ITK_DIR}) @@ -511,21 +511,21 @@ IF(MT_BUILD_ITK_TOOLS) INCLUDE(BuildEZMINC) build_EZMINC(${CMAKE_INSTALL_PREFIX} ${SUPERBUILD_STAGING_PREFIX} ${CMAKE_BINARY_DIR}/libminc ${CMAKE_BINARY_DIR}/bicpl ${ITK_DIR}) ADD_DEPENDENCIES(EZMINC ITKv4 GSL minc2 minc_io bicpl) - + INCLUDE(BuildPatchMorphology) build_PatchMorphology(${CMAKE_INSTALL_PREFIX} ${SUPERBUILD_STAGING_PREFIX} ${ITK_DIR}) ADD_DEPENDENCIES(patch_morphology ITKv4 minc_io) - + IF(MT_BUILD_OPENBLAS) ADD_DEPENDENCIES(patch_morphology OpenBLAS) ENDIF(MT_BUILD_OPENBLAS) - + IF(MT_BUILD_ABC) INCLUDE(BuildABC) build_ABC(${CMAKE_INSTALL_PREFIX} ${SUPERBUILD_STAGING_PREFIX} ${ITK_DIR}) ADD_DEPENDENCIES(ABC ITKv4 minc2) ENDIF(MT_BUILD_ABC) - + ENDIF(MT_BUILD_ITK_TOOLS) # tools requiring OpenBLAS @@ -544,9 +544,9 @@ ENDIF() IF(MT_BUILD_VISUAL_TOOLS) FIND_PACKAGE( OpenGL REQUIRED ) FIND_PACKAGE( X11 QUIET ) - + IF(USE_SYSTEM_GLUT) - FIND_PACKAGE( GLUT REQUIRED ) + FIND_PACKAGE( GLUT REQUIRED ) ELSE(USE_SYSTEM_GLUT) INCLUDE(BuildFREEGLUT) # newer version of build_freeglut seem to be causing problems build_freeglut( ${CMAKE_INSTALL_PREFIX} ${SUPERBUILD_STAGING_PREFIX}) @@ -590,7 +590,7 @@ IF(MT_BUILD_IM) INCLUDE(BuildPNG) INCLUDE(BuildFREETYPE) INCLUDE(BuildIM) - + build_jpeg(${CMAKE_INSTALL_PREFIX} ${SUPERBUILD_STAGING_PREFIX}) build_png(${CMAKE_INSTALL_PREFIX} ${SUPERBUILD_STAGING_PREFIX} ${ZLIB_INCLUDE_DIR} ${ZLIB_LIBRARY} ${ZLIB_DIR} ) build_freetype(${CMAKE_INSTALL_PREFIX} ${SUPERBUILD_STAGING_PREFIX} ${ZLIB_INCLUDE_DIR} ${ZLIB_LIBRARY} ${ZLIB_DIR}) diff --git a/cmake-modules/BuildFREEGLUT.cmake b/cmake-modules/BuildFREEGLUT.cmake index 430cc1f..0577449 100644 --- a/cmake-modules/BuildFREEGLUT.cmake +++ b/cmake-modules/BuildFREEGLUT.cmake @@ -51,7 +51,7 @@ macro(build_freeglut install_prefix staging_prefix) ) endif() -GET_PACKAGE("http://downloads.sourceforge.net/project/freeglut/freeglut/3.2.1/freeglut-3.2.1.tar.gz" "cd5c670c1086358598a6d4a9d166949d" "freeglut-3.2.1.tar.gz" FREEGLUT_PATH ) +GET_PACKAGE("https://github.com/FreeGLUTProject/freeglut/releases/download/v3.2.2/freeglut-3.2.2.tar.gz" "485c1976165315fc42c0b0a1802816d9" "freeglut-3.2.2.tar.gz" FREEGLUT_PATH ) # have to find GL X11 Xrandr Xi FIND_PACKAGE(OpenGL REQUIRED) @@ -59,7 +59,7 @@ FIND_PACKAGE(X11 REQUIRED) ExternalProject_Add(FREEGLUT URL "${FREEGLUT_PATH}" - URL_MD5 "cd5c670c1086358598a6d4a9d166949d" + URL_MD5 "485c1976165315fc42c0b0a1802816d9" SOURCE_DIR FREEGLUT BINARY_DIR FREEGLUT-build LIST_SEPARATOR ::: diff --git a/cmake-modules/BuildOpenBLAS.cmake b/cmake-modules/BuildOpenBLAS.cmake index 5e82918..67e9966 100644 --- a/cmake-modules/BuildOpenBLAS.cmake +++ b/cmake-modules/BuildOpenBLAS.cmake @@ -93,7 +93,7 @@ macro(build_open_blas install_prefix staging_prefix build_parallel) INSTALL_DIR ${staging_prefix}/${install_prefix} ) - SET(OpenBLAS_INCLUDE_DIRS ${staging_prefix}/${install_prefix}/include ) + SET(OpenBLAS_INCLUDE_DIRS ${staging_prefix}/${install_prefix}/include/openblas ) SET(OpenBLAS_LIBRARIES ${staging_prefix}/${install_prefix}/lib${LIB_SUFFIX}/libopenblas.so ) SET(OpenBLAS_LIBRARY ${OpenBLAS_LIBRARIES}) SET(OpenBLAS_DIR ${staging_prefix}/${install_prefix}/share/cmake/OpenBLAS ) diff --git a/cmake-modules/BuildPatchMorphology.cmake b/cmake-modules/BuildPatchMorphology.cmake index 31630ef..d538f9a 100644 --- a/cmake-modules/BuildPatchMorphology.cmake +++ b/cmake-modules/BuildPatchMorphology.cmake @@ -40,7 +40,8 @@ macro(build_PatchMorphology install_prefix staging_prefix itk_dir) -DCMAKE_STATIC_LINKER_FLAGS_RELEASE:STRING=${CMAKE_STATIC_LINKER_FLAGS_RELEASE} -DCMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO:STRING=${CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO} -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} - -DOpenBLAS_INCLUDE_DIR:PATH=${OpenBLAS_INCLUDE_DIRS} + -DOpenBLAS_INCLUDE_DIRS:PATH=${OpenBLAS_INCLUDE_DIRS} + -DOpenBLAS_LIBRARIES:PATH=${OpenBLAS_LIBRARIES} -DOpenBLAS_LIBRARY:PATH=${OpenBLAS_LIBRARY} -DCMAKE_DISABLE_FIND_PACKAGE_OpenBLAS:BOOL=ON -DOpenBLAS_DIR:PATH=${OpenBLAS_DIR} diff --git a/mni_autoreg b/mni_autoreg index 83cbe40..be7bd25 160000 --- a/mni_autoreg +++ b/mni_autoreg @@ -1 +1 @@ -Subproject commit 83cbe4097acd4b5d3567ffea9e07d4c0055d3dde +Subproject commit be7bd25bf7776974e0f2c1d90b6e7f8ccc0c8874