...
 
Commits (723)
*.patch whitespace=-blank-at-eol,-space-before-tab -text *.patch whitespace=-blank-at-eol,-space-before-tab,-blank-at-eof -text -crlf
cmake_minimum_required(VERSION 2.8.11) cmake_minimum_required(VERSION 3.11.2)
if (POLICY CMP0025)
# Clang and AppleClang are now unique compiler ids
cmake_policy(SET CMP0025 NEW)
endif ()
project(cmb-superbuild) project(cmb-superbuild)
list(INSERT CMAKE_MODULE_PATH 0
"${CMAKE_CURRENT_LIST_DIR}/cmake")
macro (superbuild_setup_variables) macro (superbuild_setup_variables)
include(SuperbuildVersionMacros) include(SuperbuildVersionMacros)
superbuild_set_version_variables(cmb "4.0.0" "cmb-version.cmake")
if (cmb_SOURCE_SELECTION STREQUAL "git")
# Assuming master; just use the latest version, but let the user set their
# own version in case it is actually a branch from some other version.
set(CMB_VERSION_DEFAULT "<FETCH_FROM_GIT>"
CACHE STRING "The default version of CMB to use if it cannot be detected")
if (CMB_VERSION_DEFAULT STREQUAL "<FETCH_FROM_GIT>")
include(cmbVersion)
set(CMB_VERSION_DEFAULT "${cmb_version_major}.${cmb_version_minor}.${cmb_version_patch}")
endif ()
mark_as_advanced(CMB_VERSION_DEFAULT)
set(cmb_default_version "${CMB_VERSION_DEFAULT}")
elseif (cmb_SOURCE_SELECTION STREQUAL "source")
# If it is a git repo, we'll get it that way. Otherwise, we will look at the
# `version.txt` in the checkout.
set(cmb_default_version "")
else ()
# The selection is the version number; use it.
set(cmb_default_version "${cmb_SOURCE_SELECTION}")
endif()
superbuild_set_version_variables(cmb "${cmb_default_version}" "cmb-version.cmake" "version.txt")
set(cmb_version "${cmb_version_major}.${cmb_version_minor}") set(cmb_version "${cmb_version_major}.${cmb_version_minor}")
superbuild_set_version_variables(paraview "5.1.2" "paraview-version.cmake")
if (smtk_SOURCE_SELECTION STREQUAL "git")
# Assuming master; just use the latest version, but let the user set their
# own version in case it is actually a branch from some other version.
set(SMTK_VERSION_DEFAULT "<FETCH_FROM_GIT>"
CACHE STRING "The default version of SMTK to use if it cannot be detected")
if (SMTK_VERSION_DEFAULT STREQUAL "<FETCH_FROM_GIT>")
include(smtkVersion)
set(SMTK_VERSION_DEFAULT "${smtk_version_major}.${smtk_version_minor}.${smtk_version_patch}")
endif ()
mark_as_advanced(SMTK_VERSION_DEFAULT)
set(smtk_default_version "${SMTK_VERSION_DEFAULT}")
elseif (smtk_SOURCE_SELECTION STREQUAL "source")
# If it is a git repo, we'll get it that way. Otherwise, we will look at the
# `version.txt` in the checkout.
set(smtk_default_version "")
else ()
# The selection is the version number; use it.
set(smtk_default_version "${smtk_SOURCE_SELECTION}")
endif()
superbuild_set_version_variables(smtk "${smtk_default_version}" "smtk-version.cmake" "version.txt")
set(smtk_version "${smtk_version_major}.${smtk_version_minor}")
superbuild_set_version_variables(paraview "5.6.0" "paraview-version.cmake" "version.txt")
set(paraview_version "${paraview_version_major}.${paraview_version_minor}") set(paraview_version "${paraview_version_major}.${paraview_version_minor}")
superbuild_set_version_variables(vtk "8.1.0" "vtk-version.cmake")
set(vtk_version "${vtk_version_major}.${vtk_version_minor}")
endmacro () endmacro ()
function (superbuild_find_projects var) function (superbuild_find_projects var)
include(CMBSuperbuildMacros)
set(projects set(projects
boost boost
bzip2 bzip2
cgm
cmb cmb
cmbusersguide
cmbworkflows cmbworkflows
cumulus
cxx11 cxx11
eigen
fortran
freetype freetype
ftgl ftgl
gdal gdal
hdf5 hdf5
kml lapack
matplotlib
moab moab
netcdf netcdf
nlohmannjson
numpy numpy
oce
opencv opencv
opencvcontrib
paraview paraview
paraviewweb
paraviewwebvisualizer
paraviewweblightviz
pegtl
png png
protobuf
pyarc
pybind11
python python
pythondiskcache
pythongirderclient pythongirderclient
pythonrequests pythonrequests
pythonrequeststoolbelt
pythonsetuptools pythonsetuptools
pythonsix qt
qt4 qt4
qt5
remus remus
shiboken rggsession
smtk smtk
smtkusersguide
szip szip
vtk
vtkonly
vxl vxl
zeromq zeromq
zlib) zlib)
...@@ -53,28 +114,55 @@ function (superbuild_find_projects var) ...@@ -53,28 +114,55 @@ function (superbuild_find_projects var)
if (NOT WIN32) if (NOT WIN32)
list(APPEND projects list(APPEND projects
fontconfig fontconfig
libxml2) gperf
libxml2
meshkit)
endif () endif ()
if (WIN32) if (WIN32)
list(APPEND projects list(APPEND projects
ftjam ftjam
pythonsetuptools) pythonsetuptools
pywin32)
endif ()
if (NOT DEVELOPER_MODE_smtk)
list(APPEND projects
smtkprojectmanager
smtkresourcemanagerstate)
endif () endif ()
# For now it's a convenient option to control smtk documentation
option(ENABLE_DOCUMENTATION "Enable smtk documentation" ON)
option(USE_NONFREE_COMPONENTS "Enable the non-free parts of the superbuild" OFF) option(USE_NONFREE_COMPONENTS "Enable the non-free parts of the superbuild" OFF)
mark_as_advanced(USE_NONFREE_COMPONENTS) mark_as_advanced(USE_NONFREE_COMPONENTS)
if (USE_NONFREE_COMPONENTS) if (USE_NONFREE_COMPONENTS)
list(APPEND projects list(APPEND projects
capstone
cubit
triangle) triangle)
endif () endif ()
# Capstone and Cubit are closed-source programs to which Kitware developers
# have access. We provide logic for situating these programs into our
# superbuild for development purposes only. These packages are not bundled or
# distributed.
set(KW_SHARE "" CACHE PATH "Location of Kitware-internal share directory.")
if (NOT (capstone_enabled OR cubit_enabled))
mark_as_advanced(KW_SHARE)
endif ()
set("${var}" set("${var}"
${projects} ${projects}
PARENT_SCOPE) PARENT_SCOPE)
endfunction () endfunction ()
function (superbuild_sanity_check) function (superbuild_sanity_check)
if (vtkonly_enabled AND paraview_enabled)
message(FATAL_ERROR
"Only one of the following projects should be enabled: vtkonly, paraview.")
endif ()
if (NOT smtk_enabled AND NOT cmb_enabled) if (NOT smtk_enabled AND NOT cmb_enabled)
message(FATAL_ERROR message(FATAL_ERROR
"At least one of the following projects must be enabled: cmb, smtk.") "At least one of the following projects must be enabled: cmb, smtk.")
...@@ -97,18 +185,38 @@ function (superbuild_add_packaging) ...@@ -97,18 +185,38 @@ function (superbuild_add_packaging)
TGZ) TGZ)
endif () endif ()
if (USE_SYSTEM_qt4) if (qt5_built_by_superbuild)
set(Qt5_DIR "${superbuild_install_location}/lib/cmake/Qt5")
endif ()
if (USE_SYSTEM_qt5)
list(APPEND superbuild_export_variables list(APPEND superbuild_export_variables
QT_LIBRARY_DIR) Qt5_DIR)
find_package(Qt5 QUIET REQUIRED COMPONENTS Core)
set(qt5_version "${Qt5Core_VERSION_MAJOR}.${Qt5Core_VERSION_MINOR}")
else ()
set(qt5_version "${qt5_SOURCE_SELECTION}")
endif ()
list(APPEND superbuild_export_variables
qt5_version)
list(APPEND superbuild_export_variables
BOOST_ADDITIONAL_LIBRARIES)
include(cmb.suffix)
list(APPEND superbuild_export_variables
CMB_PACKAGE_SUFFIX)
if (cmb_enabled)
set(CMB_PACKAGE_FILE_NAME ""
CACHE STRING "If set, overrides the generated filename for the package")
list(APPEND superbuild_export_variables
CMB_PACKAGE_FILE_NAME)
endif () endif ()
foreach (generator IN LISTS generators) foreach (generator IN LISTS generators)
superbuild_add_extra_package_test(modelbuilder "${generator}" superbuild_add_extra_package_test(modelbuilder "${generator}"
LABELS "CMB" LABELS "CMB"
TIMEOUT 1200) TIMEOUT 6400)
superbuild_add_extra_package_test(hydrology "${generator}"
LABELS "CMB"
TIMEOUT 1200)
endforeach () endforeach ()
endfunction () endfunction ()
...@@ -126,13 +234,39 @@ function (superbuild_add_tests) ...@@ -126,13 +234,39 @@ function (superbuild_add_tests)
superbuild_test_projects cmb smtk) superbuild_test_projects cmb smtk)
endfunction () endfunction ()
set(CMB_TEST_DATA_ROOT "" CACHE PATH "Location of CMB's testing data")
# Default Qt5 to ON.
set(_superbuild_default_qt5 ON)
set(qt5_skip_modules
qtconnectivity
qtgamepad
qtlocation
qtmultimedia
qtsensors
qtserialport
qtwayland
qtwebchannel
qtwebengine
qtwebsockets)
set(BOOST_ADDITIONAL_LIBRARIES "" CACHE STRING "Additional boost libraries to build and package")
mark_as_advanced(BOOST_ADDITIONAL_LIBRARIES)
set(boost_minimum_version 1.64.0)
set(boost_libraries set(boost_libraries
atomic atomic
chrono chrono
date_time date_time
filesystem filesystem
log
regex
serialization
system system
thread) thread
timer
${BOOST_ADDITIONAL_LIBRARIES})
configure_file( configure_file(
"${CMAKE_CURRENT_LIST_DIR}/cmake/CTestCustom.cmake.in" "${CMAKE_CURRENT_LIST_DIR}/cmake/CTestCustom.cmake.in"
...@@ -143,9 +277,27 @@ if (__BUILDBOT_INSTALL_LOCATION) ...@@ -143,9 +277,27 @@ if (__BUILDBOT_INSTALL_LOCATION)
set(superbuild_install_location "${__BUILDBOT_INSTALL_LOCATION}") set(superbuild_install_location "${__BUILDBOT_INSTALL_LOCATION}")
endif () endif ()
set(suppress_projects
boost
freetype
ftgl
gdal
hdf5
netcdf
numpy
png
pybind11
szip
vxl
zeromq
zlib)
foreach (suppress_project IN LISTS suppress_projects)
set("_superbuild_suppress_${suppress_project}_output" ON)
endforeach ()
list(APPEND superbuild_version_files list(APPEND superbuild_version_files
"${CMAKE_CURRENT_LIST_DIR}/versions.cmake") "${CMAKE_CURRENT_LIST_DIR}/versions.cmake")
list(APPEND extra_ctest_custom_files list(APPEND superbuild_ctest_custom_files
"${CMAKE_CURRENT_BINARY_DIR}/CTestCustom-cmb.cmake") "${CMAKE_CURRENT_BINARY_DIR}/CTestCustom-cmb.cmake")
list(APPEND superbuild_project_roots list(APPEND superbuild_project_roots
"${CMAKE_CURRENT_LIST_DIR}/projects") "${CMAKE_CURRENT_LIST_DIR}/projects")
......
...@@ -2,54 +2,86 @@ ...@@ -2,54 +2,86 @@
# CMB SuperBuild # CMB SuperBuild
Though CMB is relatively simple to build itself, it does depend on a several libraries including Qt, ParaView/VTK, MOAB, etc.. To help make the process of building CMB and the libraries it depends on easier we have create a SuperBuild CMake Project. Though CMB is relatively simple to build itself, it does depend on a several
# What You Need To Start libraries including Qt, ParaView/VTK, Boost, MOAB, etc.. To help make the process of
building CMB and the libraries it depends on easier we have created a
SuperBuild CMake Project.
* CMake version 3.5 or greater # Requirements
* ninja or make - note that for Windows build you will need to have ninja installed
* CMake version 3.9 or greater with SSL support (Binaries from `cmake.org`
have this already; custom built CMake binaries need to use
`CMAKE_USE_SYSTEM_CURL=ON`).
* ninja or make - (the Windows build requires ninja)
* Checkout of the [CMB SuperBuild Git Repo](https://gitlab.kitware.com/cmb/cmb-superbuild) * Checkout of the [CMB SuperBuild Git Repo](https://gitlab.kitware.com/cmb/cmb-superbuild)
* Qt Related Info
* Have Qt 5.10 or greater installed on the system and make sure you set `USE_SYSTEM_qt5` on
* In CMake: `QT5_DIR` needs to be set to [Qt installation dir for your compiler]/lib/cmake/Qt5
* C++ Compiler * C++ Compiler
* XCode 7.1 or greater * XCode 9.x or greater
* GCC 4.8 * GCC 4.9 or greater
* Visual Studio 2013 64 bit * Clang 3.4 or greater
* Microsoft Visual C++ 2015 / Build Tools 14.0.25123.0 (and possibly later)
* Ubuntu 16.04 specific
* sudo apt-get install m4
* sudo apt-get install build-essential
* turn on `USE_SYSTEM_qt5` in CMake(Recommend)
* sudo apt-get install qt5-qmake libqt5-dev qt5-dev-tools (if using system qt)
* sudo apt-get install libxt-dev
Note that the build process will also download additional tar balls and checkout additional git repos so you will also need an internet connection. Note that the build process will also download additional tarballs and
checkout additional git repos so you will also need an internet connection.
# Building CMB using the SuperBuild Process # Building CMB using the SuperBuild Process
## Prepping the Git Repo ## Prepping the Git Repo
1. Clone the CMB SuperBuild Repo using git clone https://gitlab.kitware.com/cmb/cmb-superbuild.git 1. Clone the CMB SuperBuild Repo using `git clone https://gitlab.kitware.com/cmb/cmb-superbuild.git`
2. cd into the git repo and do the following commands: 2. Using a shell in the cloned repository check out the latest stable release `git checkout release`
* git submodule init 3. Using a shell in the cloned repository, run `git submodule update --init`
* git submodule update
## Configuring the Build Using CMake ## Configuring the Build Using CMake
There are two possible methods you can use: CMake GUI or the ccmake command line tool There are two possible methods you can use: CMake GUI or the ccmake command line tool
### Using the CMake GUI ### Using the CMake GUI
![](images/CmakeScreenShot.png) ![](images/CmakeScreenShot.png)
1. Select the Source directory that contains the CMake SuperBuild Git Repo 1. Select the Source directory that contains the CMake SuperBuild Git Repo
2. Select the build directory to be used to hold the build. Note that due to a bug in git this should not be under and git repository including the Source Directory. 2. Select the build directory to be used to hold the build. Note that due to
a bug in git this should not be under and git repository including the
Source Directory.
### Using ccmake commandline tool ### Using ccmake commandline tool
1. Make the directory you want to build in
1. Make the directory you want to build in
2. cd into that directory 2. cd into that directory
3. If you are building with ninja (as oppose to make) run ccmake -G Ninja PathToYourSuperBuildRepo, else omit the -G Ninja 3. If you are building with ninja (as oppose to make) run
`ccmake -G Ninja PathToYourSuperBuildRepo`, else omit the `-G Ninja`
### Configuring the CMB SuperBuild ### Configuring the CMB SuperBuild
* By default the build will be in Release Mode (not Debug) - this can be changed using an advance option
* The process will also build Qt 4.8.6 by default. If you already have a Qt installed (4.8.*) then you can do the following: * By default the build will be in Release Mode (not Debug) - this can be
* Turn USE\_SYSTEM\_qt4 on changed using the `CMAKE_BUILD_TYPE_cmb` variable. Similar variables exist
for other projects depending on the setup including `paraview` and `smtk`.
* The process will also build Qt 5.9.1 by default. If you already have a Qt
installed (5.9 or newer) then you can do the following:
* Turn `USE_SYSTEM_qt5` on
* Tell CMake to configure * Tell CMake to configure
* Check to see if the QT\_QMAKE\_EXECUTABLE variable is set to the appropriate qmake - if is not then set it correctly * Check to see if the `Qt5_DIR` variable is set to the appropriate location -
* NOTE! Qt built on Mac OSX 10.9 and greater needs several patches to work properly. These patches are automatically applied when Qt is built using the superbuild and it is the recommended way to build Qt. You will also need to make sure you have a 10.9 SDK on your OSX platform if is not then set it correctly
* tell CMake to configure * On Windows, the directory to the Qt5 libraries must be in the `PATH`
* tell CMake to generate environment variable in order to build.
* Tell CMake to configure
* Tell CMake to generate
## Building the CMB SuperBuild ## Building the CMB SuperBuild
* cd into the build directory * cd into the build directory
* run make or ninja - depending on which build system you previously selected. * run make or ninja - depending on which build system you previously selected.
## Building a CMB Installable Package ## Building a CMB Installable Package
* cd into the build directory * cd into the build directory
* run ctest -R cpack * run ctest -R cpack
\ No newline at end of file
macro (cmb_superbuild_add_pdf name outname)
superbuild_add_project("${name}"
DOWNLOAD_NO_EXTRACT 1
DEFAULT_ON
CONFIGURE_COMMAND
""
BUILD_COMMAND
""
INSTALL_COMMAND
"${CMAKE_COMMAND}" -E copy_if_different
<DOWNLOADED_FILE>
"<INSTALL_DIR>/doc/${outname}")
if (${name}_enabled)
set("${name}_pdf" "${superbuild_install_location}/doc/${outname}")
endif ()
endmacro ()
set_property(GLOBAL
PROPERTY
cmb_superbuild_lfs_steps
lfs-init
lfs-download
lfs-checkout)
macro (cmb_superbuild_add_lfs_steps _name)
superbuild_project_add_step(lfs-init
COMMAND "${GIT_EXECUTABLE}"
lfs
install
--local
DEPENDEES download
DEPENDERS configure
DEPENDS ${ARGN}
COMMENT "Enabling LFS for ${_name}"
WORKING_DIRECTORY <SOURCE_DIR>)
superbuild_project_add_step(lfs-download
COMMAND "${GIT_EXECUTABLE}"
lfs
fetch
DEPENDEES lfs-init
DEPENDERS configure
COMMENT "Downloading LFS data for ${_name}"
WORKING_DIRECTORY <SOURCE_DIR>)
superbuild_project_add_step(lfs-checkout
COMMAND "${GIT_EXECUTABLE}"
lfs
checkout
DEPENDEES lfs-download
DEPENDERS configure
COMMENT "Checking out LFS data for ${_name}"
WORKING_DIRECTORY <SOURCE_DIR>)
endmacro ()
...@@ -10,6 +10,12 @@ set(CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS 1000) ...@@ -10,6 +10,12 @@ set(CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS 1000)
##------------------------------------------------------------------------------ ##------------------------------------------------------------------------------
## Regular expression for warning exception during build process ## Regular expression for warning exception during build process
list(APPEND CTEST_CUSTOM_WARNING_EXCEPTION list(APPEND CTEST_CUSTOM_WARNING_EXCEPTION
# Ignore all warnings.
".*"
"[w|W]arning"
"WARNING"
"CMake Warning"
"-jN forced in submake: disabling jobserver mode" "-jN forced in submake: disabling jobserver mode"
"thirdparty/qt5json" "thirdparty/qt5json"
"/usr/bin/libtool" "/usr/bin/libtool"
...@@ -29,10 +35,6 @@ list(APPEND CTEST_CUSTOM_WARNING_EXCEPTION ...@@ -29,10 +35,6 @@ list(APPEND CTEST_CUSTOM_WARNING_EXCEPTION
"build/.*/doc" "build/.*/doc"
#Shiboken
"CMakeFiles/shiboken.dir"
"libapiextractor.a"
# Boost # Boost
"clang: warning: optimization flag '-finline-functions' is not supported" "clang: warning: optimization flag '-finline-functions' is not supported"
"clang: warning: argument unused during compilation: '-finline-functions'" "clang: warning: argument unused during compilation: '-finline-functions'"
...@@ -77,7 +79,6 @@ list(APPEND CTEST_CUSTOM_WARNING_EXCEPTION ...@@ -77,7 +79,6 @@ list(APPEND CTEST_CUSTOM_WARNING_EXCEPTION
"qmutex.h.* : warning C4512:" "qmutex.h.* : warning C4512:"
"vil3d_dicom.obj : warning LNK4221:" "vil3d_dicom.obj : warning LNK4221:"
"install\\\\include" "install\\\\include"
"shiboken\\\\build"
"smtk\\\\src\\\\smtk\\\\ThirdParty" "smtk\\\\src\\\\smtk\\\\ThirdParty"
"warning C4996: 'strcpy'" "warning C4996: 'strcpy'"
"warning C4996: 'scanf'" "warning C4996: 'scanf'"
...@@ -117,17 +118,15 @@ ignore_project_warnings(boost) ...@@ -117,17 +118,15 @@ ignore_project_warnings(boost)
ignore_project_warnings(gdal) ignore_project_warnings(gdal)
ignore_project_warnings(hdf5) ignore_project_warnings(hdf5)
ignore_project_errors(hdf5) ignore_project_errors(hdf5)
ignore_project_warnings(kml)
ignore_project_warnings(python) ignore_project_warnings(python)
ignore_project_warnings(qt4) ignore_project_warnings(qt5)
ignore_project_warnings(shiboken)
ignore_project_warnings(szip) ignore_project_warnings(szip)
ignore_project_warnings(vxl) ignore_project_warnings(vxl)
ignore_project_warnings(zeromq) ignore_project_warnings(zeromq)
if (WIN32) if (WIN32)
set(ENV{PATH} set(ENV{PATH}
"$ENV{PATH};${CMAKE_CURRENT_LIST_DIR}/install/bin;${CMAKE_CURRENT_LIST_DIR}/install/lib") "$ENV{PATH};${CMAKE_CURRENT_LIST_DIR}/install/bin;${CMAKE_CURRENT_LIST_DIR}/install/lib;${CMAKE_CURRENT_LIST_DIR}/install/x64/vc14/bin")
endif () endif ()
# Regular expression for error exceptions during build process # Regular expression for error exceptions during build process
......
# Download SMTK's master branch version.txt
file(DOWNLOAD https://gitlab.kitware.com/cmb/cmb/raw/master/version.txt
${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/cmbVersion.txt STATUS status)
list(GET status 0 error_code)
if (error_code)
message(FATAL_ERROR "Could not access the version file for CMB")
endif ()
file(STRINGS ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/cmbVersion.txt version_string )
string(REGEX MATCH "([0-9]+)\\.([0-9]+)\\.([0-9]+)[-]*(.*)"
version_matches "${version_string}")
set(cmb_version_major ${CMAKE_MATCH_1})
set(cmb_version_minor ${CMAKE_MATCH_2})
set(cmb_version_patch "${CMAKE_MATCH_3}")
# Do we just have a patch version or are there extra stuff?
if (CMAKE_MATCH_4)
set(cmb_version_patch "${CMAKE_MATCH_3}-${CMAKE_MATCH_4}")
endif()
set(cmb_version "${cmb_version_major}.${cmb_version_minor}")
# Download SMTK's master branch version.txt
file(DOWNLOAD https://gitlab.kitware.com/cmb/smtk/raw/master/version.txt
${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/smtkVersion.txt STATUS status)
list(GET status 0 error_code)
if (error_code)
message(FATAL_ERROR "Could not access the version file for SMTK")
endif ()
file(STRINGS ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/smtkVersion.txt version_string )
string(REGEX MATCH "([0-9]+)\\.([0-9]+)\\.([0-9]+)[-]*(.*)"
version_matches "${version_string}")
set(smtk_version_major ${CMAKE_MATCH_1})
set(smtk_version_minor ${CMAKE_MATCH_2})
set(smtk_version "${smtk_version_major}.${smtk_version_minor}")
if (CMAKE_MATCH_3)
set(smtk_version_patch ${CMAKE_MATCH_3})
set(smtk_version "${smtk_version}.${smtk_version_patch}")
else()
set(smtk_version_patch 0)
endif()
# To be thorough, we should split the label into "-prerelease+metadata"
# and, if prerelease is specified, use it in determining precedence
# according to semantic versioning rules at http://semver.org/ .
# For now, just make the information available as a label:
if (CMAKE_MATCH_4)
set(smtk_version_label "${CMAKE_MATCH_4}")
endif()
cmake_minimum_required(VERSION 3.6.1)
project(meshkit-superbuild)
function (superbuild_find_projects var)
set(projects
cgm
cxx11
eigen
hdf5
meshkit
moab
netcdf
szip
zlib)
set("${var}"
${projects}
PARENT_SCOPE)
endfunction ()
function (superbuild_sanity_check)
if (NOT meshkit_enabled)
message(FATAL_ERROR "Meshkit is disabled...")
endif ()
endfunction ()
list(APPEND superbuild_version_files
"${CMAKE_CURRENT_LIST_DIR}/versions.cmake"
"${CMAKE_CURRENT_LIST_DIR}/../versions.cmake")
list(APPEND superbuild_project_roots
"${CMAKE_CURRENT_LIST_DIR}/projects"
"${CMAKE_CURRENT_LIST_DIR}/../projects")
# set the default arguments used for "git clone"
set(_git_clone_arguments_default --progress)
# set the default for meshkit to be enabled for this project
set(_superbuild_default_meshkit ON)
if (NOT EXISTS "${CMAKE_CURRENT_LIST_DIR}/../superbuild/CMakeLists.txt")
message(FATAL_ERROR "It appears as though the superbuild infrastructure "
"is missing; did you forget to do `git submodule init` "
"and `git submodule update`?")
endif ()
add_subdirectory("${CMAKE_CURRENT_LIST_DIR}/../superbuild" "${CMAKE_CURRENT_BINARY_DIR}/superbuild")
superbuild_add_project(cgm superbuild_add_project(cgm
DEPENDS oce
DEPENDS_OPTIONAL cxx11 DEPENDS_OPTIONAL cxx11
CMAKE_ARGS CMAKE_ARGS
-DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS} # Set link path on linux
-DCMAKE_INSTALL_RPATH:PATH=$ORIGIN/../lib
# Set link path on OSX
-DCMAKE_INSTALL_NAME_DIR:PATH=<INSTALL_DIR>/lib -DCMAKE_INSTALL_NAME_DIR:PATH=<INSTALL_DIR>/lib
-DCGM_USE_CUBIT:BOOL=OFF -DCGM_OCC:BOOL=OFF
-DCGM_OCC:BOOL=ON
-DUSE_MPI:BOOL=OFF) -DUSE_MPI:BOOL=OFF)
superbuild_add_extra_cmake_args( superbuild_add_extra_cmake_args(
"-DCGM_DIR=<INSTALL_DIR>/lib/cmake/CGM") -DCGM_DIR:PATH=<INSTALL_DIR>/lib/cmake/CGM)
superbuild_add_project(meshkit
DEPENDS moab cgm
CMAKE_ARGS
# Set link path on linux
-DCMAKE_INSTALL_RPATH:PATH=$ORIGIN/../lib
-DCGM_DIR:PATH=<INSTALL_DIR>/lib/cmake/CGM
-DBUILD_ALGS:BOOL=ON
-DBUILD_SRC:BOOL=ON
-DBUILD_UTILS:BOOL=ON
-DBUILD_RGG:BOOL=ON
-DWITH_MPI:BOOL=OFF
-DENABLE_TESTING:BOOL=OFF)
# MOAB has public headers which include Eigen, but it doesn't add the include
# flags properly.
superbuild_append_flags(cxx_flags "-I<INSTALL_DIR>/include/eigen3" PROJECT_ONLY)
superbuild_add_project(moab
DEPENDS cgm eigen netcdf zlib
CMAKE_ARGS
# Set link path on OSX
-DCMAKE_INSTALL_NAME_DIR:PATH=<INSTALL_DIR>/lib
-DCMAKE_INSTALL_LIBDIR:STRING=lib
-DENABLE_IMESH:BOOL=ON
-DENABLE_CGM:BOOL=ON
-DENABLE_NETCDF:BOOL=ON
-DENABLE_IREL:BOOL=ON
-DENABLE_HDF5:BOOL=OFF
-DENABLE_PNETCDF:BOOL=OFF
-DENABLE_MPI:BOOL=OFF
-DENABLE_TESTING:BOOL=OFF
-DNETCDF_ROOT:PATH=<INSTALL_DIR>)
superbuild_apply_patch(moab disable-fortran
"Disable use of fortran")
# By default, linux and os x cmake looks in <INSTALL_DIR>/lib/cmake for
# things. On windows, it does not. So, we set MOAB_DIR to point to the
# location of MOABConfig.cmake for everyone.
superbuild_add_extra_cmake_args(
-DMOAB_DIR:PATH=<INSTALL_DIR>/lib/cmake/MOAB)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index bc5b0cef..a5b75198 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,24 +2,24 @@ cmake_minimum_required( VERSION 3.0 )
SET(PACKAGE_NAME "MOAB")
SET(PACKAGE_VERSION "5.1.1")
-if (NOT WIN32)
- #This all breaks on windows.
- SET(CMAKE_Fortran_COMPILER_INIT ${CMAKE_GENERATOR_FC})
- SET(CMAKE_CXX_FLAGS_INIT "-fPIC -DPIC")
- SET(CMAKE_CXX_FLAGS_DEBUG_INIT "-O0 -g")
- SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
- SET(CMAKE_CXX_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
- SET(CMAKE_C_FLAGS_INIT "-fPIC -DPIC")
- SET(CMAKE_C_FLAGS_DEBUG_INIT "-O0 -g")
- SET(CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
- SET(CMAKE_C_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
- SET(CMAKE_Fortran_FLAGS_INIT "-fPIC")
- SET(CMAKE_Fortran_FLAGS_DEBUG_INIT "-O0 -g")
- SET(CMAKE_Fortran_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
- SET(CMAKE_Fortran_FLAGS_RELEASE_INIT "-O2")
- SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS_INIT "")
- SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS_INIT "")
-endif()
+#if (NOT WIN32)
+# #This all breaks on windows.
+# SET(CMAKE_Fortran_COMPILER_INIT ${CMAKE_GENERATOR_FC})
+# SET(CMAKE_CXX_FLAGS_INIT "-fPIC -DPIC")
+# SET(CMAKE_CXX_FLAGS_DEBUG_INIT "-O0 -g")
+# SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
+# SET(CMAKE_CXX_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
+# SET(CMAKE_C_FLAGS_INIT "-fPIC -DPIC")
+# SET(CMAKE_C_FLAGS_DEBUG_INIT "-O0 -g")
+# SET(CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
+# SET(CMAKE_C_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
+# SET(CMAKE_Fortran_FLAGS_INIT "-fPIC")
+# SET(CMAKE_Fortran_FLAGS_DEBUG_INIT "-O0 -g")
+# SET(CMAKE_Fortran_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
+# SET(CMAKE_Fortran_FLAGS_RELEASE_INIT "-O2")
+# SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS_INIT "")
+# SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS_INIT "")
+#endif()
project( MOAB )
@@ -395,29 +395,29 @@ CONFIGURE_FILE(
IMMEDIATE @ONLY
)
-if (ENABLE_FORTRAN)
- enable_language(Fortran)
-
- # Include CMake's Fortran mangling evaluation macros
- include(FortranCInterface)
-
- if ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
- set(FC_CASE "NAME")
- else ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
- set(FC_CASE "name")
- endif ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
- if (NOT "${FortranCInterface_GLOBAL_SUFFIX}" STREQUAL "")
- set(FortranCInterface_GLOBAL_SUFFIX "## ${FortranCInterface_GLOBAL_SUFFIX}")
- endif (NOT "${FortranCInterface_GLOBAL_SUFFIX}" STREQUAL "")
- if (NOT "${FortranCInterface_GLOBAL__SUFFIX}" STREQUAL "")
- set(FortranCInterface_GLOBAL__SUFFIX "## ${FortranCInterface_GLOBAL__SUFFIX}")
- endif (NOT "${FortranCInterface_GLOBAL__SUFFIX}" STREQUAL "")
-
- set(MOAB_F77_FUNC "${FortranCInterface_GLOBAL_PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL_SUFFIX}")
- set(MOAB_F77_FUNC_ "${FortranCInterface_GLOBAL__PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL__SUFFIX}")
- set(MOAB_FC_FUNC "${FortranCInterface_GLOBAL_PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL_SUFFIX}")
- set(MOAB_FC_FUNC_ "${FortranCInterface_GLOBAL__PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL__SUFFIX}")
-endif (ENABLE_FORTRAN)
+ #if (ENABLE_FORTRAN)
+ # enable_language(Fortran)
+ #
+ # # Include CMake's Fortran mangling evaluation macros
+ # include(FortranCInterface)
+ #
+ # if ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
+ # set(FC_CASE "NAME")
+ # else ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
+ # set(FC_CASE "name")
+ # endif ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
+ # if (NOT "${FortranCInterface_GLOBAL_SUFFIX}" STREQUAL "")
+ # set(FortranCInterface_GLOBAL_SUFFIX "## ${FortranCInterface_GLOBAL_SUFFIX}")
+ # endif (NOT "${FortranCInterface_GLOBAL_SUFFIX}" STREQUAL "")
+ # if (NOT "${FortranCInterface_GLOBAL__SUFFIX}" STREQUAL "")
+ # set(FortranCInterface_GLOBAL__SUFFIX "## ${FortranCInterface_GLOBAL__SUFFIX}")
+ # endif (NOT "${FortranCInterface_GLOBAL__SUFFIX}" STREQUAL "")
+ #
+ # set(MOAB_F77_FUNC "${FortranCInterface_GLOBAL_PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL_SUFFIX}")
+ # set(MOAB_F77_FUNC_ "${FortranCInterface_GLOBAL__PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL__SUFFIX}")
+ # set(MOAB_FC_FUNC "${FortranCInterface_GLOBAL_PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL_SUFFIX}")
+ # set(MOAB_FC_FUNC_ "${FortranCInterface_GLOBAL__PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL__SUFFIX}")
+ #endif (ENABLE_FORTRAN)
# Generate the CMake input header file and then pass it through configuration
## execute_process( COMMAND cat MOABConfig.h.in COMMAND sed -e "s/#undef /#cmakedefine MOAB_/g"
superbuild_add_project(moab
DEPENDS cgm eigen netcdf zlib
CMAKE_ARGS
# Set link path properly on linux
-DCMAKE_INSTALL_RPATH:PATH=$ORIGIN/../lib
-DCMAKE_INSTALL_LIBDIR:STRING=lib
-DENABLE_BLASLAPACK:BOOL=OFF
-DENABLE_IMESH:BOOL=ON
-DENABLE_CGM:BOOL=ON
-DENABLE_NETCDF:BOOL=ON
-DENABLE_IREL:BOOL=ON
-DENABLE_HDF5:BOOL=OFF
-DENABLE_PNETCDF:BOOL=OFF
-DENABLE_MPI:BOOL=OFF
-DENABLE_TESTING:BOOL=OFF
-DNETCDF_ROOT:PATH=<INSTALL_DIR>)
superbuild_apply_patch(moab disable-fortran
"Disable use of fortran")
# By default, linux and os x cmake looks in <INSTALL_DIR>/lib/cmake for
# things. On windows, it does not. So, we set MOAB_DIR to point to the
# location of MOABConfig.cmake for everyone.
superbuild_add_extra_cmake_args(
-DMOAB_DIR:PATH=<INSTALL_DIR>/lib/cmake/MOAB)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index bc5b0cef..a5b75198 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,24 +2,24 @@ cmake_minimum_required( VERSION 3.0 )
SET(PACKAGE_NAME "MOAB")
SET(PACKAGE_VERSION "5.1.1")
-if (NOT WIN32)
- #This all breaks on windows.
- SET(CMAKE_Fortran_COMPILER_INIT ${CMAKE_GENERATOR_FC})
- SET(CMAKE_CXX_FLAGS_INIT "-fPIC -DPIC")
- SET(CMAKE_CXX_FLAGS_DEBUG_INIT "-O0 -g")
- SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
- SET(CMAKE_CXX_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
- SET(CMAKE_C_FLAGS_INIT "-fPIC -DPIC")
- SET(CMAKE_C_FLAGS_DEBUG_INIT "-O0 -g")
- SET(CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
- SET(CMAKE_C_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
- SET(CMAKE_Fortran_FLAGS_INIT "-fPIC")
- SET(CMAKE_Fortran_FLAGS_DEBUG_INIT "-O0 -g")
- SET(CMAKE_Fortran_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
- SET(CMAKE_Fortran_FLAGS_RELEASE_INIT "-O2")
- SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS_INIT "")
- SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS_INIT "")
-endif()
+#if (NOT WIN32)
+# #This all breaks on windows.
+# SET(CMAKE_Fortran_COMPILER_INIT ${CMAKE_GENERATOR_FC})
+# SET(CMAKE_CXX_FLAGS_INIT "-fPIC -DPIC")
+# SET(CMAKE_CXX_FLAGS_DEBUG_INIT "-O0 -g")
+# SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
+# SET(CMAKE_CXX_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
+# SET(CMAKE_C_FLAGS_INIT "-fPIC -DPIC")
+# SET(CMAKE_C_FLAGS_DEBUG_INIT "-O0 -g")
+# SET(CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
+# SET(CMAKE_C_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
+# SET(CMAKE_Fortran_FLAGS_INIT "-fPIC")
+# SET(CMAKE_Fortran_FLAGS_DEBUG_INIT "-O0 -g")
+# SET(CMAKE_Fortran_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
+# SET(CMAKE_Fortran_FLAGS_RELEASE_INIT "-O2")
+# SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS_INIT "")
+# SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS_INIT "")
+#endif()
project( MOAB )
@@ -395,29 +395,29 @@ CONFIGURE_FILE(
IMMEDIATE @ONLY
)
-if (ENABLE_FORTRAN)
- enable_language(Fortran)
-
- # Include CMake's Fortran mangling evaluation macros
- include(FortranCInterface)
-
- if ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
- set(FC_CASE "NAME")
- else ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
- set(FC_CASE "name")
- endif ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
- if (NOT "${FortranCInterface_GLOBAL_SUFFIX}" STREQUAL "")
- set(FortranCInterface_GLOBAL_SUFFIX "## ${FortranCInterface_GLOBAL_SUFFIX}")
- endif (NOT "${FortranCInterface_GLOBAL_SUFFIX}" STREQUAL "")
- if (NOT "${FortranCInterface_GLOBAL__SUFFIX}" STREQUAL "")
- set(FortranCInterface_GLOBAL__SUFFIX "## ${FortranCInterface_GLOBAL__SUFFIX}")
- endif (NOT "${FortranCInterface_GLOBAL__SUFFIX}" STREQUAL "")
-
- set(MOAB_F77_FUNC "${FortranCInterface_GLOBAL_PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL_SUFFIX}")
- set(MOAB_F77_FUNC_ "${FortranCInterface_GLOBAL__PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL__SUFFIX}")
- set(MOAB_FC_FUNC "${FortranCInterface_GLOBAL_PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL_SUFFIX}")
- set(MOAB_FC_FUNC_ "${FortranCInterface_GLOBAL__PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL__SUFFIX}")
-endif (ENABLE_FORTRAN)
+ #if (ENABLE_FORTRAN)
+ # enable_language(Fortran)
+ #
+ # # Include CMake's Fortran mangling evaluation macros
+ # include(FortranCInterface)
+ #
+ # if ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
+ # set(FC_CASE "NAME")
+ # else ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
+ # set(FC_CASE "name")
+ # endif ("${FortranCInterface_GLOBAL_CASE}" MATCHES "UPPER")
+ # if (NOT "${FortranCInterface_GLOBAL_SUFFIX}" STREQUAL "")
+ # set(FortranCInterface_GLOBAL_SUFFIX "## ${FortranCInterface_GLOBAL_SUFFIX}")
+ # endif (NOT "${FortranCInterface_GLOBAL_SUFFIX}" STREQUAL "")
+ # if (NOT "${FortranCInterface_GLOBAL__SUFFIX}" STREQUAL "")
+ # set(FortranCInterface_GLOBAL__SUFFIX "## ${FortranCInterface_GLOBAL__SUFFIX}")
+ # endif (NOT "${FortranCInterface_GLOBAL__SUFFIX}" STREQUAL "")
+ #
+ # set(MOAB_F77_FUNC "${FortranCInterface_GLOBAL_PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL_SUFFIX}")
+ # set(MOAB_F77_FUNC_ "${FortranCInterface_GLOBAL__PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL__SUFFIX}")
+ # set(MOAB_FC_FUNC "${FortranCInterface_GLOBAL_PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL_SUFFIX}")
+ # set(MOAB_FC_FUNC_ "${FortranCInterface_GLOBAL__PREFIX} ${FC_CASE} ${FortranCInterface_GLOBAL__SUFFIX}")
+ #endif (ENABLE_FORTRAN)
# Generate the CMake input header file and then pass it through configuration
## execute_process( COMMAND cat MOABConfig.h.in COMMAND sed -e "s/#undef /#cmakedefine MOAB_/g"
include("${CMAKE_CURRENT_LIST_DIR}/../moab.cmake")
superbuild_apply_patch(moab quote-compiler-path
"Add quotations around compiler path to avoid whitespace warnings.")
superbuild_apply_patch(moab remove-flags-from-link-list
"Remove CMake error where linker flags are a part of the link library list")
superbuild_apply_patch(moab msvc-fixes
"Many windows-specific fixes for moab (not developed on windows).")
diff -Nr -U5 moab/src/GeomQueryTool.cpp moab_patched/src/GeomQueryTool.cpp
--- moab/src/GeomQueryTool.cpp Fri Jan 19 16:55:39 2018
+++ moab_patched/src/GeomQueryTool.cpp Fri Jan 19 16:53:37 2018
@@ -7,10 +7,12 @@
#include <limits>
#include <algorithm>
#include <set>
#include <ctype.h>
+#define _USE_MATH_DEFINES
+#include <math.h>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include "moab/OrientedBoxTreeTool.hpp"
diff -Nr -U5 moab/src/IntxMesh/Intx2MeshOnSphere.cpp moab_patched/src/IntxMesh/Intx2MeshOnSphere.cpp
--- moab/src/IntxMesh/Intx2MeshOnSphere.cpp Fri Jan 19 16:55:39 2018
+++ moab_patched/src/IntxMesh/Intx2MeshOnSphere.cpp Fri Jan 19 16:53:37 2018
@@ -2,10 +2,13 @@
* Intx2MeshOnSphere.cpp
*
* Created on: Oct 3, 2012
*/
+#define _USE_MATH_DEFINES
+#include <cmath>
+
#include "moab/IntxMesh/Intx2MeshOnSphere.hpp"
#include "moab/IntxMesh/IntxUtils.hpp"
#include "moab/GeomUtil.hpp"
#ifdef MOAB_HAVE_MPI
#include "moab/ParallelComm.hpp"
diff -Nr -U5 moab/src/IntxMesh/IntxUtils.cpp moab_patched/src/IntxMesh/IntxUtils.cpp
--- moab/src/IntxMesh/IntxUtils.cpp Fri Jan 19 16:55:39 2018
+++ moab_patched/src/IntxMesh/IntxUtils.cpp Fri Jan 19 16:53:37 2018
@@ -2,10 +2,11 @@
* IntxUtils.cpp
*
* Created on: Oct 3, 2012
*/
+#define _USE_MATH_DEFINES
#include <math.h>
#include "moab/IntxMesh/IntxUtils.hpp"
// this is from mbcoupler; maybe it should be moved somewhere in moab src
// right now, add a dependency to mbcoupler
// #include "ElemUtil.hpp"
diff -Nr -U5 moab/src/MeshGeneration.cpp moab_patched/src/MeshGeneration.cpp
--- moab/src/MeshGeneration.cpp Fri Jan 19 16:55:39 2018
+++ moab_patched/src/MeshGeneration.cpp Fri Jan 19 16:53:37 2018
@@ -6,10 +6,12 @@
#include "moab/MeshGeneration.hpp"
#include "moab/MergeMesh.hpp"
#include <iostream>
#include <vector>
+#include <time.h>
+
#ifdef MOAB_HAVE_MPI
#include "moab_mpi.h"
#include "moab/ParallelComm.hpp"
#include "MBParallelConventions.h"
#include "moab/ParallelMergeMesh.hpp"
diff -Nr -U5 moab/src/moab/Util.hpp moab_patched/src/moab/Util.hpp
--- moab/src/moab/Util.hpp Fri Jan 19 16:55:40 2018
+++ moab_patched/src/moab/Util.hpp Fri Jan 19 16:53:38 2018
@@ -18,20 +18,23 @@
#include "moab/MOABConfig.h"
#include "moab/Forward.hpp"
#include "moab/CartVect.hpp"
-#include <math.h>
-#if defined MOAB_HAVE_ISFINITE
-#define moab_isfinite(f) isfinite(f)
-#elif defined MOAB_HAVE_STDISFINITE
#include <cmath>
-#define moab_isfinite(f) std::isfinite(f)
+#if defined MOAB_HAVE_ISFINITE
+# define moab_isfinite(f) isfinite(f)
+//If we have c++11 support, we will have std::isfinite
+#elif (defined(__cplusplus) && __cplusplus >= 201103L)
+# define moab_isfinite(f) std::isfinite(f)
+#elif (defined(_WIN32) && defined(_MSC_VER)) || defined(__MINGW32__)
+# include <float.h>
+# define moab_isfinite(A) _finite(A)
#elif defined MOAB_HAVE_FINITE
-#define moab_isfinite(f) finite(f)
+# define moab_isfinite(f) finite(f)
#else
-#define moab_isfinite(f) (!isinf(f) && !isnan(f))
+# define moab_isfinite(f) (!isinf(f) && !isnan(f))
#endif
namespace moab {
/** \class Util
diff -Nr -U5 moab/src/ProgOptions.cpp moab_patched/src/ProgOptions.cpp
--- moab/src/ProgOptions.cpp Fri Jan 19 16:55:40 2018
+++ moab_patched/src/ProgOptions.cpp Fri Jan 19 16:53:38 2018
@@ -1,5 +1,7 @@
+#define NOMINMAX
+#include <algorithm>
#include <iostream>
#include <sstream>
#include <iomanip>
#include <cstdlib>
#include <list>
diff -Nr -U5 moab/test/perf/CMakeLists.txt moab_patched/test/perf/CMakeLists.txt
--- moab/test/perf/CMakeLists.txt Fri Jan 19 16:55:40 2018
+++ moab_patched/test/perf/CMakeLists.txt Fri Jan 19 16:53:38 2018
@@ -11,12 +11,12 @@
perf.cpp
perftool.cpp
umr_perf.cpp )
if ( MOAB_HAVE_IMESH )
- set(TESTS ${TESTS} tstt_perf_binding.cpp)
- set(tstt_perf_binding_CMDARGS 4;B)
+# set(TESTS ${TESTS} tstt_perf_binding.cpp)
+# set(tstt_perf_binding_CMDARGS 4;B)
set(LIBS ${LIBS} iMesh )
endif()
if ( MOAB_HAVE_CGM )
set(LIBS ${LIBS} ${CGM_LIBRARIES})
endif()
diff -Nr -U5 moab/test/spherical_area_test.cpp moab_patched/test/spherical_area_test.cpp
--- moab/test/spherical_area_test.cpp Fri Jan 19 16:55:40 2018
+++ moab_patched/test/spherical_area_test.cpp Fri Jan 19 16:53:38 2018
@@ -1,10 +1,13 @@
/*
* spherical_area_test.cpp
*
* Created on: Feb 1, 2013
*/
+#define _USE_MATH_DEFINES
+#include <math.h>
+
#include <iostream>
#include "moab/Core.hpp"
#include "moab/Interface.hpp"
#include "moab/IntxMesh/IntxUtils.hpp"
#include "TestUtil.hpp"
diff -Nr -U5 moab/test/urefine_mesh_test.cpp moab_patched/test/urefine_mesh_test.cpp
--- moab/test/urefine_mesh_test.cpp Fri Jan 19 16:55:40 2018
+++ moab_patched/test/urefine_mesh_test.cpp Fri Jan 19 16:53:38 2018
@@ -1,10 +1,9 @@
/*This unit test is for the uniform refinement capability based on AHF datastructures*/
#include <iostream>
#include <string>
#include <sstream>
-#include <sys/time.h>
#include <vector>
#include <algorithm>
#include "moab/Core.hpp"
#include "moab/Range.hpp"
#include "moab/MeshTopoUtil.hpp"
diff -Nr -U5 moab/tools/umr.cpp moab_patched/tools/umr.cpp
--- moab/tools/umr.cpp Fri Jan 19 16:55:41 2018
+++ moab_patched/tools/umr.cpp Fri Jan 19 16:53:39 2018
@@ -3,11 +3,10 @@
#include <vector>
#include <string>
#include <stdio.h>
#include <iomanip>
#include <fstream>
-#include <sys/time.h>
#include <time.h>
#include <math.h>
#include <assert.h>
#include <float.h>
diff -Nr -U5 src/config/MOABConfig.cmake.in src.new/config/MOABConfig.cmake.in
--- src/config/MOABConfig.cmake.in 2017-11-29 11:03:38.000000000 -0500
+++ src.new/config/MOABConfig.cmake.in 2018-01-24 10:26:22.000000000 -0500
@@ -8,14 +8,14 @@
# MOAB_CXX, MOAB_CC, MOAB_F77, MOAB_FC - compilers used to compile MOAB
# MOAB_CXXFLAGS, MOAB_CCFLAGS, MOAB_FFLAGS, MOAB_FCFLAGS - compiler flags used to compile MOAB; possibly need to use these in add_definitions or CMAKE_<LANG>_FLAGS_<MODE>
set(MOAB_FOUND 1)
-set(MOAB_CC @CC@)
-set(MOAB_CXX @CXX@)
-set(MOAB_FC @FC@)
-set(MOAB_F77 @F77@)
+set(MOAB_CC "@CC@")
+set(MOAB_CXX "@CXX@")
+set(MOAB_FC "@FC@")
+set(MOAB_F77 "@F77@")
# Compiler flags used by MOAB
set(MOAB_CFLAGS "@CFLAGS@")
set(MOAB_CXXFLAGS "@CXXFLAGS@")
set(MOAB_FCFLAGS "@FCFLAGS@")
set(MOAB_FFLAGS "@FFLAGS@")
diff -Nr -U5 src/config/MOABConfig.cmake.cmake src_patched/config/MOABConfig.cmake.cmake
--- src/config/MOABConfig.cmake.cmake 2017-11-29 11:03:38.000000000 -0500
+++ src_patched/config/MOABConfig.cmake.cmake 2018-02-14 16:08:31.000000000 -0500
@@ -8,14 +8,14 @@
# MOAB_CXX, MOAB_CC, MOAB_F77, MOAB_FC - compilers used to compile MOAB
# MOAB_CXXFLAGS, MOAB_CCFLAGS, MOAB_FFLAGS, MOAB_FCFLAGS - compiler flags used to compile MOAB; possibly need to use these in add_definitions or CMAKE_<LANG>_FLAGS_<MODE>
set(MOAB_FOUND 1)
-set(MOAB_CC @CMAKE_C_COMPILER@)
-set(MOAB_CXX @CMAKE_CXX_COMPILER@)
-set(MOAB_FC @CMAKE_Fortran_COMPILER@)
-set(MOAB_F77 @CMAKE_Fortran_COMPILER@)
+set(MOAB_CC "@CMAKE_C_COMPILER@")
+set(MOAB_CXX "@CMAKE_CXX_COMPILER@")
+set(MOAB_FC "@CMAKE_Fortran_COMPILER@")
+set(MOAB_F77 "@CMAKE_Fortran_COMPILER@")
# Compiler flags used by MOAB
set(MOAB_CFLAGS "@CFLAGS@")
set(MOAB_CXXFLAGS "@CXXFLAGS@")
set(MOAB_FCFLAGS "@FFLAGS@")
set(MOAB_FFLAGS "@FFLAGS@")
diff -Nr -U5 src/src/CMakeLists.txt src.new/src/CMakeLists.txt
--- src/src/CMakeLists.txt 2017-11-29 11:03:38.000000000 -0500
+++ src.new/src/CMakeLists.txt 2018-01-19 15:58:49.000000000 -0500
@@ -279,11 +279,11 @@
SOVERSION ${MOAB_VERSION_MAJOR}
)
target_link_libraries(
MOAB
- ${CMAKE_EXE_LINKER_FLAGS} ${MOAB_DEP_LIBRARIES} ${MOAB_LIBS} ${MOAB_CGM_LIBS} ${MPI_LIBRARIES} ${LAPACK_LIBRARIES} ${BLAS_LIBRARIES}
+ ${MOAB_DEP_LIBRARIES} ${MOAB_LIBS} ${MOAB_CGM_LIBS} ${MPI_LIBRARIES} ${LAPACK_LIBRARIES} ${BLAS_LIBRARIES}
)
install(
TARGETS MOAB
EXPORT MOABTargets
superbuild_set_revision(cgm
GIT_REPOSITORY "https://bitbucket.org/fathomteam/cgm.git"
GIT_TAG 18403e5b100fe8d49a8ac0d6a2e849a0bbeae3bd)
superbuild_set_revision(meshkit
GIT_REPOSITORY "https://haocheng_liu@bitbucket.org/haocheng_liu/meshkit.git"
GIT_TAG osx-10-dot-13-patch)
superbuild_set_revision(moab
GIT_REPOSITORY "https://bitbucket.org/fathomteam/moab.git"
GIT_TAG 78d0b938fcf80fcdfb34fa39583fbce544b56953)
include("${CMAKE_CURRENT_LIST_DIR}/../kml.cmake")
superbuild_apply_patch(kml add-missing-unistd.h
"file_posix.cc misses including unistd.h")
diff -Nru5 src/src/kml/base/file_posix.cc src.add-missing-unistd.h/src/kml/base/file_posix.cc
--- src/src/kml/base/file_posix.cc 2012-04-06 08:25:40.000000000 -0400
+++ src.add-missing-unistd.h/src/kml/base/file_posix.cc 2016-02-23 17:04:57.943711396 -0500
@@ -30,10 +30,13 @@
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <sys/stat.h>
+// posix compile fix:
+#include <unistd.h>
+
namespace kmlbase {
// Internal to the POSIX File class.
static bool StatFile(const char* path, struct stat* stat_data) {
struct stat tmp;
# Capstone is a private program to which Kitware developers have access. We
# provide logic for situating these programs into our superbuild for development
# purposes only. Nothing is bundled or distributed.
superbuild_add_project(capstone
CAN_USE_SYSTEM
DOWNLOAD_NO_EXTRACT 1
CONFIGURE_COMMAND
/bin/sh -c "yes | hdiutil attach -mountpoint '<SOURCE_DIR>' '<DOWNLOADED_FILE>'"
BUILD_COMMAND
${CMAKE_COMMAND} -E copy_directory "<SOURCE_DIR>/Capstone-9.1.2" "<BINARY_DIR>"
INSTALL_COMMAND
hdiutil detach <SOURCE_DIR>
)
set(capstone_pythonpath ${CMAKE_CURRENT_BINARY_DIR}/capstone/build/Capstone.app/Contents/MacOS)
set(CreateMG_DIR ${CMAKE_CURRENT_BINARY_DIR}/capstone/build/lib)
set(cmb_plugins) foreach(program IN LISTS cmb_programs_to_install)
foreach (cmb_plugin IN LISTS cmb_plugins_all) set(additional_libraries)
if (EXISTS "${superbuild_install_location}/Applications/ModelBuilder.app/Contents/Libraries/lib${cmb_plugin}.dylib") set(plugins)
list(APPEND cmb_plugins set(plugin_paths)
${cmb_plugin})
set("cmb_plugin_path_${cmb_plugin}"
"${superbuild_install_location}/Applications/ModelBuilder.app/Contents/Libraries/lib${cmb_plugin}.dylib")
continue ()
endif ()
foreach (path IN ITEMS "" "cmb-${cmb_version}" "paraview-${paraview_version}") if (program STREQUAL "modelbuilder")
if (EXISTS "${superbuild_install_location}/lib/${path}/lib${cmb_plugin}.dylib") # Install additional libraries in modelbuilder app
list(APPEND cmb_plugins foreach(library IN LISTS cmb_additional_libraries)
${cmb_plugin}) list(APPEND additional_libraries "${superbuild_install_location}/lib/lib${library}.dylib")
set("cmb_plugin_path_${cmb_plugin}" endforeach()
"${superbuild_install_location}/lib/${path}/lib${cmb_plugin}.dylib")
break ()
endif ()
endforeach ()
endforeach ()
set(python_modules) # Install CMB plugins in modelbuilder app
if (pythongirderclient_enabled) foreach(plugin IN LISTS cmb_plugins_cmb)
list(APPEND python_modules list(APPEND plugin_paths "${superbuild_install_location}/Applications/modelbuilder.app/Contents/Plugins/lib${plugin}.dylib")
requests endforeach()
girder_client) list(APPEND plugins ${cmb_plugins_cmb})
endif ()
foreach(program IN LISTS cmb_programs_to_install) # Install CMB plugins in modelbuilder app
set(plugins "${cmb_plugins_${program}}") foreach(plugin IN LISTS cmb_plugins_standalone)
list(APPEND plugin_paths "${superbuild_install_location}/lib/lib${plugin}.dylib")
endforeach()
list(APPEND plugins ${cmb_plugins_standalone})
set(plugin_paths) # Install paraview plugins in modelbuilder app
foreach (plugin IN LISTS plugins) foreach (plugin IN LISTS cmb_plugins_paraview)
if (NOT DEFINED "cmb_plugin_path_${plugin}") list(APPEND plugin_paths "${superbuild_install_location}/Applications/paraview.app/Contents/Plugins/lib${plugin}.dylib")
message(FATAL_ERROR "The application ${program} needs the ${plugin} plugin, but it was not found.") endforeach()
endif () list(APPEND plugins ${cmb_plugins_paraview})
list(APPEND plugin_paths endif()
"${cmb_plugin_path_${plugin}}")
endforeach ()
superbuild_apple_create_app( superbuild_apple_create_app(
"\${CMAKE_INSTALL_PREFIX}/${cmb_package}" "\${CMAKE_INSTALL_PREFIX}/${cmb_package}"
"${program}.app" "${program}.app"
"${superbuild_install_location}/Applications/${program}.app/Contents/MacOS/${program}" "${superbuild_install_location}/Applications/${program}.app/Contents/MacOS/${program}"
CLEAN CLEAN
FAKE_PLUGIN_PATHS
PLUGINS ${plugin_paths} PLUGINS ${plugin_paths}
ADDITIONAL_LIBRARIES ${additional_libraries}
SEARCH_DIRECTORIES SEARCH_DIRECTORIES
"${superbuild_install_location}/lib") "${superbuild_install_location}/lib")
foreach (icon_filename MacIcon.icns pvIcon.icns) foreach (icon_filename MacIcon.icns pvIcon.icns modelbuilder.icns)
set(icon_path "${superbuild_install_location}/Applications/${program}.app/Contents/Resources/${icon_filename}") set(icon_path "${superbuild_install_location}/Applications/${program}.app/Contents/Resources/${icon_filename}")
if (EXISTS "${icon_path}") if (EXISTS "${icon_path}")
install( install(
...@@ -95,12 +85,12 @@ foreach(program IN LISTS cmb_programs_to_install) ...@@ -95,12 +85,12 @@ foreach(program IN LISTS cmb_programs_to_install)
"${superbuild_install_location}/lib" "${superbuild_install_location}/lib"
"${superbuild_install_location}/Applications/paraview.app/Contents/Libraries") "${superbuild_install_location}/Applications/paraview.app/Contents/Libraries")
# Install the paraview.vtk module. if (matplotlib_enabled)
install(CODE install(
"file(INSTALL DIRECTORY "${superbuild_install_location}/lib/python2.7/site-packages/matplotlib/mpl-data/"
FILES \"\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${cmb_package}/${program}.app/Contents/Python/vtk/\" DESTINATION "${cmb_package}/${program}.app/Contents/Python/matplotlib/mpl-data"
DESTINATION \"\${CMAKE_INSTALL_PREFIX}/${cmb_package}/${program}.app/Contents/Python/paraview/vtk\")" COMPONENT superbuild)
COMPONENT superbuild) endif ()
if (pythonrequests_enabled) if (pythonrequests_enabled)
install( install(
...@@ -108,6 +98,36 @@ foreach(program IN LISTS cmb_programs_to_install) ...@@ -108,6 +98,36 @@ foreach(program IN LISTS cmb_programs_to_install)
DESTINATION "${cmb_package}/${program}.app/Contents/Python/requests" DESTINATION "${cmb_package}/${program}.app/Contents/Python/requests"
COMPONENT superbuild) COMPONENT superbuild)
endif () endif ()
if (paraviewweb_enabled)
install(
FILES "${superbuild_install_location}/Applications/paraview.app/Contents/Python/paraview/web/defaultProxies.json"
DESTINATION "${cmb_package}/${program}.app/Contents/Python/paraview/web"
COMPONENT "superbuild")
install(
DIRECTORY "${superbuild_install_location}/share/paraview/web"
DESTINATION "${cmb_package}/${program}.app/Contents/Resources"
COMPONENT "superbuild")
endif ()
foreach (qt5_plugin_path IN LISTS qt5_plugin_paths)
get_filename_component(qt5_plugin_group "${qt5_plugin_path}" DIRECTORY)
get_filename_component(qt5_plugin_group "${qt5_plugin_group}" NAME)
superbuild_apple_install_module(
"\${CMAKE_INSTALL_PREFIX}/${cmb_package}"
"${program}.app"
"${qt5_plugin_path}"
"Contents/Plugins/${qt5_plugin_group}"
SEARCH_DIRECTORIES "${library_paths}")
endforeach ()
if (cmb_doc_base_dir)
set(cmb_doc_dir "${cmb_package}/${program}.app/${cmb_doc_base_dir}")
endif ()
# Install PDF guides.
cmb_install_extra_data()
endforeach () endforeach ()
# FIXME: Install inside of each application? # FIXME: Install inside of each application?
...@@ -115,3 +135,15 @@ install( ...@@ -115,3 +135,15 @@ install(
DIRECTORY "${superbuild_install_location}/share/cmb/workflows/" DIRECTORY "${superbuild_install_location}/share/cmb/workflows/"
DESTINATION "Workflows" DESTINATION "Workflows"
COMPONENT superbuild) COMPONENT superbuild)
if (meshkit_enabled)
foreach (meshkit_exe IN ITEMS coregen assygen)
superbuild_apple_install_utility(
"\${CMAKE_INSTALL_PREFIX}/${cmb_package}"
"modelbuilder.app"
"${superbuild_install_location}/bin/${meshkit_exe}"
SEARCH_DIRECTORIES "${library_paths}"
FRAMEWORK_DEST "Frameworks/meshkit"
LIBRARY_DEST "Libraries/meshkit")
endforeach ()
endif ()
# Cubit is a private program to which Kitware developers have access. We provide
# logic for situating these programs into our superbuild for development
# purposes only. Nothing is bundled or distributed.
superbuild_add_project(cubit
CAN_USE_SYSTEM
DOWNLOAD_NO_EXTRACT 1
CONFIGURE_COMMAND
/bin/sh -c "yes | hdiutil attach -mountpoint '<SOURCE_DIR>' '<DOWNLOADED_FILE>'"
BUILD_COMMAND
${CMAKE_COMMAND} -E copy_directory "<SOURCE_DIR>/Cubit-15.2" "<BINARY_DIR>"
INSTALL_COMMAND
hdiutil detach <SOURCE_DIR>
)
set(CUBIT_EXE ${CMAKE_CURRENT_BINARY_DIR}/cubit/build/Cubit.app/Contents/MacOS/Cubit)
include(hydrology.bundle.common)
set(cmb_package "CMB-Hydro ${cmb_version_major}.${cmb_version_minor}.${cmb_version_patch}")
include(cmb.bundle.apple)
include(modelbuilder.bundle.common) include(modelbuilder.bundle.common)
set(cmb_package "ModelBuilder ${cmb_version_major}.${cmb_version_minor}.${cmb_version_patch}") set(cmb_package "modelbuilder ${cmb_version_major}.${cmb_version_minor}.${cmb_version_patch}")
set(cmb_doc_base_dir "Contents/doc")
include(cmb.bundle.apple) include(cmb.bundle.apple)
include("${CMAKE_CURRENT_LIST_DIR}/../opencv.cmake")
if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS "8.0.0")
superbuild_apply_patch(opencv coreimage-videoio-link
"Remove CoreImage from videoio's linkline")
endif ()
diff --git a/modules/videoio/CMakeLists.txt b/modules/videoio/CMakeLists.txt
index 413b3cd..3b4150b 100644
--- a/modules/videoio/CMakeLists.txt
+++ b/modules/videoio/CMakeLists.txt
@@ -173,7 +173,7 @@ if(HAVE_AVFOUNDATION)
list(APPEND VIDEOIO_LIBRARIES "-framework AVFoundation" "-framework QuartzCore")
else()
list(APPEND videoio_srcs ${CMAKE_CURRENT_LIST_DIR}/src/cap_avfoundation_mac.mm)
- list(APPEND VIDEOIO_LIBRARIES "-framework Cocoa" "-framework Accelerate" "-framework AVFoundation" "-framework CoreGraphics" "-framework CoreImage" "-framework CoreMedia" "-framework CoreVideo" "-framework QuartzCore")
+ list(APPEND VIDEOIO_LIBRARIES "-framework Cocoa" "-framework Accelerate" "-framework AVFoundation" "-framework CoreGraphics" "-framework CoreMedia" "-framework CoreVideo" "-framework QuartzCore")
endif()
endif()
superbuild_add_project(shiboken
DEPENDS qt4 python
CMAKE_ARGS
-DDISABLE_DOCSTRINGS:BOOL=ON)
# Capstone is a private program to which Kitware developers have access. We
# provide logic for situating these programs into our superbuild for development
# purposes only. Nothing is bundled or distributed.
find_package(CreateMG REQUIRED)
set(capstone_pythonpath ${CreateMG_DIR}/bin)
if (APPLE)
set(capstone_pythonpath ${CreateMG_DIR}/../Capstone.app/Contents/MacOS)
endif ()
...@@ -4,35 +4,27 @@ include(cmb-version) ...@@ -4,35 +4,27 @@ include(cmb-version)
include(paraview-version) include(paraview-version)
set(CPACK_PACKAGE_VENDOR "Kitware, Inc.") set(CPACK_PACKAGE_VENDOR "Kitware, Inc.")
set(CPACK_RESOURCE_FILE_LICENSE
"${superbuild_source_directory}/License.txt")
set(CPACK_PACKAGE_VERSION_MAJOR ${cmb_version_major}) set(CPACK_PACKAGE_VERSION_MAJOR ${cmb_version_major})
set(CPACK_PACKAGE_VERSION_MINOR ${cmb_version_minor}) set(CPACK_PACKAGE_VERSION_MINOR ${cmb_version_minor})
if (cmb_version_suffix) set(CPACK_PACKAGE_VERSION_PATCH ${cmb_version_patch}${cmb_version_suffix})
set(CPACK_PACKAGE_VERSION_PATCH ${cmb_version_patch}-${cmb_version_suffix}) if (CMB_PACKAGE_SUFFIX)
else() set(CPACK_PACKAGE_VERSION_PATCH ${CPACK_PACKAGE_VERSION_PATCH}-${CMB_PACKAGE_SUFFIX})
set(CPACK_PACKAGE_VERSION_PATCH ${cmb_version_patch}) endif ()
endif()
SET(CPACK_PACKAGE_INSTALL_DIRECTORY if (NOT DEFINED package_filename)
"${cmb_package_name} ${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}") set(package_filename "${CMB_PACKAGE_FILE_NAME}")
set(CPACK_SOURCE_PACKAGE_FILE_NAME endif ()
"${cmb_package_name}-${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
if(NOT DEFINED CPACK_SYSTEM_NAME) if (package_filename)
set(CPACK_SYSTEM_NAME ${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}) set(CPACK_PACKAGE_FILE_NAME "${package_filename}")
endif() else ()
if(${CPACK_SYSTEM_NAME} MATCHES Windows)
if(CMAKE_CL_64)
set(CPACK_SYSTEM_NAME win64)
else(CMAKE_CL_64)
set(CPACK_SYSTEM_NAME win32)
endif()
endif()
if(NOT DEFINED CPACK_PACKAGE_FILE_NAME)
set(CPACK_PACKAGE_FILE_NAME set(CPACK_PACKAGE_FILE_NAME
"${CPACK_SOURCE_PACKAGE_FILE_NAME}-${CPACK_SYSTEM_NAME}") "${cmb_package_name}-${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
endif() endif ()