Don't hardwire "exclude" to False.

Don't hardwire "exclude" to False.

svn path=/trunk/; revision=10930

--- examples/ada/x16a.adb.cmake
+++ examples/ada/x16a.adb.cmake
@@ -270,7 +270,7 @@
     -- Ada note: This "exclusion" part works if exclude is set to True.
     -- In the C original example, the setting of exclude was handled by the
     -- the input parser which handling is not implemented in this Ada example.
-    exclude := False;
+--    exclude := False;
     if exclude then

         -- Load colour palettes.


Fix broken plugin loading for MSVC debug builds

--- CommonLibrary.cmake
+++ CommonLibrary.cmake
@@ -231,7 +231,7 @@
     set(_compile_definitions) # clear _compile_definitions-NOTFOUND
   endif()
   if(MSVC OR XCODE_VERSION)
-    set(_DSOName ${CMAKE_SHARED_LIBRARY_PREFIX}${Target}${CMAKE_SHARED_LIBRARY_SUFFIX})
+    set(_DSOName ${CMAKE_SHARED_LIBRARY_PREFIX}${Target}${CMAKE_DEBUG_POSTFIX}${CMAKE_SHARED_LIBRARY_SUFFIX})
   else()
     if(APPLE)
       set(_DSOName ${CMAKE_SHARED_LIBRARY_PREFIX}${Target}.${${PROJECT_NAME}_VERSION_ABI}${CMAKE_SHARED_LIBRARY_SUFFIX})


Libray and include paths are defined for upper and lower cases package name.

--- CommonPackage.cmake
+++ CommonPackage.cmake
@@ -132,20 +132,25 @@
     endif()
     set(${PROJECT_NAME}_FIND_PACKAGES_FOUND
       "${${PROJECT_NAME}_FIND_PACKAGES_FOUND} ${Package_Name}")
-    link_directories(${${${Package_Name}_name}_LIBRARY_DIRS})
-    if(NOT "${${${Package_Name}_name}_INCLUDE_DIRS}" MATCHES "-NOTFOUND")
-      if(__is_system_package)
-        include_directories(BEFORE SYSTEM ${${${Package_Name}_name}_INCLUDE_DIRS})
-      else()
-        include_directories(${${${Package_Name}_name}_INCLUDE_DIRS})
-      endif()
-    endif()
-    if(NOT "${${${Package_Name}_name}_INCLUDE_DIR}" MATCHES "-NOTFOUND")
-      if(__is_system_package)
-        include_directories(BEFORE SYSTEM ${${${Package_Name}_name}_INCLUDE_DIR})
-      else()
-        include_directories(${${${Package_Name}_name}_INCLUDE_DIR})
-      endif()
+    set(__library_dirs ${Package_Name}_LIBRARY_DIRS ${PACKAGE_NAME}_LIBRARY_DIRS)
+    link_directories( ${__library_dirs} )
+    set(__include_dirs)
+    if(NOT "${${Package_Name}_INCLUDE_DIRS}" MATCHES "-NOTFOUND")
+      list(APPEND __include_dirs ${${Package_Name}_INCLUDE_DIRS})
+    endif()
+    if(NOT "${${PACKAGE_NAME}_INCLUDE_DIRS}" MATCHES "-NOTFOUND")
+      list(APPEND __include_dirs ${${PACKAGE_NAME}_INCLUDE_DIRS})
+    endif()
+    if(NOT "${${Package_Name}_INCLUDE_DIR}" MATCHES "-NOTFOUND")
+      list(APPEND __include_dirs ${${Package_Name}_INCLUDE_DIR})
+    endif()
+    if(NOT "${${PACKAGE_NAME}_INCLUDE_DIR}" MATCHES "-NOTFOUND")
+      list(APPEND __include_dirs ${${PACKAGE_NAME}_INCLUDE_DIR})
+    endif()
+    if(__is_system_package)
+      include_directories(BEFORE SYSTEM ${__include_dirs})
+    else()
+      include_directories(${__include_dirs})
     endif()
   endif()
 endmacro()


cmake: add MIN_TEST preprocessor symbol for all unit tests.

--- test/min-lib-unittest.cmake
+++ test/min-lib-unittest.cmake
@@ -8,6 +8,10 @@
 	"${C74_INCLUDES}"
 	"${CMAKE_CURRENT_LIST_DIR}/../../min-api/test/catch/include"
 #	"${CMAKE_CURRENT_LIST_DIR}/mock"
+)
+
+add_definitions(
+	-DMIN_TEST
 )

 #set(CMAKE_CXX_FLAGS "-std=c++1y -stdlib=libc++ -fprofile-arcs -ftest-coverage")


simplify use script: remove RAPIDJSON_INCLUDE_DIR

issue https://github.com/smanders/externpro/issues/273

--- projects/use/usexp-rapidjson-config.cmake
+++ projects/use/usexp-rapidjson-config.cmake
@@ -1,24 +1,18 @@
 # RAPIDJSON_FOUND - RapidJSON was found
 # RAPIDJSON_VER - RapidJSON version
-# RAPIDJSON_INCLUDE_DIR - the RapidJSON include directory
 set(prj rapidjson)
 # this file (-config) installed to share/cmake
 get_filename_component(XP_ROOTDIR ${CMAKE_CURRENT_LIST_DIR}/../.. ABSOLUTE)
 get_filename_component(XP_ROOTDIR ${XP_ROOTDIR} ABSOLUTE) # remove relative parts
 string(TOUPPER ${prj} PRJ)
 set(${PRJ}_VER "@VER@ [@PROJECT_NAME@]")
-set(verDir /${prj}_@VER@)
-unset(${PRJ}_INCLUDE_DIR CACHE)
-find_path(${PRJ}_INCLUDE_DIR rapidjson/rapidjson.h PATHS ${XP_ROOTDIR}/include${verDir} NO_DEFAULT_PATH)
 if(NOT TARGET xpro::rapidjson)
   add_library(xpro::rapidjson INTERFACE IMPORTED)
-  if(${PRJ}_INCLUDE_DIR)
-    set_target_properties(xpro::rapidjson PROPERTIES
-      INTERFACE_INCLUDE_DIRECTORIES "${${PRJ}_INCLUDE_DIR}"
-      )
-  endif()
+  set_target_properties(xpro::rapidjson PROPERTIES
+    INTERFACE_INCLUDE_DIRECTORIES "${XP_ROOTDIR}/include/${prj}_@VER@"
+    )
 endif()
-set(reqVars ${PRJ}_VER ${PRJ}_INCLUDE_DIR)
+set(reqVars ${PRJ}_VER)
 include(FindPackageHandleStandardArgs)
 find_package_handle_standard_args(${prj} REQUIRED_VARS ${reqVars})
 mark_as_advanced(${reqVars})


replace file(copy by cmake -E copy

replace file(copy by cmake -E copy

--- tools/cmake/mbed_set_post_build.cmake
+++ tools/cmake/mbed_set_post_build.cmake
@@ -88,11 +88,20 @@
     # executable suffix for all toolchains as CMake hardcodes the name of the
     # diagnostic output file for some toolchains.

-    # COPY_FILE could be used with cmake >=3.21
-    file(COPY_FILE
-            "${CMAKE_CURRENT_BINARY_DIR}/${target}${CMAKE_EXECUTABLE_SUFFIX}.map"
-            "${CMAKE_CURRENT_BINARY_DIR}/${target}${CMAKE_EXECUTABLE_SUFFIX}.map.old"
-            RESULT 0)
+    # copy mapfile .map to .map.old for ram/rom statistics diff in memap.py
+    if(EXISTS ${CMAKE_CURRENT_BINARY_DIR}/${target}${CMAKE_EXECUTABLE_SUFFIX}.map)
+        add_custom_command(
+            TARGET
+                ${target}
+            PRE_BUILD
+            COMMAND
+                ${CMAKE_COMMAND} -E rename "${CMAKE_CURRENT_BINARY_DIR}/${target}${CMAKE_EXECUTABLE_SUFFIX}.map" "${CMAKE_CURRENT_BINARY_DIR}/${target}${CMAKE_EXECUTABLE_SUFFIX}.map.old"
+            COMMENT
+                "executable:"
+            VERBATIM
+        )
+    endif()
+
     mbed_configure_memory_map(${target} "${CMAKE_CURRENT_BINARY_DIR}/${target}${CMAKE_EXECUTABLE_SUFFIX}.map")
     mbed_validate_application_profile(${target})
     mbed_generate_bin_hex(${target})


Fix luajit build issues on OSX + refactoring

Pass sysroot on OSX.
Make the code in luajit.cmake a bit more sane and straightforward.

--- cmake/luajit.cmake
+++ cmake/luajit.cmake
@@ -129,27 +129,50 @@
 message (STATUS "Use LuaJIT library: ${LUAJIT_LIB}")

 macro(luajit_build)
-    set (luajit_buildoptions BUILDMODE=static)
-    set (luajit_copt "")
-    set (luajit_xcflags "")
+    # Cmake rules concerning strings and lists of strings are weird.
+    #   set (foo "1 2 3") defines a string, while
+    #   set (foo 1 2 3) defines a list.
+    # Use separate_arguments() to turn a string into a list (splits at ws).
+    # It appears that variable expansion rules are context-dependent.
+    # With the current arrangement add_custom_command()
+    # does the right thing. We can even handle pathnames with
+    # spaces though a path with an embeded semicolon or a quotation mark
+    # will most certainly wreak havok.
+    #
+    # This stuff is extremely fragile, proceed with caution.
+    set (luajit_cflags ${CMAKE_C_FLAGS})
+        separate_arguments(luajit_cflags)
+    set (luajut_ldflags ${CMAKE_STATIC_LINKER_FLAGS})
+        separate_arguments(luajit_ldflags)
+    # Use external unwind on all platforms.
+    set (luajit_xcflags "-DLUAJIT_UNWIND_EXTERNAL=1")
+    # We are consciously ommiting debug info in RelWithDebugInfo mode
     if (${CMAKE_BUILD_TYPE} STREQUAL "Debug")
-        set (luajit_buildoptions ${luajit_buildoptions} CCDEBUG=${CC_DEBUG_OPT})
-        set (luajit_copt ${luajit_copt} -O1)
+        set (luajit_ccopt -O0)
+        if (CC_HAS_GGDB)
+            set (luajit_ccdebug -g -ggdb)
+        else ()
+            set (luajit_ccdebug -g)
+        endif ()
         set (luajit_xcflags ${luajit_xcflags}
             -DLUA_USE_APICHECK -DLUA_USE_ASSERT)
     else ()
-        set (luajit_copt ${luajit_copt} -O2)
+        set (luajit_cсopt -O2)
+        set (luajit_ccdbebug "")
+    endif()
+    # Pass sysroot settings on OSX
+    if (NOT "${CMAKE_OSX_SYSROOT}" STREQUAL "")
+        set (luajit_cflags ${luajit_cflags} ${CMAKE_C_SYSROOT_FLAG} ${CMAKE_OSX_SYSROOT})
+        set (luajit_ldflags ${luajit_ldlags} ${CMAKE_C_SYSROOT_FLAG} ${CMAKE_OSX_SYSROOT})
     endif()
     if (ENABLE_VALGRIND)
         set (luajit_xcflags ${luajit_xcflags}
             -DLUAJIT_USE_VALGRIND -DLUAJIT_USE_SYSMALLOC)
     endif()
-    set (luajit_target_cc "${CMAKE_C_COMPILER} ${CMAKE_C_COMPILER_ARG1} ${CMAKE_C_FLAGS}")
-    # Use external unwind on all platforms.
-    set (luajit_target_cc "${luajit_target_cc} -DLUAJIT_UNWIND_EXTERNAL=1")
+    set (luajit_target_cc ${CMAKE_C_COMPILER} ${CMAKE_C_COMPILER_ARG1})
     if(${CMAKE_SYSTEM_PROCESSOR} STREQUAL ${CMAKE_HOST_SYSTEM_PROCESSOR})
         # Regular mode - use CMake compiler for building host utils.
-        set (luajit_host_cc ${CMAKE_C_COMPILER} ${CMAKE_C_COMPILER_ARG1} ${CMAKE_C_FLAGS})
+        set (luajit_host_cc ${CMAKE_C_COMPILER} ${CMAKE_C_COMPILER_ARG1})
     else()
         # Crosscompile mode - use a host CC compiler for building host utils.
         # Since CMake does not support cross compilation properly
@@ -161,20 +184,16 @@
         # The host compiler must have same pointer size as the target compiler.
         set (luajit_host_cc "${luajit_host_cc} -m32")
     endif()
-    set(luajit_ldflags "${CMAKE_SHARED_LINKER_FLAGS}")
-    separate_arguments(luajit_copt)
-    separate_arguments(luajit_ldflags)
-    separate_arguments(luajit_host_cc)
-    separate_arguments(luajit_target_cc)
-    set (luajit_buildoptions ${luajit_buildoptions}
-        CFLAGS=""
-        CXXFLAGS=""
+    set (luajit_buildoptions
+        BUILDMODE=static
+        CC="${luajit_host_cc}"
+        CFLAGS="${luajit_cflags}"
+        LDFLAGS="${luajit_ldflags}"
+        CCOPT="${luajit_ccopt}"
+        CCDEBUG="${luajit_ccdebug}"
         XCFLAGS="${luajit_xcflags}"
-        CC="${luajit_host_cc}"
-        HOST_CC="${luajit_host_cc}"
         TARGET_CC="${luajit_target_cc}"
-        CCOPT="${luajit_copt}")
-    set (luajit_buildoptions ${luajit_buildoptions} Q='' LDFLAGS="${luajit_ldflags}")
+        Q='')
     if (${PROJECT_BINARY_DIR} STREQUAL ${PROJECT_SOURCE_DIR})
         add_custom_command(OUTPUT ${PROJECT_BINARY_DIR}/third_party/luajit/src/libluajit.a
             WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/third_party/luajit


Minor adjustment for Windows after making use of CMAKE_SHARED_LIBRARY_PREFIX in plugin.cmake.

--- cmake/plugin.cmake
+++ cmake/plugin.cmake
@@ -61,9 +61,7 @@
     #       However, this is not common practice on Windows, so...

     IF(WIN32)
-        SET_TARGET_PROPERTIES(${PROJECT_NAME}
-            PROPERTIES PREFIX ""
-        )
+        SET(CMAKE_SHARED_LIBRARY_PREFIX)
     ENDIF()

     SET_TARGET_PROPERTIES(${PROJECT_NAME}


Can't just move the plugins, since on Linux (and I imagine Mac OS X), the .so file contains import information and may therefore (e.g. in the case of the Core plugin) be required to build a plugin (e.g. the Viewer plugin), so...

--- cmake/plugin.cmake
+++ cmake/plugin.cmake
@@ -89,7 +89,7 @@
     ENDIF()

     ADD_CUSTOM_COMMAND(TARGET ${PROJECT_NAME} POST_BUILD
-                       COMMAND ${CMAKE_COMMAND} -E rename ${ORIG_PLUGINS_DIR}/${PLUGIN_FILENAME} ${DEST_PLUGINS_DIR}/${PLUGIN_FILENAME})
+                       COMMAND ${CMAKE_COMMAND} -E copy ${ORIG_PLUGINS_DIR}/${PLUGIN_FILENAME} ${DEST_PLUGINS_DIR}/${PLUGIN_FILENAME})
 ENDMACRO()

 MACRO(PACKAGE_PLUGIN)


Ensure aio is available on Linux.

Ensure aio is available on Linux.

--- cmake/build_configurations/mysql_release.cmake
+++ cmake/build_configurations/mysql_release.cmake
@@ -103,6 +103,16 @@
   ENDIF()

   OPTION(WITH_PIC "" ON) # Why?
+
+  # Ensure aio is available on Linux (required by InnoDB)
+  IF(CMAKE_SYSTEM_NAME STREQUAL "Linux")
+    CHECK_INCLUDE_FILES(libaio.h HAVE_LIBAIO_H)
+    CHECK_LIBRARY_EXISTS(aio io_queue_init "" HAVE_LIBAIO)
+    IF(NOT HAVE_LIBAIO_H OR NOT HAVE_LIBAIO)
+      MESSAGE(FATAL_ERROR "aio is required on Linux")
+    ENDIF()
+  ENDIF()
+
 ENDIF()


Doxygen: Typo fix

Doxygen: Typo fix

--- tools/doxygen/doxygen.cmake
+++ tools/doxygen/doxygen.cmake
@@ -260,7 +260,7 @@
     find_package(PythonInterp QUIET)    # sets, PYTHONINTERP_FOUND PYTHON_EXECUTABLE

     if(NOT ${DOXYGEN_FOUND})
-        ivw_message(WARN "Tried to create doxygen project, but doxygen was not found")
+        ivw_message(WARNING "Tried to create doxygen project, but doxygen was not found")
         return()
     endif()


cmake/modules/FindVIGRA.cmake: Get the directory of vigranumpycore.

--- cmake/modules/FindVIGRA.cmake
+++ cmake/modules/FindVIGRA.cmake
@@ -32,7 +32,7 @@
                             OUTPUT_STRIP_TRAILING_WHITESPACE)

 IF(NOT VIGRA_VIGRANUMPYCORE_LIBRARY_NOT_FOUND)
-    SET( VIGRANUMPY_SITEPACKAGE_DIR ${VIGRA_VIGRANUMPYCORE_LIBRARY} CACHE PATH "Path to Vigra's vigranumpycore library.")
+    GET_FILENAME_COMPONENT(VIGRANUMPY_SITEPACKAGE_DIR ${VIGRA_VIGRANUMPYCORE_LIBRARY} DIRECTORY)

     MESSAGE(STATUS "Found VIGRA")
     MESSAGE(STATUS "  > includes:                 ${VIGRA_INCLUDE_DIR}")


Update coverage settings for gcc

Update coverage settings for gcc

--- source/cmake_modules/CompilationFlags.cmake
+++ source/cmake_modules/CompilationFlags.cmake
@@ -16,7 +16,7 @@
     set(CMAKE_GNUCXX_WARN_FLAGS "-Wall -Wextra -Woverloaded-virtual -Wundef -pedantic")
     set(CMAKE_GNUCXX_COMMON_FLAGS "-std=c++0x -rdynamic -g")
     set(CMAKE_CXX_FLAGS "${CMAKE_GNUCXX_COMMON_FLAGS} ${CMAKE_GNUCXX_WARN_FLAGS}")
-    set(CMAKE_CXX_FLAGS_PROFILE "${CMAKE_CXX_FLAG} --coverage -g")
+    set(CMAKE_CXX_FLAGS_PROFILE "${CMAKE_CXX_FLAG} --coverage -fprofile-arcs -ftest-coverage  -g")
     set(CMAKE_EXE_LINKER_FLAGS_PROFILE "${CMAKE_EXE_LINKER_FLAGS} --coverage")
 endif(CMAKE_COMPILER_IS_GNUCXX)


CMake error - need to evaluate the newest compiler variable.

--- tools/VoltDBCompilation.cmake
+++ tools/VoltDBCompilation.cmake
@@ -134,7 +134,7 @@
 #
 # Note: Update this when adding a new compiler support.
 #
-SET (VOLTDB_COMPILER_NEWEST VOLTDB_COMPILER_U18p04)
+SET (VOLTDB_COMPILER_NEWEST ${VOLTDB_COMPILER_U18p04})
 #
 #
 #


Use absolute path for template batch file.

--- BlueBerry/CMake/FunctionCreateBlueBerryApplication.cmake
+++ BlueBerry/CMake/FunctionCreateBlueBerryApplication.cmake
@@ -168,7 +168,7 @@
 # Create batch files for Windows platforms
 if(WIN32)
   set(template_name "start${_APP_NAME}.bat.in")
-  if(EXISTS ${template_name})
+  if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${template_name}")
     foreach(BUILD_TYPE debug release)
       mitkFunctionCreateWindowsBatchScript(${template_name}
         ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/start${_APP_NAME}_${BUILD_TYPE}.bat


[CMake] [darwin] Refactor darwin_read_exclude_file to be reusable. NFC.

Rename darwin_read_exclude_file to more generic darwin_read_list_from_file, and make it take the file path instead of constructing it so it can be reused more freely.

git-svn-id: c199f293c43da69278bea8e88f92242bf3aa95f7@248635 91177308-0d34-0410-b5e6-96231b3b80d8

--- cmake/Modules/CompilerRTDarwinUtils.cmake
+++ cmake/Modules/CompilerRTDarwinUtils.cmake
@@ -103,11 +103,11 @@
 set(DARWIN_EXCLUDE_DIR ${CMAKE_SOURCE_DIR}/lib/builtins/Darwin-excludes)

 # Read and process the exclude file into a list of symbols
-function(darwin_read_exclude_file output_var file)
-  if(EXISTS ${DARWIN_EXCLUDE_DIR}/${file}.txt)
-    file(READ ${DARWIN_EXCLUDE_DIR}/${file}.txt ${file}_EXCLUDES)
-    string(REPLACE "\n" ";" ${file}_EXCLUDES ${${file}_EXCLUDES})
-    set(${output_var} ${${file}_EXCLUDES} PARENT_SCOPE)
+function(darwin_read_list_from_file output_var file)
+  if(EXISTS ${file})
+    file(READ ${file} EXCLUDES)
+    string(REPLACE "\n" ";" EXCLUDES ${EXCLUDES})
+    set(${output_var} ${EXCLUDES} PARENT_SCOPE)
   endif()
 endfunction()

@@ -124,8 +124,10 @@
     message(FATAL_ERROR "Must specify OS and ARCH to darwin_find_excluded_builtins_list!")
   endif()

-  darwin_read_exclude_file(${LIB_OS}_BUILTINS ${LIB_OS})
-  darwin_read_exclude_file(${LIB_OS}_${LIB_ARCH}_BASE_BUILTINS ${LIB_OS}-${LIB_ARCH})
+  darwin_read_list_from_file(${LIB_OS}_BUILTINS
+    ${DARWIN_EXCLUDE_DIR}/${LIB_OS}.txt)
+  darwin_read_list_from_file(${LIB_OS}_${LIB_ARCH}_BASE_BUILTINS
+    ${DARWIN_EXCLUDE_DIR}/${LIB_OS}-${LIB_ARCH}.txt)

   if(LIB_MIN_VERSION)
     file(GLOB builtin_lists ${DARWIN_EXCLUDE_DIR}/${LIB_OS}*-${LIB_ARCH}.txt)
@@ -141,7 +143,8 @@
     endforeach()

     if(smallest_version)
-      darwin_read_exclude_file(${LIB_ARCH}_${LIB_OS}_BUILTINS ${LIB_OS}${smallest_version}-${LIB_ARCH})
+      darwin_read_list_from_file(${LIB_ARCH}_${LIB_OS}_BUILTINS
+        ${DARWIN_EXCLUDE_DIR}/${LIB_OS}${smallest_version}-${LIB_ARCH}.txt)
     endif()
   endif()


add endif to python environment in .csh

add endif to python environment in .csh


CMake: Added Static postfix to libs in static build

--- CMake/Utils/OgreInstall.cmake
+++ CMake/Utils/OgreInstall.cmake
@@ -11,10 +11,16 @@
 endif ()

 function(ogre_install_lib LIBNAME)
+  # add static prefix, if compiling static version
+  if (OGRE_STATIC)
+    set_target_properties(${LIBNAME} PROPERTIES
+      OUTPUT_NAME ${LIBNAME}Static
+    )
+  endif ()
   install(TARGETS ${LIBNAME}
     RUNTIME DESTINATION "bin${OGRE_RELEASE_PATH}" CONFIGURATIONS Release MinSizeRel RelWithDebInfo
-	LIBRARY DESTINATION "lib" CONFIGURATIONS Release MinSizeRel RelWithDebInfo
-	ARCHIVE DESTINATION "lib" CONFIGURATIONS Release MinSizeRel RelWithDebInfo
+	LIBRARY DESTINATION "lib" CONFIGURATIONS Release MinSizeRel RelWithDebInfo None
+	ARCHIVE DESTINATION "lib" CONFIGURATIONS Release MinSizeRel RelWithDebInfo None
   )
   install(TARGETS ${LIBNAME}
     RUNTIME DESTINATION "bin${OGRE_DEBUG_PATH}" CONFIGURATIONS DEBUG
@@ -24,10 +30,16 @@
 endfunction(ogre_install_lib)

 function(ogre_install_plugin PLUGINNAME)
+  # add static prefix, if compiling static version
+  if (OGRE_STATIC)
+    set_target_properties(${PLUGINNAME} PROPERTIES
+      OUTPUT_NAME ${PLUGINNAME}Static
+    )
+  endif ()
   install(TARGETS ${PLUGINNAME}
     RUNTIME DESTINATION "bin${OGRE_RELEASE_PATH}" CONFIGURATIONS Release MinSizeRel RelWithDebInfo
-	LIBRARY DESTINATION "lib${OGRE_PLUGIN_PATH}" CONFIGURATIONS Release MinSizeRel RelWithDebInfo
-	ARCHIVE DESTINATION "lib${OGRE_PLUGIN_PATH}" CONFIGURATIONS Release MinSizeRel RelWithDebInfo
+	LIBRARY DESTINATION "lib${OGRE_PLUGIN_PATH}" CONFIGURATIONS Release MinSizeRel RelWithDebInfo None
+	ARCHIVE DESTINATION "lib${OGRE_PLUGIN_PATH}" CONFIGURATIONS Release MinSizeRel RelWithDebInfo None
   )
   install(TARGETS ${PLUGINNAME}
     RUNTIME DESTINATION "bin${OGRE_DEBUG_PATH}" CONFIGURATIONS DEBUG
@@ -39,7 +51,7 @@
 function(ogre_install_sample SAMPLENAME)
   if (OGRE_INSTALL_SAMPLES)
     install(TARGETS ${SAMPLENAME}
-      RUNTIME DESTINATION "bin${OGRE_RELEASE_PATH}" CONFIGURATIONS Release MinSizeRel RelWithDebInfo OPTIONAL
+      RUNTIME DESTINATION "bin${OGRE_RELEASE_PATH}" CONFIGURATIONS Release MinSizeRel RelWithDebInfo None OPTIONAL
     )
     install(TARGETS ${SAMPLENAME}
       RUNTIME DESTINATION "bin${OGRE_DEBUG_PATH}" CONFIGURATIONS DEBUG OPTIONAL


Fix refresh frame problem on Windows

Fix refresh frame problem on Windows

--- CMake/Superbuild/External_Slicer.cmake
+++ CMake/Superbuild/External_Slicer.cmake
@@ -79,7 +79,7 @@
     BINARY_DIR ${${proj}_DIR}
     PREFIX ${proj}${ep_suffix}
     GIT_REPOSITORY "git://public.kitware.com/Bender/Slicer.git"
-    GIT_TAG "99050b1f862bcb4f7ccb69690bf0c950940c7139"
+    GIT_TAG "bca866c01d7cd87e2d91ba566e13e253c8086dbd"
     ${bender_external_update}
     INSTALL_COMMAND ""
     CMAKE_GENERATOR ${gen}


STYLE: Update External_Slicer.cmake to be consistent across projects.

This will facilitate the maintenance of the build system.

--- CMake/Superbuild/External_Slicer.cmake
+++ CMake/Superbuild/External_Slicer.cmake
@@ -29,26 +29,30 @@
   message(FATAL_ERROR "${proj}_DIR variable is defined but corresponds to nonexistent directory")
 endif()

-if(NOT DEFINED ${proj}_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
+if(NOT DEFINED ${proj}_DIR)

   if(NOT DEFINED git_protocol)
       set(git_protocol "git")
   endif()

-  set(${proj}_INTERNAL_DEPENDENCIES_LIST ${APPLICATION_NAME} TubeTK Gutenberg)
+  set(${proj}_DIR ${CMAKE_BINARY_DIR}/S-bld)
+  set(${proj}_PREFIX ${CMAKE_BINARY_DIR}/${proj}-prefix)
+  set(${proj}_INTERNAL_DEPENDENCIES_LIST ${APPLICATION_NAME}
+    # List here additional external projects
+    TubeTK
+    Gutenberg
+    )

   find_package(Qt4 REQUIRED)

   get_property(${APPLICATION_NAME}_MODULES GLOBAL PROPERTY ${APPLICATION_NAME}_MODULES)
-  set(${proj}_DIR ${CMAKE_BINARY_DIR}/S-bld)
-
-  set(Slicer_QTLOADABLEMODULES_DISABLED
+  set(${proj}_QTLOADABLEMODULES_DISABLED
     SlicerWelcome
     )
-  set(Slicer_QTSCRIPTEDMODULES_DISABLED
+  set(${proj}_QTSCRIPTEDMODULES_DISABLED
     Endoscopy
     )
-  set(Slicer_CLIMODULES_DISABLED
+  set(${proj}_CLIMODULES_DISABLED
     ExecutionModelTour
     FiberTractMeasurements
     )
@@ -76,57 +80,62 @@

   ExternalProject_Add(${proj}
     ${${proj}_EP_ARGS}
-    SOURCE_DIR ${CMAKE_BINARY_DIR}/${proj}
+    SOURCE_DIR ${${proj}_SOURCE_DIR}
     BINARY_DIR ${${proj}_DIR}
-    PREFIX ${proj}${ep_suffix}
+    PREFIX ${${proj}_PREFIX}
     INSTALL_COMMAND ""
     #${${APPLICATION_NAME}_external_update}
     CMAKE_CACHE_ARGS
-      -DCMAKE_CXX_FLAGS:STRING=${ep_common_cxx_flags}
-      -DCMAKE_C_FLAGS:STRING=${ep_common_c_flags}
+      # Compile options
       -DADDITIONAL_C_FLAGS:STRING=${ADDITIONAL_C_FLAGS}
       -DADDITIONAL_CXX_FLAGS:STRING=${ADDITIONAL_CXX_FLAGS}
+      -DCMAKE_C_COMPILER:FILEPATH=${CMAKE_C_COMPILER}
+      -DCMAKE_C_FLAGS:STRING=${ep_common_c_flags}
+      -DCMAKE_CXX_COMPILER:FILEPATH=${CMAKE_CXX_COMPILER}
+      -DCMAKE_CXX_FLAGS:STRING=${ep_common_cxx_flags}
+      -DCMAKE_EXE_LINKER_FLAGS:STRING=${CMAKE_EXE_LINKER_FLAGS}
+      -DCMAKE_SHARED_LINKER_FLAGS:STRING=${CMAKE_SHARED_LINKER_FLAGS}
       -DBUILD_TESTING:BOOL=OFF
+      # Install paths
       -D${proj}_INSTALL_BIN_DIR:STRING=${${APPLICATION_NAME}_INSTALL_BIN_DIR}
       -D${proj}_INSTALL_LIB_DIR:STRING=${${APPLICATION_NAME}_INSTALL_BIN_DIR}
-      -D${proj}_USE_GIT_PROTOCOL:BOOL=${${APPLICATION_NAME}_USE_GIT_PROTOCOL}
       # Qt
-      -DSlicer_ADDITIONAL_REQUIRED_QT_MODULES:STRING=QTDECLARATIVE;QTSCRIPT
       -DQT_QMAKE_EXECUTABLE:FILEPATH=${QT_QMAKE_EXECUTABLE}
-      -DSlicer_REQUIRED_QT_VERSION:STRING=${QT_VERSION_MAJOR}.${QT_VERSION_MINOR}.${QT_VERSION_PATCH}
+      -D${proj}_REQUIRED_QT_VERSION:STRING=${QT_VERSION_MAJOR}.${QT_VERSION_MINOR}.${QT_VERSION_PATCH}
+      -D${proj}_ADDITIONAL_REQUIRED_QT_MODULES:STRING=QTDECLARATIVE;QTSCRIPT
       # External projects
       -DEXTERNAL_PROJECT_ADDITIONAL_DIR:PATH=${${APPLICATION_NAME}_SUPERBUILD_DIR}
-      -DSlicer_ADDITIONAL_DEPENDENCIES:STRING=${${proj}_INTERNAL_DEPENDENCIES_LIST}
+      -D${proj}_ADDITIONAL_DEPENDENCIES:STRING=${${proj}_INTERNAL_DEPENDENCIES_LIST}
+      -D${proj}_USE_GIT_PROTOCOL:BOOL=${${APPLICATION_NAME}_USE_GIT_PROTOCOL}
+      -D${proj}_DIR:PATH=${${proj}_DIR} # Required by External_<APPLICATION_NAME>.cmake
       # Application
       -D${APPLICATION_NAME}_SOURCE_DIR:PATH=${${APPLICATION_NAME}_SOURCE_DIR} # needed by External_${APPLICATION_NAME}.cmake
-      -DSlicer_MAIN_PROJECT:STRING=${APPLICATION_NAME}App
       -D${APPLICATION_NAME}App_APPLICATION_NAME:STRING=${APPLICATION_NAME}
-      -DSlicer_APPLICATIONS_DIR:PATH=${${APPLICATION_NAME}_SOURCE_DIR}/Applications
+      -D${proj}_APPLICATIONS_DIR:PATH=${${APPLICATION_NAME}_SOURCE_DIR}/Applications
+      -D${proj}_MAIN_PROJECT:STRING=${APPLICATION_NAME}App
       # Slicer features
-      -DSlicer_BUILD_DICOM_SUPPORT:BOOL=ON
-      -DSlicer_BUILD_DIFFUSION_SUPPORT:BOOL=OFF
-      -DSlicer_BUILD_EXTENSIONMANAGER_SUPPORT:BOOL=OFF
-      -DSlicer_BUILD_MULTIVOLUME_SUPPORT:BOOL=OFF
-      -DSlicer_USE_OpenIGTLink:BOOL=OFF
-      -DSlicer_USE_QtTesting:BOOL=OFF
-      -DSlicer_USE_PYTHONQT:BOOL=ON
-      -DSlicer_USE_PYTHONQT_WITH_TCL:BOOL=OFF
-      -DSlicer_USE_SimpleITK:BOOL=OFF
-      -DSlicer_USE_NUMPY:BOOL=OFF
+      -D${proj}_BUILD_DICOM_SUPPORT:BOOL=ON
+      -D${proj}_BUILD_DIFFUSION_SUPPORT:BOOL=OFF
+      -D${proj}_BUILD_EXTENSIONMANAGER_SUPPORT:BOOL=OFF
+      -D${proj}_BUILD_MULTIVOLUME_SUPPORT:BOOL=OFF
+      -D${proj}_USE_NUMPY:BOOL=ON
+      -D${proj}_USE_OpenIGTLink:BOOL=OFF
+      -D${proj}_USE_PYTHONQT_WITH_TCL:BOOL=OFF
+      -D${proj}_USE_PYTHONQT:BOOL=ON
+      -D${proj}_USE_QtTesting:BOOL=OFF
+      -D${proj}_USE_SimpleITK:BOOL=OFF
       # Slicer built-in modules
-      -DSlicer_CLIMODULES_DISABLED:STRING=${Slicer_CLIMODULES_DISABLED}
-      -DSlicer_QTLOADABLEMODULES_DISABLED:STRING=${Slicer_QTLOADABLEMODULES_DISABLED}
-      -DSlicer_QTSCRIPTEDMODULES_DISABLED:STRING=${Slicer_QTSCRIPTEDMODULES_DISABLED}
+      -D${proj}_CLIMODULES_DISABLED:STRING=${${proj}_CLIMODULES_DISABLED}
+      -D${proj}_QTLOADABLEMODULES_DISABLED:STRING=${${proj}_QTLOADABLEMODULES_DISABLED}
+      -D${proj}_QTSCRIPTEDMODULES_DISABLED:STRING=${${proj}_QTSCRIPTEDMODULES_DISABLED}
       # Slicer remote modules
-      -DSlicer_BUILD_BRAINSTOOLS:BOOL=OFF
-      -DSlicer_BUILD_ChangeTrackerPy:BOOL=OFF
-      -DSlicer_BUILD_CompareVolumes:BOOL=OFF
-      -DSlicer_BUILD_EMSegment:BOOL=OFF
-      -DSlicer_BUILD_DataStore:BOOL=OFF
-      -DSlicer_BUILD_LandmarkRegistration:BOOL=OFF
-      -DSlicer_EXTENSION_SOURCE_DIRS:STRING=${${APPLICATION_NAME}_MODULES_IN_BUILD_ORDER}
-      # Required by External_<APPLICATION_NAME>.cmake
-      -DSlicer_DIR:PATH=${${proj}_DIR}
+      -D${proj}_BUILD_BRAINSTOOLS:BOOL=OFF
+      -D${proj}_BUILD_ChangeTrackerPy:BOOL=OFF
+      -D${proj}_BUILD_CompareVolumes:BOOL=OFF
+      -D${proj}_BUILD_DataStore:BOOL=OFF
+      -D${proj}_BUILD_EMSegment:BOOL=OFF
+      -D${proj}_BUILD_LandmarkRegistration:BOOL=OFF
+      -D${proj}_EXTENSION_SOURCE_DIRS:STRING=${${APPLICATION_NAME}_MODULES_IN_BUILD_ORDER}
       # Required by TubeTK modules
       -DSlicer_SOURCE_DIR:PATH=${Slicer_SOURCE_DIR}
       # Use VTKv6


blockedarray.cmake: Removed install step.

--- blockedarray.cmake
+++ blockedarray.cmake
@@ -39,8 +39,12 @@
         -DBoost_LIBRARY_DIRS=${BUILDEM_DIR}/lib
     	${blockedarray_SRC_DIR}

-    BUILD_COMMAND       ${BUILDEM_ENV_STRING} make
-    INSTALL_COMMAND     ${BUILDEM_ENV_STRING} make install
+    BUILD_COMMAND       ${BUILDEM_ENV_STRING} $(MAKE)
+
+    # blockedarray doesn't support a seperate install location.
+    # Its output .so is copied directly into the source tree and used from there.
+    ###INSTALL_COMMAND     ${BUILDEM_ENV_STRING} make install
+    INSTALL_COMMAND     ""
 )

 endif (NOT blockedarray_NAME)


vtkhdf5: Fix build error when building on system with glic >= 2.19

As described in [1], since _BSD_SOURCE has been deprecated,
_DEFAULT_SOURCE should now be used.

This commit fixes the following build error happening when buiding
on Ubuntu 14.04 LTS (with gcc (Ubuntu 4.8.2-19ubuntu1) 4.8.2,
GNU C Library (Ubuntu EGLIBC 2.19-0ubuntu6.5)):

$ make H5detect
[...]
/home/jcfr/Projects/Slicer-Release/VTKv6/ThirdParty/hdf5/vtkhdf5/src/H5detect.c:158:1: error: unknown type name ‘sigjmp_buf’
 static H5JMP_BUF jbuf_g;

[1] http://www.sourceware.org/ml/glibc-cvs/2014-q1/msg00252.html

Change-Id: I81c4f77f0f2c505f6b4f998a2a4c3f9b5bba1d5e

--- ThirdParty/hdf5/vtkhdf5/config/cmake/ConfigureChecks.cmake
+++ ThirdParty/hdf5/vtkhdf5/config/cmake/ConfigureChecks.cmake
@@ -440,7 +440,7 @@
   # POSIX feature information can be found in the gcc manual at:
   # http://www.gnu.org/s/libc/manual/html_node/Feature-Test-Macros.html
   set (HDF5_EXTRA_C_FLAGS -D_POSIX_C_SOURCE=199506L)
-  set (HDF5_EXTRA_FLAGS -D_BSD_SOURCE)
+  set (HDF5_EXTRA_FLAGS -D_DEFAULT_SOURCE -D_BSD_SOURCE)

   option (HDF5_ENABLE_LARGE_FILE "Enable support for large (64-bit) files on Linux." ON)
   if (HDF5_ENABLE_LARGE_FILE)


Update ITK superbuild version to 4.12.1

Update ITK superbuild version to 4.12.1

--- SuperBuild/External_ITK.cmake
+++ SuperBuild/External_ITK.cmake
@@ -47,7 +47,7 @@
 mark_as_advanced(ITK_GIT_REPOSITORY)
 sitk_legacy_naming(ITK_GIT_REPOSITORY ITK_REPOSITORY)

-set(ITK_GIT_TAG "v4.12.0" CACHE STRING "Tag in ITK git repo")
+set(ITK_GIT_TAG "v4.12.1" CACHE STRING "Tag in ITK git repo")
 mark_as_advanced(ITK_GIT_TAG)
 set(ITK_TAG_COMMAND GIT_TAG "${ITK_GIT_TAG}")


ENH: Update VTK version. Version 5 support is deprecated

DTIPrep no longer supports vtk version 5

--- SuperBuild/External_VTK.cmake
+++ SuperBuild/External_VTK.cmake
@@ -24,33 +24,7 @@
 set(extProjName VTK) #The find_package known name
 set(proj        VTK) #This local name

-
-#Setting VTK_VERSION_MAJOR to its default value if it has not been set before
-set(VTK_VERSION_MAJOR 5 CACHE STRING "Choose the expected VTK major version to build Slicer (5 or 6).")
-# Set the possible values of VTK major version for cmake-gui
-set_property(CACHE VTK_VERSION_MAJOR PROPERTY STRINGS "5" "6")
-if(NOT "${VTK_VERSION_MAJOR}" STREQUAL "5" AND NOT "${VTK_VERSION_MAJOR}" STREQUAL "6")
-  set(VTK_VERSION_MAJOR 5 CACHE STRING "Choose the expected VTK major version to build Slicer (5 or 6)." FORCE)
-  message(WARNING "Setting VTK_VERSION_MAJOR to '5' as an valid value was specified.")
-endif()
-
-set(USE_VTKv5 ON)
-set(USE_VTKv6 OFF)
-if(${VTK_VERSION_MAJOR} STREQUAL "6")
-  set(USE_VTKv5 OFF)
-  set(USE_VTKv6 ON)
-endif()
-
-if(USE_VTKv6)
-  set(${extProjName}_REQUIRED_VERSION "6.1")  #If a required version is necessary, then set this, else leave blank
-else()
-  set(${extProjName}_REQUIRED_VERSION "5.10")  #If a required version is necessary, then set this, else leave blank
-endif()
-
-# Sanity checks
-#if(DEFINED ${extProjName}_DIR AND NOT EXISTS ${${extProjName}_DIR})
-#  message(FATAL_ERROR "${extProjName}_DIR variable is defined but corresponds to non-existing directory (${${extProjName}_DIR})")
-#endif()
+set(${extProjName}_REQUIRED_VERSION "6.1")  #If a required version is necessary, then set this, else leave blank

 # Set dependency list
 set(${proj}_DEPENDENCIES "")
@@ -96,13 +70,9 @@

   set(VTK_QT_ARGS)
   if(${PRIMARY_PROJECT_NAME}_USE_QT)
-    if(USE_VTKv6)
-      set(VTK_QT_ARGS
-        -DModule_vtkGUISupportQt:BOOL=ON
-        )
-    else()
-      set(VTK_QT_ARGS)
-    endif()
+    set(VTK_QT_ARGS
+      -DModule_vtkGUISupportQt:BOOL=ON
+    )
     if(NOT APPLE)
       list(APPEND VTK_QT_ARGS
         #-DDESIRED_QT_VERSION:STRING=4 # Unused
@@ -190,13 +160,10 @@
       ${VTK_MAC_ARGS}
     )
   ### --- End Project specific additions
-if(USE_VTKv6)
+
   set(${proj}_GIT_TAG "v6.1.0")
   set(${proj}_REPOSITORY ${git_protocol}://vtk.org/VTK.git)
-else()
-  set(${proj}_REPOSITORY ${git_protocol}://github.com/BRAINSia/VTK.git)
-  set(${proj}_GIT_TAG "FixClangFailure_VTK5.10_release")
-endif()
+
   ExternalProject_Add(${proj}
     GIT_REPOSITORY ${${proj}_REPOSITORY}
     GIT_TAG ${${proj}_GIT_TAG}
@@ -226,15 +193,11 @@
     DEPENDERS configure
     COMMAND ${CMAKE_COMMAND}
     -DVTKSource=<SOURCE_DIR>
-    -DUSE_VTKv6=${USE_VTKv6}
+    -DUSE_VTKv6=ON
     -P ${VTKPatchScript}
     )

-if(USE_VTKv6)
-  set(${extProjName}_DIR ${CMAKE_BINARY_DIR}/${proj}-install/lib/cmake/vtk-6.1)
-else()
-  set(${extProjName}_DIR ${CMAKE_BINARY_DIR}/${proj}-install/lib/vtk-5.10)
-endif()
+set(${extProjName}_DIR ${CMAKE_BINARY_DIR}/${proj}-install/lib/cmake/vtk-6.1)

 else()
   if(${USE_SYSTEM_${extProjName}})


updates to .gitlab-ci.yml

updates to .gitlab-ci.yml

--- scripts/test.cmake
+++ scripts/test.cmake
@@ -63,12 +63,11 @@
   check_result()
 ENDMACRO()

-EXECUTE_PROCESS(
-  COMMAND "wget" "http://10.123.110.90/CDash"
-  WORKING_DIRECTORY ${TEST_MODELS_DIRECTORY}
-  RESULT_VARIABLE retcode)
-check_result()
-
+#EXECUTE_PROCESS(
+#  COMMAND "wget" "http://10.123.110.90/CDash"
+#  WORKING_DIRECTORY ${TEST_MODELS_DIRECTORY}
+#  RESULT_VARIABLE retcode)
+#check_result()

 # increase default output sizes for test outputs
 IF (NOT DEFINED CTEST_CUSTOM_MAXIMUM_PASSED_TEST_OUTPUT_SIZE)


Removing old cmake package descriptor

Removing old cmake package descriptor

--- tools/cmake/UNUMCommon.cmake
+++ tools/cmake/UNUMCommon.cmake
@@ -1,38 +0,0 @@
-############################
-#This configuration file defines some cmake variables:
-#UNUM_INCLUDE_DIRS: list of include directories for the universal library
-#UNUM_LIBRARIES: libraries needed for interfaces like umfpack and arprec, see below
-#UNUM_CXX_DEFINITIONS: definitions to enable the requested interfaces
-#UNUM_VERSION: version (current: 1)
-#UNUM_MINOR_VERSION: minor version
-#
-#supported components:
-#
-
-unset(UNUM_LIBRARIES )
-unset(UNUM_CXX_DEFINITIONS )
-unset(UNUM_INCLUDE_DIRS )
-
-if (MSVC)
-    add_definitions(/wd4522) # multiple assignment ops for single type, to be investigated further if avoidable
-endif()
-
-if (USE_ASSERTS)
-  list(APPEND UNUM_CXX_DEFINITIONS "-DUNUM_ASSERT_FOR_THROW")
-endif()
-
-if(EXISTS ${UNUM_DIR}/posit/posit.hpp)
-	list(APPEND UNUM_INCLUDE_DIRS "${UNUM_DIR}/posit")
-else()
-	list(APPEND UNUM_INCLUDE_DIRS "${UNUM_DIR}/../../include")
-endif(EXISTS ${UNUM_DIR}/posit/posit.hpp)
-
-macro(unum_check_cxx_compiler_flag FLAG RESULT)
-  # counts entirely on compiler's return code, maybe better to combine it with check_cxx_compiler_flag
-  file(WRITE "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/src.cxx" "int main() { return 0;}\n")
-  try_compile(${RESULT}
-    ${CMAKE_BINARY_DIR}
-    ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/src.cxx
-    COMPILE_DEFINITIONS ${FLAG})
-endmacro()
-


Install Cython with pip

Install Cython with pip

The install using easy_install seems to be broken, it tries to
pull down the wheel from PyPI.

--- projects/cython.cmake
+++ projects/cython.cmake
@@ -20,7 +20,6 @@
   BUILD_IN_SOURCE 1
   INSTALL_COMMAND
     ${install_command_env}
-  ${pv_python_executable} setup.py install
-     --prefix=<INSTALL_DIR>
+  ${python_pip_executable} install .
   ${process_environment}
 )


Automated merge with https://bitbucket.org/stinson_linden/viewer-development-havokai

--- indra/cmake/00-Common.cmake
+++ indra/cmake/00-Common.cmake
@@ -180,7 +180,7 @@
       # this stops us requiring a really recent glibc at runtime
       add_definitions(-fno-stack-protector)
       # linking can be very memory-hungry, especially the final viewer link
-      set(CMAKE_CXX_LINK_FLAGS "-Wl,--no-keep-memory,FORCE:MULTIPLE")
+      set(CMAKE_CXX_LINK_FLAGS "-Wl,--no-keep-memory")
     endif (NOT STANDALONE)
   endif (VIEWER)


tensorflow cmake setup fixes for windows

--- cmake/ExternalTensorflow.cmake
+++ cmake/ExternalTensorflow.cmake
@@ -19,9 +19,10 @@
                 ${CMAKE_COMMAND}
                 ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow/tensorflow/contrib/cmake/
                 -G${CMAKE_GENERATOR}
+		-Thost=x64
                 -DCMAKE_BUILD_TYPE:STRING=Release
                 -Dtensorflow_BUILD_PYTHON_BINDINGS=OFF
-                -Dtensorflow_ENABLE_SNAPPY_SUPPRT=OFF
+                -Dtensorflow_ENABLE_SNAPPY_SUPPORT=ON
                 -Dtensorflow_BUILD_CC_EXAMPLE=OFF
                 -Dtensorflow_BUILD_SHARED_LIB=ON
                 -Dtensorflow_BUILD_CONTRIB_KERNELS=OFF
@@ -34,7 +35,7 @@
         )
     list(APPEND LIBRARIES
         tensorflow.lib
-        libprotobuf.lib # For windows we need this protobuf static lib for some reason..
+        #libprotobuf.lib # For windows we need this protobuf static lib for some reason..
     )
 else(WIN32)
     # Use bazel to build tensorflow on linux


Updated tensorflow build to more compute capabilities on linux

--- cmake/ExternalTensorflow.cmake
+++ cmake/ExternalTensorflow.cmake
@@ -121,8 +121,10 @@
   set(FILENAME windows/tensorflow_2.4.0_msvc14.2.tar.xz)
   set(SHA 3a2c512e8cabc36b830e4b14204c74dc5b2d342cfea0b1a38e4f1cc28eb4c699)
 else()
-  set(FILENAME linux/tensorflow_2.4.0_glibc2.27.tar.xz)
-  set(SHA 32235fef0d0b236e19646d42164b92432692ffb653ff6bbb79783b9c5ef83b8c)
+  #set(FILENAME linux/tensorflow_2.4.0_glibc2.27.tar.xz)
+  #set(SHA 32235fef0d0b236e19646d42164b92432692ffb653ff6bbb79783b9c5ef83b8c)
+  set(FILENAME linux/tensorflow_full_2.4.0_glibc2.27.tar.xz)
+  set(SHA 92155ee33501e45c2ce1d8e8988758f259f338bea586c961c904c774009b22c1)
 endif()
 ExternalProject_Add(tensorflow
         PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow


CTEST_OUTPUT_ON_FAILURE=1

--- cmake/MyPackageBootstrap.cmake
+++ cmake/MyPackageBootstrap.cmake
@@ -43,7 +43,13 @@
   IF (MYPACKAGE_DEBUG)
     MESSAGE (STATUS "[${PROJECT_NAME}-BOOTSTRAP-DEBUG] Creating target check")
   ENDIF ()
-  ADD_CUSTOM_TARGET (check COMMAND ${CMAKE_CTEST_COMMAND})
+  ADD_CUSTOM_TARGET(check
+            ${CMAKE_COMMAND} -E echo ----------------------------------
+    COMMAND ${CMAKE_COMMAND} -E echo Test command:
+    COMMAND ${CMAKE_COMMAND} -E echo ${CMAKE_CTEST_COMMAND} -C $<CONFIG>
+    COMMAND ${CMAKE_COMMAND} -E echo ----------------------------------
+    COMMAND ${CMAKE_COMMAND} -E env CTEST_OUTPUT_ON_FAILURE=1 ${CMAKE_CTEST_COMMAND} -C $<CONFIG>
+    )
   IF (MYPACKAGE_DEBUG)
     MESSAGE (STATUS "[${PROJECT_NAME}-BOOTSTRAP-DEBUG] Creating target man")
   ENDIF ()


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Modules/ThirdParty/KWSys/src/KWSys/kwsysDateStamp.cmake
+++ Modules/ThirdParty/KWSys/src/KWSys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 06)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   14)
+SET(KWSYS_DATE_STAMP_DAY   15)


replace tabs with spaces and made code more tidy

--- pch.cmake
+++ pch.cmake
@@ -86,7 +86,7 @@
 endmacro()

 function( filter_item filtered_item item )
-#    message( STATUS "Filtering ${item}" )
+   # message( STATUS "Filtering ${item}" )
     set(append_item true)
     if( ${item} MATCHES ".*COMPILE_LANGUAGE.*" )
         if( ${item} MATCHES ".*\\\$<\\\$<COMPILE_LANGUAGE:CXX>:(.*)>$")
@@ -109,174 +109,174 @@
     endif()
     if( ${append_item} )
         set( ${filtered_item} ${item} PARENT_SCOPE )
-#        message( STATUS "    -> filtered to ${item}" )
+       # message( STATUS "    -> filtered to ${item}" )
     else()
         unset( ${filtered_item} PARENT_SCOPE )
-#        message( STATUS "    -> filtered out" )
+       # message( STATUS "    -> filtered out" )
     endif()
 endfunction()

-MACRO(ADD_PRECOMPILED_HEADER _targetName _input)
-  GET_FILENAME_COMPONENT(_inputWe ${_input} NAME_WE)
-  SET(pch_source ${_inputWe}.cpp)
-
-  set( PCH_LOCAL_DEPENDS "")
-  SET(FORCEINCLUDE OFF)
-
-  FOREACH(arg ${ARGN})
-    IF(arg MATCHES FORCEINCLUDE)
-      SET(FORCEINCLUDE ON)
-    ELSE()
-      LIST(APPEND PCH_LOCAL_DEPENDS ${arg})
-    ENDIF()
-  ENDFOREACH(arg)
-
-  IF(MSVC)
-    GET_TARGET_PROPERTY(sources ${_targetName} SOURCES)
-	GET_FILENAME_COMPONENT(PCH_NAME ${_input} NAME)
-    SET(_sourceFound FALSE)
-    FOREACH(_source ${sources})
-      SET(PCH_COMPILE_FLAGS "")
-      IF(_source MATCHES \\.\(cc|cxx|cpp\)$)
-	GET_FILENAME_COMPONENT(_sourceWe ${_source} NAME_WE)
-	IF(_sourceWe STREQUAL ${_inputWe})
-	  SET(PCH_COMPILE_FLAGS "${PCH_COMPILE_FLAGS} /Yc${PCH_NAME}")
-	  SET(_sourceFound TRUE)
-	ELSE(_sourceWe STREQUAL ${_inputWe})
-	  SET(PCH_COMPILE_FLAGS "${PCH_COMPILE_FLAGS} /Yu${PCH_NAME}")
-	  IF(FORCEINCLUDE)
-	    SET(PCH_COMPILE_FLAGS "${PCH_COMPILE_FLAGS} /FI${PCH_NAME}")
-	  ENDIF(FORCEINCLUDE)
-	ENDIF(_sourceWe STREQUAL ${_inputWe})
-	SET_SOURCE_FILES_PROPERTIES(${_source} PROPERTIES COMPILE_FLAGS "${PCH_COMPILE_FLAGS}")
-      ENDIF(_source MATCHES \\.\(cc|cxx|cpp\)$)
-    ENDFOREACH()
-    IF(NOT _sourceFound)
-      MESSAGE(FATAL_ERROR "A source file for ${_input} was not found. Required for MSVC builds.")
-    ENDIF(NOT _sourceFound)
-  ENDIF(MSVC)
-
-  IF(CMAKE_COMPILER_IS_GNUCXX OR ${CMAKE_CXX_COMPILER_ID} MATCHES "Clang")
-    if(${CMAKE_GENERATOR} STREQUAL "Xcode")
-        set_target_properties(${_targetName} PROPERTIES XCODE_ATTRIBUTE_GCC_PREFIX_HEADER ${_input} XCODE_ATTRIBUTE_GCC_PRECOMPILE_PREFIX_HEADER "Yes")
-    else()
-        GET_FILENAME_COMPONENT(_name ${_input} NAME)
-        SET(GCH_PATH "${CMAKE_CURRENT_BINARY_DIR}/${_targetName}-pch" )
-        SET(_output "${GCH_PATH}/${_name}.gch")
-    #    SET(_output "${CMAKE_BINARY_DIR}/${_name}.gch")
-
-        string(REGEX REPLACE "[^a-zA-Z0-9]" "" OutputName ${_output})
-
-        if(NOT DEFINED ${OutputName}_CREATED)
-            # obtain optimization flags
-            STRING(TOUPPER "CMAKE_CXX_FLAGS_${CMAKE_BUILD_TYPE}" _flags_var_name)
-            SET(_compiler_FLAGS ${${_flags_var_name}})
-            # obtain all other flags
-            list(APPEND _compiler_FLAGS ${CMAKE_CXX_FLAGS})
-
-            # Obtain target dependencies flags (recursively)
-            set( visited "" )
-            set( depsCompileOptions "" )
-            set( depsCompileDefinitions "" )
-            set( depsIncludeDirectories "" )
-            set( depsSystemIncludeDirectories "" )
-            get_dependencies_compile_options( ${_targetName} depsCompileOptions depsCompileDefinitions depsIncludeDirectories depsSystemIncludeDirectories visited )
-#            message("Additional compile flags for ${_targetName}: ${targetCompileFlags}")
-
-            get_directory_property( _directory_flags INCLUDE_DIRECTORIES )
-            get_target_property( _target_include_dirs ${_targetName} INCLUDE_DIRECTORIES )
-            get_target_property( _target_interface_include_dirs ${_targetName} INTERFACE_INCLUDE_DIRECTORIES )
-            foreach( item ${_directory_flags} ${_target_include_dirs} ${_target_interface_include_dirs} ${depsIncludeDirectories} )
-                filter_item( filtered_item ${item} )
-                if( filtered_item )
-                    list( APPEND _compiler_FLAGS "-I${filtered_item}" )
+macro( ADD_PRECOMPILED_HEADER _targetName _input )
+    get_filename_component( _inputWe ${_input} NAME_WE )
+    set( pch_source ${_inputWe}.cpp )
+
+    set( PCH_LOCAL_DEPENDS "")
+    set( FORCEINCLUDE OFF )
+
+    foreach( arg ${ARGN} )
+        if( arg MATCHES FORCEINCLUDE )
+            set( FORCEINCLUDE ON )
+        else()
+            list( APPEND PCH_LOCAL_DEPENDS ${arg} )
+        endif()
+    endforeach()
+
+    if( MSVC )
+        get_target_property( sources ${_targetName} SOURCES )
+        get_filename_component( PCH_NAME ${_input} NAME )
+        set( _sourceFound FALSE )
+        foreach( _source ${sources} )
+            set( PCH_COMPILE_FLAGS "" )
+            if( _source MATCHES \\.\(cc|cxx|cpp\)$ )
+                get_filename_component( _sourceWe ${_source} NAME_WE )
+                if( _sourceWe STREQUAL ${_inputWe} )
+                    set( PCH_COMPILE_FLAGS "${PCH_COMPILE_FLAGS} /Yc${PCH_NAME}" )
+                    set( _sourceFound TRUE )
+                else( _sourceWe STREQUAL ${_inputWe} )
+                    set( PCH_COMPILE_FLAGS "${PCH_COMPILE_FLAGS} /Yu${PCH_NAME}" )
+                    if( FORCEINCLUDE )
+                        set( PCH_COMPILE_FLAGS "${PCH_COMPILE_FLAGS} /FI${PCH_NAME}" )
+                    endif( FORCEINCLUDE )
+                endif( _sourceWe STREQUAL ${_inputWe} )
+                set_source_files_properties( ${_source} PROPERTIES COMPILE_FLAGS "${PCH_COMPILE_FLAGS}" )
+            endif( _source MATCHES \\.\(cc|cxx|cpp\)$ )
+        endforeach()
+        if( NOT _sourceFound )
+            message( FATAL_ERROR "A source file for ${_input} was not found. Required for MSVC builds." )
+        endif( NOT _sourceFound )
+    endif(MSVC)
+
+    if( CMAKE_COMPILER_IS_GNUCXX OR ${CMAKE_CXX_COMPILER_ID} MATCHES "Clang" )
+        if( ${CMAKE_GENERATOR} STREQUAL "Xcode" )
+            set_target_properties(${_targetName} PROPERTIES XCODE_ATTRIBUTE_GCC_PREFIX_HEADER ${_input} XCODE_ATTRIBUTE_GCC_PRECOMPILE_PREFIX_HEADER "Yes")
+        else()
+            GET_FILENAME_COMPONENT(_name ${_input} NAME)
+            SET(GCH_PATH "${CMAKE_CURRENT_BINARY_DIR}/${_targetName}-pch" )
+            SET(_output "${GCH_PATH}/${_name}.gch")
+        #    SET(_output "${CMAKE_BINARY_DIR}/${_name}.gch")
+
+            string(REGEX REPLACE "[^a-zA-Z0-9]" "" OutputName ${_output})
+
+            if(NOT DEFINED ${OutputName}_CREATED)
+                # obtain optimization flags
+                STRING(TOUPPER "CMAKE_CXX_FLAGS_${CMAKE_BUILD_TYPE}" _flags_var_name)
+                SET(_compiler_FLAGS ${${_flags_var_name}})
+                # obtain all other flags
+                list(APPEND _compiler_FLAGS ${CMAKE_CXX_FLAGS})
+
+                # Obtain target dependencies flags (recursively)
+                set( visited "" )
+                set( depsCompileOptions "" )
+                set( depsCompileDefinitions "" )
+                set( depsIncludeDirectories "" )
+                set( depsSystemIncludeDirectories "" )
+                get_dependencies_compile_options( ${_targetName} depsCompileOptions depsCompileDefinitions depsIncludeDirectories depsSystemIncludeDirectories visited )
+    #            message("Additional compile flags for ${_targetName}: ${targetCompileFlags}")
+
+                get_directory_property( _directory_flags INCLUDE_DIRECTORIES )
+                get_target_property( _target_include_dirs ${_targetName} INCLUDE_DIRECTORIES )
+                get_target_property( _target_interface_include_dirs ${_targetName} INTERFACE_INCLUDE_DIRECTORIES )
+                foreach( item ${_directory_flags} ${_target_include_dirs} ${_target_interface_include_dirs} ${depsIncludeDirectories} )
+                    filter_item( filtered_item ${item} )
+                    if( filtered_item )
+                        list( APPEND _compiler_FLAGS "-I${filtered_item}" )
+                    endif()
+                endforeach()
+
+                get_target_property( _target_system_include_dirs ${_targetName} INTERFACE_SYSTEM_INCLUDE_DIRECTORIES )
+                foreach( item ${_target_system_include_dirs} ${depsSystemIncludeDirectories} )
+                    filter_item( filtered_item ${item} )
+                    if( filtered_item )
+                        list( APPEND _compiler_FLAGS "-isystem ${filtered_item}" )
+                    endif()
+                endforeach()
+
+                get_directory_property( _directory_flags COMPILE_DEFINITIONS )
+                get_target_property( _target_compile_definitions ${_targetName} COMPILE_DEFINITIONS )
+                foreach( def ${_directory_flags} ${_target_compile_definitions} ${depsCompileDefinitions} )
+                    filter_item( filtered_item ${def} )
+                    if( filtered_item )
+                        list( APPEND _compiler_FLAGS "-D${filtered_item}" )
+                    endif()
+                endforeach()
+
+                get_directory_property( _compile_options COMPILE_OPTIONS )
+                get_target_property( _target_compile_options ${_targetName} COMPILE_OPTIONS )
+                foreach( option ${_compile_options} ${_target_compile_options} ${depsCompileOptions} )
+                    filter_item( filtered_item ${option} )
+                    if( filtered_item )
+                        list(APPEND _compiler_FLAGS ${filtered_item})
+                    endif()
+                endforeach()
+
+    	    get_target_property( _target_pic ${_targetName} POSITION_INDEPENDENT_CODE )
+                if(_target_pic)
+                    list(APPEND _compiler_FLAGS "-fPIC")
+                endif()
+
+                if( ANDROID )
+                    list( APPEND _compiler_FLAGS "--sysroot=${CMAKE_SYSROOT}" )
+                    foreach( sid ${CMAKE_CXX_STANDARD_INCLUDE_DIRECTORIES} )
+                        list( APPEND _compiler_FLAGS "-isystem ${sid}" )
+                    endforeach()
+                    list( APPEND _compiler_FLAGS "-target ${CMAKE_CXX_COMPILER_TARGET} " )
+                endif()
+
+                if( APPLE AND CMAKE_OSX_DEPLOYMENT_TARGET )
+                    list(APPEND _compiler_FLAGS "-mmacosx-version-min=${CMAKE_OSX_DEPLOYMENT_TARGET}")
+                endif()
+
+                set(COMPILER ${CMAKE_CXX_COMPILER})
+                if(${COMPILER} MATCHES "ccache")
+                    string(STRIP ${CMAKE_CXX_COMPILER_ARG1} CARG1)
+                    set( COMPILER ${CARG1} )
+                endif()
+
+                list( REMOVE_DUPLICATES _compiler_FLAGS )
+
+                SEPARATE_ARGUMENTS(_compiler_FLAGS)
+
+                ADD_CUSTOM_COMMAND(
+                  OUTPUT ${_output}
+                  COMMAND ${CMAKE_COMMAND} -E remove ${_output}
+                  COMMAND ${COMPILER} -x c++-header ${_compiler_FLAGS} -o ${_output} ${_input}
+                  DEPENDS ${_input} ${PCH_LOCAL_DEPENDS}
+                  COMMENT "Building precompiled header for ${_targetName}"
+                  VERBATIM)
+                set(${OutputName}_CREATED true)
+                # set(${OutputName}_CREATED true PARENT_SCOPE)
+            endif()
+            add_custom_target(${_targetName}_PCH DEPENDS ${_output} SOURCES ${_input})
+
+            ## Implementation note:
+            ## We always build single PCH for target. However, some source files in target can have different compile flags.
+            ## A right thing to do (TM) would be to generate PCH for each group of files with same flags. However, we do not
+            ## do that. So, instead of including PCH globally on whole target, we will include PCH only on those sources that
+            ## do not already have specific flags.
+            ## Also, specific for C source files, we filter-out C sources with regex that matches only C++ files since
+            ## generator expression $<COMPILE_LANGUAGE:CXX> works only for target_compile_options function.
+            ##
+            ##                                                                         Nenad Miksa (28.02.2017.)
+
+            get_target_property( target_sources ${_targetName} SOURCES )
+            foreach( source ${target_sources} )
+                get_source_file_property( old_flags ${source} COMPILE_FLAGS )
+                if( NOT old_flags AND ${source} MATCHES ".*\\.c.+" )
+                    set_source_files_properties( "${source}" PROPERTIES COMPILE_FLAGS "-include ${GCH_PATH}/${PCH_NAME}.h -Winvalid-pch" )
                 endif()
             endforeach()
-
-            get_target_property( _target_system_include_dirs ${_targetName} INTERFACE_SYSTEM_INCLUDE_DIRECTORIES )
-            foreach( item ${_target_system_include_dirs} ${depsSystemIncludeDirectories} )
-                filter_item( filtered_item ${item} )
-                if( filtered_item )
-                    list( APPEND _compiler_FLAGS "-isystem ${filtered_item}" )
-                endif()
-            endforeach()
-
-            get_directory_property( _directory_flags COMPILE_DEFINITIONS )
-            get_target_property( _target_compile_definitions ${_targetName} COMPILE_DEFINITIONS )
-            foreach( def ${_directory_flags} ${_target_compile_definitions} ${depsCompileDefinitions} )
-                filter_item( filtered_item ${def} )
-                if( filtered_item )
-                    list( APPEND _compiler_FLAGS "-D${filtered_item}" )
-                endif()
-            endforeach()
-
-            get_directory_property( _compile_options COMPILE_OPTIONS )
-            get_target_property( _target_compile_options ${_targetName} COMPILE_OPTIONS )
-            foreach( option ${_compile_options} ${_target_compile_options} ${depsCompileOptions} )
-                filter_item( filtered_item ${option} )
-                if( filtered_item )
-                    list(APPEND _compiler_FLAGS ${filtered_item})
-                endif()
-            endforeach()
-
-	    get_target_property( _target_pic ${_targetName} POSITION_INDEPENDENT_CODE )
-            if(_target_pic)
-                list(APPEND _compiler_FLAGS "-fPIC")
-            endif()
-
-            if( ANDROID )
-                list( APPEND _compiler_FLAGS "--sysroot=${CMAKE_SYSROOT}" )
-                foreach( sid ${CMAKE_CXX_STANDARD_INCLUDE_DIRECTORIES} )
-                    list( APPEND _compiler_FLAGS "-isystem ${sid}" )
-                endforeach()
-                list( APPEND _compiler_FLAGS "-target ${CMAKE_CXX_COMPILER_TARGET} " )
-            endif()
-
-            if( APPLE AND CMAKE_OSX_DEPLOYMENT_TARGET )
-                list(APPEND _compiler_FLAGS "-mmacosx-version-min=${CMAKE_OSX_DEPLOYMENT_TARGET}")
-            endif()
-
-            set(COMPILER ${CMAKE_CXX_COMPILER})
-            if(${COMPILER} MATCHES "ccache")
-                string(STRIP ${CMAKE_CXX_COMPILER_ARG1} CARG1)
-                set( COMPILER ${CARG1} )
-            endif()
-
-            list( REMOVE_DUPLICATES _compiler_FLAGS )
-
-            SEPARATE_ARGUMENTS(_compiler_FLAGS)
-
-            ADD_CUSTOM_COMMAND(
-              OUTPUT ${_output}
-              COMMAND ${CMAKE_COMMAND} -E remove ${_output}
-              COMMAND ${COMPILER} -x c++-header ${_compiler_FLAGS} -o ${_output} ${_input}
-              DEPENDS ${_input} ${PCH_LOCAL_DEPENDS}
-              COMMENT "Building precompiled header for ${_targetName}"
-              VERBATIM)
-            set(${OutputName}_CREATED true)
-            # set(${OutputName}_CREATED true PARENT_SCOPE)
-        endif()
-        add_custom_target(${_targetName}_PCH DEPENDS ${_output} SOURCES ${_input})
-
-        ## Implementation note:
-        ## We always build single PCH for target. However, some source files in target can have different compile flags.
-        ## A right thing to do (TM) would be to generate PCH for each group of files with same flags. However, we do not
-        ## do that. So, instead of including PCH globally on whole target, we will include PCH only on those sources that
-        ## do not already have specific flags.
-        ## Also, specific for C source files, we filter-out C sources with regex that matches only C++ files since
-        ## generator expression $<COMPILE_LANGUAGE:CXX> works only for target_compile_options function.
-        ##
-        ##                                                                         Nenad Miksa (28.02.2017.)
-
-        get_target_property( target_sources ${_targetName} SOURCES )
-        foreach( source ${target_sources} )
-            get_source_file_property( old_flags ${source} COMPILE_FLAGS )
-            if( NOT old_flags AND ${source} MATCHES ".*\\.c.+" )
-                set_source_files_properties( "${source}" PROPERTIES COMPILE_FLAGS "-include ${GCH_PATH}/${PCH_NAME}.h -Winvalid-pch" )
-            endif()
-        endforeach()
-#        target_compile_options( ${_targetName} PRIVATE $<$<COMPILE_LANGUAGE:CXX>:-include ${GCH_PATH}/${PCH_NAME}.h -Winvalid-pch> )
-        ADD_DEPENDENCIES(${_targetName} ${_targetName}_PCH)
-    endif()
-  ENDIF(CMAKE_COMPILER_IS_GNUCXX OR ${CMAKE_CXX_COMPILER_ID} MATCHES "Clang")
-ENDMACRO()
+    #        target_compile_options( ${_targetName} PRIVATE $<$<COMPILE_LANGUAGE:CXX>:-include ${GCH_PATH}/${PCH_NAME}.h -Winvalid-pch> )
+            ADD_DEPENDENCIES(${_targetName} ${_targetName}_PCH)
+        endif()
+    endif( CMAKE_COMPILER_IS_GNUCXX OR ${CMAKE_CXX_COMPILER_ID} MATCHES "Clang" )
+endmacro()


feature: update eigen version to 3.3.8

feature: update eigen version to 3.3.8

--- cmake/external/DownloadEigen.cmake
+++ cmake/external/DownloadEigen.cmake
@@ -6,7 +6,7 @@

 ExternalProject_Add(eigen
                     GIT_REPOSITORY "https://gitlab.com/libeigen/eigen.git"
-                    GIT_TAG "3.3.7"
+                    GIT_TAG "3.3.8"
                     SOURCE_DIR "${PROJECT_SOURCE_DIR}/third_party/eigen3"
                     BINARY_DIR "${CMAKE_BINARY_DIR}/eigen-build"
                     CONFIGURE_COMMAND ""


Defined BOOST_ALL_NO_LIB to disable auto-linking

Fixes linker errors about missing pdalboost_filesystem...lib
and others, while building with Visual Studio.

--- cmake/win32_compiler_options.cmake
+++ cmake/win32_compiler_options.cmake
@@ -11,6 +11,8 @@
     elseif (MSVC8)
       set(PDAL_COMPILER_VC8 1)
     endif()
+
+    add_definitions(-DBOOST_ALL_NO_LIB)

     # check for MSVC 8+
     if (NOT (MSVC_VERSION VERSION_LESS 1400))


FindOpenColorIO.cmake: Fix for location of OCIO headers (#1528)

--- src/cmake/modules/FindOpenColorIO.cmake
+++ src/cmake/modules/FindOpenColorIO.cmake
@@ -25,7 +25,7 @@
         endif()
     endif ()
     FIND_PATH(OCIO_INCLUDES
-        OpenColorIO.h
+        OpenColorIO/OpenColorIO.h
         PATHS
         ${OCIO_INCLUDE_PATH}
         ${OCIO_PATH}/include/
@@ -33,7 +33,6 @@
         /usr/local/include
         /sw/include
         /opt/local/include
-        PATH_SUFFIXES OpenColorIO
         DOC "The directory where OpenColorIO/OpenColorIO.h resides")
     FIND_LIBRARY(OCIO_LIBRARIES
         NAMES OCIO OpenColorIO


updated the find cyclopts cmake file matching the cyclus implementation

--- src/CMake/FindCYCLOPTS.cmake
+++ src/CMake/FindCYCLOPTS.cmake
@@ -1,13 +1,23 @@
+
+IF(NOT DEFINED CYCLOPTS_ROOT_DIR)
+    SET(CYCLOPTS_ROOT_DIR "$ENV{CYCLOPTS_ROOT_DIR}")
+ENDIF(NOT DEFINED CYCLOPTS_ROOT_DIR)
+
+MESSAGE(STATUS "CYCLOPTS_ROOT_DIR hint is : ${CYCLOPTS_ROOT_DIR}")

 # if installed in a non-standard location,
 # the include directory must be added to the PATH variable
 FIND_PATH(CYCLOPTS_INCLUDE_DIR cyclopts/Variable.h
+  HINTS "${CYCLOPTS_INCLUDE_DIR}"
+  HINTS "${CYCLOPTS_ROOT_DIR}"
+  HINTS "${CYCLOPTS_ROOT_DIR}/include"
   HINTS /usr/
   HINTS /usr/include/
   HINTS /usr/local/
   HINTS /usr/local/include/
   HINTS /usr/cyclopts/
   HINTS /usr/local/cyclopts/
+  HINTS ${CYCLOPTS_HINT}/
 )

 set(CYCLOPTS_INCLUDE_DIR ${CYCLOPTS_INCLUDE_DIR}/cyclopts)


branding (win)

branding (win)

--- indra/cmake/Variables.cmake
+++ indra/cmake/Variables.cmake
@@ -122,7 +122,7 @@
 set(GRID agni CACHE STRING "Target Grid")

 set(VIEWER ON CACHE BOOL "Build Firestorm viewer.")
-set(VIEWER_CHANNEL "LindenDeveloper" CACHE STRING "Viewer Channel Name")
+set(VIEWER_CHANNEL "FirestormDeveloper" CACHE STRING "Viewer Channel Name")
 set(VIEWER_LOGIN_CHANNEL ${VIEWER_CHANNEL} CACHE STRING "Fake login channel for A/B Testing")

 set(STANDALONE OFF CACHE BOOL "Do not use Linden-supplied prebuilt libraries.")


Remove install of INCLUDE target.

Remove install of INCLUDE target.

--- Shared/CMake/JamomaUtilFunctions.cmake
+++ Shared/CMake/JamomaUtilFunctions.cmake
@@ -31,8 +31,7 @@
 			EXPORT ${PROJECT_NAME}Targets
 			LIBRARY DESTINATION lib
 			ARCHIVE DESTINATION lib
-			RUNTIME DESTINATION bin
-			INCLUDES DESTINATION include)
+			RUNTIME DESTINATION bin)
 	if(APPLE)
 		install(FILES ${PROJECT_HDRS} DESTINATION "include")
 	else()


add stitching miniapp to workbench release config

--- CMake/BuildConfigurations/WorkbenchRelease.cmake
+++ CMake/BuildConfigurations/WorkbenchRelease.cmake
@@ -18,6 +18,7 @@

 if(NOT MITK_USE_SUPERBUILD)
   set(BUILD_CoreCmdApps ON CACHE BOOL "" FORCE)
+  set(BUILD_MatchPointCmdApps ON CACHE BOOL "" FORCE)
 endif()

 set(MITK_VTK_DEBUG_LEAKS OFF CACHE BOOL "Enable VTK Debug Leaks" FORCE)


[CI] mv submit step before eventual error report

--- CI/machinery/CTestDriver.cmake
+++ CI/machinery/CTestDriver.cmake
@@ -156,9 +156,7 @@
 ctest_configure()
 ctest_build()
 ctest_test(PARALLEL_LEVEL ${NP} RETURN_VALUE TEST_RETURN_VAL)
-if(NOT TEST_RETURN_VAL EQUAL 0)
-message(FATAL_ERROR " *** test failure *** ")
-endif()
+
 if (WITH_MEMCHECK AND CTEST_COVERAGE_COMMAND)
 ctest_coverage()
 endif (WITH_MEMCHECK AND CTEST_COVERAGE_COMMAND)
@@ -173,4 +171,6 @@
 if(NOT SUBMIT_RETURN_VAL EQUAL 0)
 message(WARNING " *** submission failure *** ")
 endif()
-
+if(NOT TEST_RETURN_VAL EQUAL 0)
+message(FATAL_ERROR " *** test failure *** ")
+endif()


COMP: additional check for MITK_USE_OPEN_CV to avoid CMake errors

--- CMake/MITK_OpenCV_Config.cmake
+++ CMake/MITK_OpenCV_Config.cmake
@@ -1,4 +1,5 @@
 #MESSAGE(STATUS "Searching for OpenCV")
+IF(MITK_USE_OPEN_CV)
 FIND_PACKAGE(OpenCV REQUIRED)
 LIST(APPEND ALL_LIBRARIES ${OpenCV_LIBS})
 # adding release directory for fixing error with RelWitgDebInfo (debug dlls have the suffix "d". thus release dlls wont be loaded accidentally)
@@ -19,3 +20,5 @@
 #MESSAGE(STATUS "Warning: OpenCVConfig.cmake not found. Please set OPENCV_DIR manually to guide search.")
 #SET(OPENCV_DIR CACHE PATH "Set the directory containing OpenCVConfig.cmake")
 #ENDIF(OPENCV_DIR)
+ENDIF(MITK_USE_OPEN_CV)
+


Add framework library to support HIDAPI.

--- CMake/Modules/UrhoCommon.cmake
+++ CMake/Modules/UrhoCommon.cmake
@@ -860,7 +860,7 @@
     # ThirdParty/SDL external dependency
     if (${TARGET} MATCHES SDL|Urho3D)
         if (WIN32)
-            list (APPEND LIBS user32 gdi32 winmm imm32 ole32 oleaut32 version uuid)
+            list (APPEND LIBS user32 gdi32 winmm imm32 ole32 oleaut32 setupapi version uuid)
         elseif (APPLE)
             list (APPEND LIBS iconv)
         elseif (ANDROID)
@@ -907,9 +907,9 @@
             endif ()
         elseif (APPLE)
             if (ARM)
-                list (APPEND LIBS "-framework AudioToolbox" "-framework AVFoundation" "-framework CoreAudio" "-framework CoreGraphics" "-framework CoreMotion" "-framework Foundation" "-framework GameController" "-framework OpenGLES" "-framework QuartzCore" "-framework UIKit")
+                list (APPEND LIBS "-framework AudioToolbox" "-framework AVFoundation" "-framework CoreAudio" "-framework CoreBluetooth" "-framework CoreGraphics" "-framework CoreMotion" "-framework Foundation" "-framework GameController" "-framework OpenGLES" "-framework QuartzCore" "-framework UIKit")
             else ()
-                list (APPEND LIBS "-framework AudioToolbox" "-framework Carbon" "-framework Cocoa" "-framework CoreFoundation" "-framework SystemConfiguration" "-framework CoreAudio" "-framework CoreServices" "-framework CoreVideo" "-framework ForceFeedback" "-framework IOKit" "-framework OpenGL")
+                list (APPEND LIBS "-framework AudioToolbox" "-framework Carbon" "-framework Cocoa" "-framework CoreFoundation" "-framework SystemConfiguration" "-framework CoreAudio" "-framework CoreBluetooth" "-framework CoreServices" "-framework CoreVideo" "-framework ForceFeedback" "-framework IOKit" "-framework OpenGL")
             endif ()
         endif ()


Updated forge tag

Updated forge tag

--- CMakeModules/build_forge.cmake
+++ CMakeModules/build_forge.cmake
@@ -22,7 +22,7 @@
 ExternalProject_Add(
     forge-ext
     GIT_REPOSITORY https://github.com/arrayfire/forge.git
-    GIT_TAG af3.2.0
+    GIT_TAG af3.2.1
     PREFIX "${prefix}"
     INSTALL_DIR "${prefix}"
     UPDATE_COMMAND ""


Manual synchronization to allow the compilation in STANDALONE witout python mode.

--- adm_local_without_kernel/cmake_files/SalomeMacros.cmake
+++ adm_local_without_kernel/cmake_files/SalomeMacros.cmake
@@ -595,6 +595,21 @@
 ENDMACRO(SALOME_ADD_MPI_TO_HDF5)

 ####################################################################
+# SALOME_TOHEXA()
+# Convert a number (smaller than 16) into hexadecimal representation
+# with a leading 0.
+MACRO(SALOME_TOHEXA num result)
+  SET(_hexa_map a b c d e f)
+  IF(${num} LESS 10)
+    SET(${result} "0${num}")
+  ELSE()
+    MATH(EXPR _res "${num}-10" )
+    LIST(GET _hexa_map ${_res} _out)
+    SET(${result} "0${_out}")
+  ENDIF()
+ENDMACRO(SALOME_TOHEXA)
+
+####################################################################
 # SALOME_XVERSION()
 #
 # Computes hexadecimal version of SALOME package
@@ -613,10 +628,16 @@
 MACRO(SALOME_XVERSION pkg)
   STRING(TOUPPER ${pkg} _pkg_UC)
   IF(${_pkg_UC}_VERSION)
-    EXECUTE_PROCESS(COMMAND ${PYTHON_EXECUTABLE} -c "import sys; t=sys.argv[-1].split(\".\") ; t[:]=(int(elt) for elt in t) ; sys.stdout.write(\"0x%02x%02x%02x\"%tuple(t))" ${${_pkg_UC}_VERSION}
-                    OUTPUT_VARIABLE ${_pkg_UC}_XVERSION)
+    SET(_major)
+    SET(_minor)
+    SET(_patch)
+    SALOME_TOHEXA(${${_pkg_UC}_MAJOR_VERSION} _major)
+    SALOME_TOHEXA(${${_pkg_UC}_MINOR_VERSION} _minor)
+    SALOME_TOHEXA(${${_pkg_UC}_PATCH_VERSION} _patch)
+    SET(${_pkg_UC}_XVERSION "0x${_major}${_minor}${_patch}")
   ENDIF()
 ENDMACRO(SALOME_XVERSION)
+

 #########################################################################
 # SALOME_ACCUMULATE_HEADERS()


Add vespaclient-java shell scripts to cmake install script

--- install_java.cmake
+++ install_java.cmake
@@ -46,6 +46,7 @@
 install_fat_java_artifact(standalone-container)
 install_fat_java_artifact(vespa-http-client)
 install_fat_java_artifact(vespaclient-container-plugin)
+install_fat_java_artifact(vespaclient-java)
 install_fat_java_artifact(zkfacade)

 vespa_install_script(application-preprocessor/src/main/sh/vespa-preprocess-application bin)
@@ -57,6 +58,15 @@
 vespa_install_script(config-model/src/main/perl/vespa-replicate-log-stream bin)
 vespa_install_script(config-model/src/main/sh/validate-application bin)
 vespa_install_script(container-disc/src/main/sh/vespa-start-container-daemon.sh vespa-start-container-daemon bin)
+vespa_install_script(vespaclient-java/src/main/sh/vds-document-statistics.sh vds-document-statistics bin)
+vespa_install_script(vespaclient-java/src/main/sh/vdsstat.sh vdsstat bin)
+vespa_install_script(vespaclient-java/src/main/sh/vespa-query-profile-dump-tool.sh vespa-query-profile-dump-tool bin)
+vespa_install_script(vespaclient-java/src/main/sh/vespa-summary-benchmark.sh vespa-summary-benchmark bin)
+vespa_install_script(vespaclient-java/src/main/sh/vespadestination.sh vespadestination bin)
+vespa_install_script(vespaclient-java/src/main/sh/vespafeeder.sh vespafeeder bin)
+vespa_install_script(vespaclient-java/src/main/sh/vespaget.sh vespaget bin)
+vespa_install_script(vespaclient-java/src/main/sh/vespavisit.sh vespavisit bin)
+vespa_install_script(vespaclient-java/src/main/sh/vespavisittarget.sh vespavisittarget bin)

 vespa_install_script(logserver/bin/logserver-start.sh logserver-start bin)


Update lwIP CMake to remove unused inlude paths

Signed-off-by: José Simões <1616ff7a83d123f98f8f38fa2524eab406644781@eclo.solutions>

--- CMake/Modules/FindCHIBIOS_LWIP.cmake
+++ CMake/Modules/FindCHIBIOS_LWIP.cmake
@@ -11,18 +11,13 @@

 # List of the required lwIp include files.
 list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_SOURCE_DIR}/targets/CMSIS-OS/Lwip)
-list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_SOURCE_DIR}/src/DeviceInterfaces/Networking.Sntp)
 list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/os/various)
 list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/os/various/lwip_bindings)
 list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include)
-list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include/lwip/apps)
-list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include/lwip/priv)
-list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include/lwip/prot)
+list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include/lwip)
 list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include/netif)
-list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include/netif/ppp)
-list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include/netif/ppp/polarssl)
 list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include/posix)
-list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/ext/lwip/src/include/posix/sys)
+list(APPEND CHIBIOS_LWIP_INCLUDE_DIRS ${PROJECT_SOURCE_DIR}/src/DeviceInterfaces/Networking.Sntp)

 set(LWIP_SRCS


DashboardDriverScript - Build result of targets test and doc are submitted

--- CMake/ctkDashboardDriverScript.cmake
+++ CMake/ctkDashboardDriverScript.cmake
@@ -181,21 +181,23 @@
      # Build target
      set(CTEST_BUILD_TARGET "${subproject}")
      ctest_build(BUILD "${ctk_build_dir}" APPEND)
+     ctest_submit(PARTS Build)

      # Loop over kit suffixes and try to build the corresponding target
      foreach(kit_suffixe ${kit_suffixes})
        message("----------- [ Build ${subproject}${kit_suffixe} ] -----------")
        set(CTEST_BUILD_TARGET "${subproject}${kit_suffixe}")
        ctest_build(BUILD "${ctk_build_dir}" APPEND)
+       ctest_submit(PARTS Build)
      endforeach()

-     ctest_submit(PARTS Build)
     endforeach()

     if (WITH_DOCUMENTATION)
       # Build Documentation target
       set(CTEST_BUILD_TARGET "doc")
       ctest_build(BUILD "${ctk_build_dir}" APPEND)
+      ctest_submit(PARTS Build)
     endif()

     # HACK Unfortunately ctest_coverage ignores the build argument, try to force it...


fix cmake error introduced by prev. commit

git-svn-id: 65dd0ccd495961f396d5302e5521154b071f0302@2407 5b2332b8-efa3-11de-8684-7d64432d61a3

--- CMakeModules/ConfigurePackages.cmake
+++ CMakeModules/ConfigurePackages.cmake
@@ -12,15 +12,18 @@
         set (Boost_USE_STATIC_LIBS OFF)
     endif ()

-    sagase_configure_package (BOOST
-        NAMES Boost boost
-	if (APPLE)
-	        COMPONENTS boost_date_time boost_filesystem boost_system boost_thread boost_program_options boost_unit_test_framework
-	else ()
-	        COMPONENTS date_time filesystem system thread program_options unit_test_framework
-	endif ()
-
-        PREFIXES ${ENV_NAALI_DEP_PATH})
+    if (APPLE)
+        sagase_configure_package (BOOST
+    	    NAMES Boost boost
+            COMPONENTS boost_date_time boost_filesystem boost_system boost_thread boost_program_options boost_unit_test_framework
+
+            PREFIXES ${ENV_NAALI_DEP_PATH})
+    else ()
+        sagase_configure_package (BOOST
+    	    NAMES Boost boost
+            COMPONENTS date_time filesystem system thread program_options unit_test_framework
+            PREFIXES ${ENV_NAALI_DEP_PATH})
+    endif ()

     if (APPLE)
         set (BOOST_LIBRARY_DIRS ${ENV_NAALI_DEP_PATH}/lib)


Ensure aio is available on Linux.

Ensure aio is available on Linux.

--- cmake/build_configurations/mysql_release.cmake
+++ cmake/build_configurations/mysql_release.cmake
@@ -103,6 +103,16 @@
   ENDIF()

   OPTION(WITH_PIC "" ON) # Why?
+
+  # Ensure aio is available on Linux (required by InnoDB)
+  IF(CMAKE_SYSTEM_NAME STREQUAL "Linux")
+    CHECK_INCLUDE_FILES(libaio.h HAVE_LIBAIO_H)
+    CHECK_LIBRARY_EXISTS(aio io_queue_init "" HAVE_LIBAIO)
+    IF(NOT HAVE_LIBAIO_H OR NOT HAVE_LIBAIO)
+      MESSAGE(FATAL_ERROR "aio is required on Linux")
+    ENDIF()
+  ENDIF()
+
 ENDIF()


COMP: add missing rtkcuda library for linking SimpleRTK

--- utilities/SimpleRTK/SimpleRTKWithSwig.cmake
+++ utilities/SimpleRTK/SimpleRTKWithSwig.cmake
@@ -130,6 +130,10 @@
 file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/SimpleRTK-build/CMakeCacheInit.txt" "${ep_simplertk_cache}${ep_common_cache}\n${ep_languages_cache}" )

 set(proj SimpleRTK)
+set(SimpleRTKDeps "RTK")
+if(RTK_USE_CUDA)
+  list(APPEND SimpleRTKDeps "rtkcuda")
+endif()
 ExternalProject_Add(${proj}
   DOWNLOAD_COMMAND ""
   SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}
@@ -168,7 +172,7 @@
     -DWRAP_R:BOOL=${WRAP_R}
     -DBUILD_EXAMPLES:BOOL=${BUILD_TESTING}
 	-DSimpleRTK_PYTHON_WHEEL=1
-  DEPENDS ${${CMAKE_PROJECT_NAME}_DEPENDENCIES} RTK
+  DEPENDS ${${CMAKE_PROJECT_NAME}_DEPENDENCIES} ${SimpleRTKDeps}
 )


build configuration fixed to lab system

build configuration fixed to lab system

--- CMake/BuildConfigurations/camiPhotoacousticsSetup.cmake
+++ CMake/BuildConfigurations/camiPhotoacousticsSetup.cmake
@@ -9,8 +9,8 @@
 set(MITK_USE_OPHIR_PYRO_HARDWARE ON CACHE BOOL "Use the Ophir sensor build-in in OPOTEK Phocus Mobile" FORCE)
 set(MITK_OPHIR_API_PATH "C:/OphirCppWrapper" CACHE PATH "Ophir API Path")

-set(MITK_USE_OPOTEK_HARDWARE ON CACHE BOOL "Use hardware build-in in OPOTEK Phocus Mobile" FORCE)
-set(MITK_GALIL_API_PATH "C:/OphirCppWrapper" CACHE PATH "Galil API Path")
+set(MITK_USE_GALIL_HARDWARE ON CACHE BOOL "Use hardware build-in in OPOTEK Phocus Mobile" FORCE)
+set(MITK_GALIL_API_PATH "C:/Program Files (x86)/Galil/gclib" CACHE PATH "Galil API Path")

 # Enable default plugins and the navigation modules
 set(MITK_CONFIG_PLUGINS


Use relative paths for rpath.

Use relative paths for rpath.

--- cmake/config.cmake
+++ cmake/config.cmake
@@ -22,8 +22,12 @@

 enable_testing()

-set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/lib)
-set(MACOSX_RPATH ON)
+if (APPLE)
+	set(CMAKE_INSTALL_RPATH "@executable_path;@executable_path/../lib")
+	set(MACOSX_RPATH ON)
+else()
+	set(CMAKE_INSTALL_RPATH "$ORIGIN;$ORIGIN/../lib")
+endif()

 function(cfs_set_folder target folderName)
 	if (CUTTLEFISH_ROOT_FOLDER AND folderName)


specify ceres LIB_SUFFIX to be empty to avoid lib64

issue https://github.com/smanders/externpro/issues/206

--- projects/ceres.cmake
+++ projects/ceres.cmake
@@ -49,6 +49,8 @@
     )
   if(MSVC)
     list(APPEND XP_CONFIGURE -DMSVC_USE_STATIC_CRT:BOOL=OFF)
+  elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
+    list(APPEND XP_CONFIGURE -DLIB_SUFFIX:STRING=) # install to lib, not lib64
   endif()
   configure_file(${PRO_DIR}/use/usexp-ceres-config.cmake ${STAGE_DIR}/share/cmake/
     @ONLY NEWLINE_STYLE LF


BUG: build xcb in Qt Superbuild

BUG: build xcb in Qt Superbuild

--- SuperBuild/CMake/External_qt5.cmake
+++ SuperBuild/CMake/External_qt5.cmake
@@ -98,7 +98,7 @@
     set(QT5_SB_CONFIG "${QT5_SB_CONFIG} -no-framework")
   else()
       #Linux
-      set(QT5_SB_CONFIG "${QT5_SB_CONFIG} -no-glib -no-fontconfig")
+      set(QT5_SB_CONFIG "${QT5_SB_CONFIG} -no-glib -no-fontconfig -qt-xcb")
   endif()
   #common for all unix
   set(QT5_SB_CONFIG "${QT5_SB_CONFIG} -no-dbus -no-icu -v")


fixed: propage qmake config to dependent projects

--- CMake/ConfigurePackages.cmake
+++ CMake/ConfigurePackages.cmake
@@ -747,6 +747,7 @@
         ENDIF(WIN32)

 #        OSG_ADD_OPT(QT4_FOUND)
+        OSG_ADD_OPT(QT_QMAKE_EXECUTABLE)

     ELSE(QT4_FOUND)
         OSG_SET(OSG_QT4_INC_DIR "")


- Fixed ogre_find_plugin macro in FindOGRE.cmake by adding new path suffix OGRE-${OGRE_VERSION}

--- CMake/Packages/FindOGRE.cmake
+++ CMake/Packages/FindOGRE.cmake
@@ -444,9 +444,9 @@
   get_debug_names(OGRE_${PLUGIN}_LIBRARY_NAMES)
   set(OGRE_${PLUGIN}_LIBRARY_FWK ${OGRE_LIBRARY_FWK})
   find_library(OGRE_${PLUGIN}_LIBRARY_REL NAMES ${OGRE_${PLUGIN}_LIBRARY_NAMES}
-    HINTS "${OGRE_BUILD}/lib" ${OGRE_LIBRARY_DIRS} ${OGRE_FRAMEWORK_PATH} PATH_SUFFIXES "" OGRE opt Release Release/opt RelWithDebInfo RelWithDebInfo/opt MinSizeRel MinSizeRel/opt)
+    HINTS "${OGRE_BUILD}/lib" ${OGRE_LIBRARY_DIRS} ${OGRE_FRAMEWORK_PATH} PATH_SUFFIXES "" OGRE OGRE-${OGRE_VERSION} opt Release Release/opt RelWithDebInfo RelWithDebInfo/opt MinSizeRel MinSizeRel/opt)
   find_library(OGRE_${PLUGIN}_LIBRARY_DBG NAMES ${OGRE_${PLUGIN}_LIBRARY_NAMES_DBG}
-    HINTS "${OGRE_BUILD}/lib" ${OGRE_LIBRARY_DIRS} ${OGRE_FRAMEWORK_PATH} PATH_SUFFIXES "" OGRE opt Debug Debug/opt)
+    HINTS "${OGRE_BUILD}/lib" ${OGRE_LIBRARY_DIRS} ${OGRE_FRAMEWORK_PATH} PATH_SUFFIXES "" OGRE OGRE-${OGRE_VERSION} opt Debug Debug/opt)
   make_library_set(OGRE_${PLUGIN}_LIBRARY)

   if (OGRE_${PLUGIN}_LIBRARY OR OGRE_${PLUGIN}_INCLUDE_DIR)


CMake: Make FindOgre script useable on OSX with static builds

--- CMake/Packages/FindOGRE.cmake
+++ CMake/Packages/FindOGRE.cmake
@@ -68,14 +68,13 @@
   set(OGRE_LIB_SUFFIX "")
 endif ()

-
-if(APPLE AND NOT OGRE_BUILD_PLATFORM_APPLE_IOS)
+if(APPLE AND NOT OGRE_STATIC)
 	set(OGRE_LIBRARY_NAMES "Ogre${OGRE_LIB_SUFFIX}")
 else()
     set(OGRE_LIBRARY_NAMES "OgreMain${OGRE_LIB_SUFFIX}")
 endif()
 get_debug_names(OGRE_LIBRARY_NAMES)
-
+
 # construct search paths from environmental hints and
 # OS specific guesses
 if (WIN32)
@@ -145,7 +144,7 @@
 set(OGRE_PREFIX_WATCH ${OGRE_PREFIX_PATH} ${OGRE_PREFIX_SOURCE} ${OGRE_PREFIX_BUILD})
 clear_if_changed(OGRE_PREFIX_WATCH ${OGRE_RESET_VARS})

-if(NOT OGRE_BUILD_PLATFORM_APPLE_IOS)
+if(NOT OGRE_STATIC)
 	# try to locate Ogre via pkg-config
 	use_pkgconfig(OGRE_PKGC "OGRE${OGRE_LIB_SUFFIX}")

@@ -383,11 +382,9 @@
 # look for Overlay component
 ogre_find_component(Overlay OgreOverlaySystem.h)

-
 #########################################################
 # Find Ogre plugins
-#########################################################
-
+#########################################################
 macro(ogre_find_plugin PLUGIN HEADER)
   # On Unix, the plugins might have no prefix
   if (CMAKE_FIND_LIBRARY_PREFIXES)
@@ -411,9 +408,9 @@
   get_debug_names(OGRE_${PLUGIN}_LIBRARY_NAMES)
   set(OGRE_${PLUGIN}_LIBRARY_FWK ${OGRE_LIBRARY_FWK})
   find_library(OGRE_${PLUGIN}_LIBRARY_REL NAMES ${OGRE_${PLUGIN}_LIBRARY_NAMES}
-    HINTS ${OGRE_LIBRARY_DIRS} PATH_SUFFIXES "" OGRE opt release release/opt relwithdebinfo relwithdebinfo/opt minsizerel minsizerel/opt)
+    HINTS "${OGRE_BUILD}/lib" ${OGRE_LIBRARY_DIRS} PATH_SUFFIXES "" OGRE opt release release/opt relwithdebinfo relwithdebinfo/opt minsizerel minsizerel/opt)
   find_library(OGRE_${PLUGIN}_LIBRARY_DBG NAMES ${OGRE_${PLUGIN}_LIBRARY_NAMES_DBG}
-    HINTS ${OGRE_LIBRARY_DIRS} PATH_SUFFIXES "" OGRE opt debug debug/opt)
+    HINTS "${OGRE_BUILD}/lib" ${OGRE_LIBRARY_DIRS} PATH_SUFFIXES "" OGRE opt debug debug/opt)
   make_library_set(OGRE_${PLUGIN}_LIBRARY)

   if (OGRE_${PLUGIN}_LIBRARY OR OGRE_${PLUGIN}_INCLUDE_DIR)
@@ -446,9 +443,9 @@
           PATH_SUFFIXES "" bin bin/debug debug)
       elseif (UNIX)
         get_filename_component(OGRE_PLUGIN_DIR_TMP ${OGRE_${PLUGIN}_LIBRARY_REL} PATH)
-        set(OGRE_PLUGIN_DIR_REL ${OGRE_PLUGIN_DIR_TMP} CACHE STRING "Ogre plugin dir (release)")
-        get_filename_component(OGRE_PLUGIN_DIR_TMP ${OGRE_${PLUGIN}_LIBRARY_DBG} PATH)
-        set(OGRE_PLUGIN_DIR_DBG ${OGRE_PLUGIN_DIR_TMP} CACHE STRING "Ogre plugin dir (debug)")
+        set(OGRE_PLUGIN_DIR_REL ${OGRE_PLUGIN_DIR_TMP} CACHE STRING "Ogre plugin dir (release)" FORCE)
+	    get_filename_component(OGRE_PLUGIN_DIR_TMP ${OGRE_${PLUGIN}_LIBRARY_DBG} PATH)
+        set(OGRE_PLUGIN_DIR_DBG ${OGRE_PLUGIN_DIR_TMP} CACHE STRING "Ogre plugin dir (debug)" FORCE)
       endif ()
     endif ()

@@ -479,7 +476,7 @@
 ogre_find_plugin(RenderSystem_GLES2 OgreGLES2RenderSystem.h RenderSystems/GLES2/include)
 ogre_find_plugin(RenderSystem_Direct3D9 OgreD3D9RenderSystem.h RenderSystems/Direct3D9/include)
 ogre_find_plugin(RenderSystem_Direct3D11 OgreD3D11RenderSystem.h RenderSystems/Direct3D11/include)
-
+
 if (OGRE_STATIC)
   # check if dependencies for plugins are met
   if (NOT DirectX_FOUND)


allow the use of static xerces

allow the use of static xerces

--- CMakeModules/FindXerces.cmake
+++ CMakeModules/FindXerces.cmake
@@ -11,25 +11,46 @@
 SET(XERCESC_FIND_QUIETLY TRUE)
 ENDIF (XERCESC_INCLUDE AND XERCESC_LIBRARY)

-FIND_PATH(XERCESC_INCLUDE NAMES util/XercesVersion.hpp
+OPTION(XERCESC_STATIC "Set to ON to link your project with static library (instead of DLL)." ON)
+
+IF (NOT  ${XERCESC_WAS_STATIC} STREQUAL ${XERCESC_STATIC})
+UNSET(XERCESC_LIBRARY CACHE)
+UNSET(XERCESC_LIBRARY_DEBUG CACHE)
+ENDIF (NOT  ${XERCESC_WAS_STATIC} STREQUAL ${XERCESC_STATIC})
+
+SET(XERCESC_WAS_STATIC ${XERCESC_STATIC} CACHE INTERNAL "" )
+
+FIND_PATH(XERCESC_INCLUDE NAMES xercesc/util/XercesVersion.hpp
 PATHS
 $ENV{XERCESC_INCLUDE_DIR}
 ${XERCESC_INCLUDE_DIR}
-PATH_SUFFIXES xercesc
 )

+IF (XERCESC_STATIC)
+FIND_LIBRARY(XERCESC_LIBRARY NAMES xerces-c_static_3
+ PATHS
+ $ENV{XERCESC_LIBRARY_DIR}
+ ${XERCESC_LIBRARY_DIR}
+)
+FIND_LIBRARY(XERCESC_LIBRARY_DEBUG NAMES xerces-c_static_3D
+ PATHS
+ $ENV{XERCESC_LIBRARY_DIR}
+ ${XERCESC_LIBRARY_DIR}
+)
+ADD_DEFINITIONS( -DXERCES_STATIC_LIBRARY )
+ELSE (XERCESC_STATIC)
 FIND_LIBRARY(XERCESC_LIBRARY NAMES xerces-c_3
  PATHS
  $ENV{XERCESC_LIBRARY_DIR}
  ${XERCESC_LIBRARY_DIR}
- )
-
- FIND_LIBRARY(XERCESC_LIBRARY_DEBUG NAMES xerces-c_3D
+)
+FIND_LIBRARY(XERCESC_LIBRARY_DEBUG NAMES xerces-c_3D
  PATHS
  $ENV{XERCESC_LIBRARY_DIR}
  ${XERCESC_LIBRARY_DIR}
- )
-
+)
+ENDIF (XERCESC_STATIC)
+
 IF (XERCESC_INCLUDE AND XERCESC_LIBRARY)
 SET(XERCESC_FOUND TRUE)
 ELSE (XERCESC_INCLUDE AND XERCESC_LIBRARY)
@@ -38,14 +59,14 @@

 IF(XERCESC_FOUND)

-FIND_PATH(XVERHPPPATH NAMES XercesVersion.hpp PATHS
+FIND_PATH(XERCESC_XVERHPPPATH NAMES XercesVersion.hpp PATHS
  ${XERCESC_INCLUDE}
- PATH_SUFFIXES util)
+ PATH_SUFFIXES xercesc/util)

-IF ( ${XVERHPPPATH} STREQUAL XVERHPPPATH-NOTFOUND )
+IF ( ${XERCESC_XVERHPPPATH} STREQUAL XERCESC_XVERHPPPATH-NOTFOUND )
  SET(XERCES_VERSION "0")
-ELSE( ${XVERHPPPATH} STREQUAL XVERHPPPATH-NOTFOUND )
- FILE(READ ${XVERHPPPATH}/XercesVersion.hpp XVERHPP)
+ELSE( ${XERCESC_XVERHPPPATH} STREQUAL XERCESC_XVERHPPPATH-NOTFOUND )
+ FILE(READ ${XERCESC_XVERHPPPATH}/XercesVersion.hpp XVERHPP)

  STRING(REGEX MATCHALL "\n *#define XERCES_VERSION_MAJOR +[0-9]+" XVERMAJ
    ${XVERHPP})
@@ -63,7 +84,7 @@

  SET(XERCESC_VERSION ${XVERMAJ}.${XVERMIN}.${XVERREV})

-ENDIF ( ${XVERHPPPATH} STREQUAL XVERHPPPATH-NOTFOUND )
+ENDIF ( ${XERCESC_XVERHPPPATH} STREQUAL XERCESC_XVERHPPPATH-NOTFOUND )

 IF(NOT XERCESC_FIND_QUIETLY)
  MESSAGE(STATUS "Found Xerces-C: ${XERCESC_LIBRARY}")


PKG: avoid confusion variable names in macro

--- SuperBuild/CMake/PackageHelper.cmake
+++ SuperBuild/CMake/PackageHelper.cmake
@@ -263,6 +263,11 @@
   execute_process(COMMAND ${CMAKE_COMMAND} -E remove_directory "${CMAKE_INSTALL_PREFIX}/${PKG_STAGE_DIR}")
 endmacro()

+#NOTE:
+# VAR_IN_PKGSETUP_CONFIGURE cmake variable is set below.
+# This is important and useful running configure_file()
+# over *pkgsetup.in
+
 function(configure_package)
   if(UNIX)
     set(EXE_EXT "")
@@ -281,7 +286,7 @@
   endif()

   #This must exist in any OTB Installation minimal or full
-  set(PKG_BINARY_FILES "bin/otbApplicationLauncherCommandLine")
+  set(VAR_IN_PKGSETUP_CONFIGURE "bin/otbApplicationLauncherCommandLine")
   set(PKG_PEFILES "${OTB_INSTALL_DIR}/bin/otbApplicationLauncherCommandLine${EXE_EXT}")
   if(NOT EXISTS "${OTB_INSTALL_DIR}/bin/otbApplicationLauncherCommandLine${EXE_EXT}")
     message(FATAL_ERROR "${OTB_INSTALL_DIR}/bin/otbApplicationLauncherCommandLine${EXE_EXT} not found.")
@@ -291,8 +296,8 @@
       iceViewer
       otbTestDriver)
     if(EXISTS "${OTB_INSTALL_DIR}/bin/${EXE_FILE}${EXE_EXT}")
-      #see the first comment about PKG_BINARY_FILES
-      set(PKG_BINARY_FILES "${PKG_BINARY_FILES} bin/${EXE_FILE}${EXE_EXT}")
+      #see the first comment about VAR_IN_PKGSETUP_CONFIGURE
+      set(VAR_IN_PKGSETUP_CONFIGURE "${VAR_IN_PKGSETUP_CONFIGURE} bin/${EXE_FILE}${EXE_EXT}")
       list(APPEND PKG_PEFILES
         "${OTB_INSTALL_DIR}/bin/${EXE_FILE}${EXE_EXT}")
     endif()
@@ -301,12 +306,12 @@
   foreach(EXE_FILE monteverdi
       mapla)
     if(EXISTS "${CMAKE_INSTALL_PREFIX}/bin/${EXE_FILE}${EXE_EXT}")
-      #PKG_BINARY_FILES might seem a bit redundant variable if you
+      #VAR_IN_PKGSETUP_CONFIGURE might seem a bit redundant variable if you
       #consider PKG_PEFILES which also has same content.
-      #But PKG_BINARY_FILES goes into pkgsetup.in for Linux standalone binaries
+      #But VAR_IN_PKGSETUP_CONFIGURE goes into pkgsetup.in for Linux standalone binaries
       # and other one (PKG_PEFILES) is for dependency resolution in
       # process_deps() function
-      set(PKG_BINARY_FILES "${PKG_BINARY_FILES} bin/${EXE_FILE}${EXE_EXT}")
+      set(VAR_IN_PKGSETUP_CONFIGURE "${VAR_IN_PKGSETUP_CONFIGURE} bin/${EXE_FILE}${EXE_EXT}")
       list(APPEND PKG_PEFILES
         "${CMAKE_INSTALL_PREFIX}/bin/${EXE_FILE}${EXE_EXT}")
     endif()
@@ -322,10 +327,10 @@

   file(GLOB OTB_APPS_LIST ${OTB_APPLICATIONS_DIR}/otbapp_${LIB_EXT}) # /lib/otb

-  #see the first comment about PKG_BINARY_FILES
+  #see the first comment about VAR_IN_PKGSETUP_CONFIGURE
   foreach(OTB_APP_SO ${OTB_APPS_LIST})
     get_filename_component(OTB_APP_SO_NAME ${OTB_APP_SO} NAME)
-    set(PKG_BINARY_FILES "${PKG_BINARY_FILES} lib/otb/applications/${OTB_APP_SO_NAME}")
+    set(VAR_IN_PKGSETUP_CONFIGURE "${VAR_IN_PKGSETUP_CONFIGURE} lib/otb/applications/${OTB_APP_SO_NAME}")
   endforeach()

   set(include_mvd 0)
@@ -356,13 +361,13 @@
   file(GLOB temp_files "${CMAKE_BINARY_DIR}/temp_so_names_dir/*") # /lib/otb
   foreach(temp_file ${temp_files})
     get_filename_component(basename_of_temp_file ${temp_file} NAME)
-    set(PKG_BINARY_FILES "${PKG_BINARY_FILES} lib/${basename_of_temp_file}")
+    set(VAR_IN_PKGSETUP_CONFIGURE "${VAR_IN_PKGSETUP_CONFIGURE} lib/${basename_of_temp_file}")
   endforeach()

   #remove this temporary directory
   execute_process(COMMAND ${CMAKE_COMMAND} -E remove_directory "${CMAKE_BINARY_DIR}/temp_so_names_dir")

-  set(PKG_BINARY_FILES "${PKG_BINARY_FILES}" PARENT_SCOPE)
+  set(VAR_IN_PKGSETUP_CONFIGURE "${VAR_IN_PKGSETUP_CONFIGURE}" PARENT_SCOPE)

 endfunction()

@@ -434,7 +439,7 @@
         set(${result_var1} 1 PARENT_SCOPE)
         #Now find where the symlink is linked to.
         #Do a regex replace
-        string(REGEX REPLACE "_file_full_*.*symbolic.link.to.."
+        string(REGEX REPLACE "_file_full_*.*symbolic.link.to."
           "" symlinked_to ${file_ov})
         #Take out last character which is a single quote
         string(REPLACE "'" "" symlinked_to "${symlinked_to}")


Removed duplicate message

Removed duplicate message

--- allocore/modules/zeroconf_module.cmake
+++ allocore/modules/zeroconf_module.cmake
@@ -2,8 +2,6 @@

 if(BUILD_ZEROCONF)
-message("Building Zerconf module.")
-

 if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
   list(APPEND ALLOCORE_SRC


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 05)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   22)
+SET(KWSYS_DATE_STAMP_DAY   23)


STYLE: Nightly Date Stamp

STYLE: Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -7,4 +7,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 06)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   20)
+SET(KWSYS_DATE_STAMP_DAY   21)


STYLE: Nightly Date Stamp

STYLE: Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -7,4 +7,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 12)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   28)
+SET(KWSYS_DATE_STAMP_DAY   29)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 05)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   23)
+SET(KWSYS_DATE_STAMP_DAY   24)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 10)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   09)
+SET(KWSYS_DATE_STAMP_DAY   10)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 01)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   19)
+SET(KWSYS_DATE_STAMP_DAY   20)


STYLE: Nightly Date Stamp

STYLE: Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -7,4 +7,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 05)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   13)
+SET(KWSYS_DATE_STAMP_DAY   14)


STYLE: Nightly Date Stamp

STYLE: Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -7,4 +7,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 07)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   05)
+SET(KWSYS_DATE_STAMP_DAY   06)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 07)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   02)
+SET(KWSYS_DATE_STAMP_DAY   03)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 03)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   13)
+SET(KWSYS_DATE_STAMP_DAY   14)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 10)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   18)
+SET(KWSYS_DATE_STAMP_DAY   19)


STYLE: Nightly Date Stamp

STYLE: Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -7,4 +7,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 07)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   30)
+SET(KWSYS_DATE_STAMP_DAY   31)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 01)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   28)
+SET(KWSYS_DATE_STAMP_DAY   29)


STYLE: Nightly Date Stamp

STYLE: Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -4,7 +4,7 @@
 SET(KWSYS_DATE_STAMP_YEAR  2008)

 # KWSys version date month component.  Format is MM.
-SET(KWSYS_DATE_STAMP_MONTH 09)
+SET(KWSYS_DATE_STAMP_MONTH 10)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   30)
+SET(KWSYS_DATE_STAMP_DAY   01)


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

--- Utilities/kwsys/kwsysDateStamp.cmake
+++ Utilities/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@
 SET(KWSYS_DATE_STAMP_MONTH 10)

 # KWSys version date day component.  Format is DD.
-SET(KWSYS_DATE_STAMP_DAY   13)
+SET(KWSYS_DATE_STAMP_DAY   14)


allow tests with generator expression in the path

--- ament_cmake_nose/cmake/ament_add_nose_test.cmake
+++ ament_cmake_nose/cmake/ament_add_nose_test.cmake
@@ -61,7 +61,9 @@
   if(NOT IS_ABSOLUTE "${path}")
     set(path "${CMAKE_CURRENT_SOURCE_DIR}/${path}")
   endif()
-  if(NOT EXISTS "${path}")
+  # only check existence of path if it doesn't contain generator expressions
+  string(FIND "${path}" "$<" index)
+  if(index EQUAL -1 AND NOT EXISTS "${path}")
     message(FATAL_ERROR
       "ament_add_nose_test() the path '${path}' does not exist")
   endif()


MOD: Install headers for loadable modules. See: http://www.cegui.org.uk/mantis/view.php?id=724

--- cmake/CEGUIMacros.cmake
+++ cmake/CEGUIMacros.cmake
@@ -186,11 +186,7 @@

     include_directories("${CMAKE_SOURCE_DIR}/${_REL_INC_DIR}")

-    if (${_IS_MODULE})
-        set (_LIB_TYPE MODULE)
-    else()
-        set (_LIB_TYPE SHARED)
-    endif()
+    set (_LIB_TYPE SHARED)

     ###########################################################################
     #                       STATIC LIBRARY SET UP
@@ -272,7 +268,7 @@
 # to (except in static builds)
 #
 macro (cegui_add_loadable_module _MODULE_NAME _SOURCE_FILES_VAR _HEADER_FILES_VAR)
-    cegui_add_library_impl(${_MODULE_NAME} TRUE ${_SOURCE_FILES_VAR} ${_HEADER_FILES_VAR} TRUE FALSE)
+    cegui_add_library_impl(${_MODULE_NAME} TRUE ${_SOURCE_FILES_VAR} ${_HEADER_FILES_VAR} TRUE TRUE)
 endmacro()

 #


Add a version check for clang-format.

Add a version check for clang-format.

--- cmake/ClangFormat.cmake
+++ cmake/ClangFormat.cmake
@@ -15,6 +15,17 @@
   find_program(CLANG_FORMAT clang-format)

   if(CLANG_FORMAT)
+    # Query for version.
+    execute_process(
+      COMMAND ${CLANG_FORMAT} "--version"
+      OUTPUT_VARIABLE CLANG_FORMAT_VERSION
+      OUTPUT_STRIP_TRAILING_WHITESPACE)
+    string(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]+" CLANG_FORMAT_VERSION ${CLANG_FORMAT_VERSION})
+  endif()
+
+  set(CLANG_FORMAT_VERSION_PATTERN "6.[0-9]+.[0-9]+")
+
+  if(CLANG_FORMAT AND CLANG_FORMAT_VERSION MATCHES ${CLANG_FORMAT_VERSION_PATTERN})
     add_custom_target("${TARGET}_clangformat"
       COMMAND ${CLANG_FORMAT}
         "-i"
@@ -25,6 +36,10 @@
       WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
       VERBATIM)
     add_dependencies(${TARGET} "${TARGET}_clangformat")
+  elseif(CLANG_FORMAT)
+    message(WARNING "clang-format version ${CLANG_FORMAT_VERSION} is wrong.\n"
+      "Please download and install a version matching \"${CLANG_FORMAT_VERSION_PATTERN}\""
+      " from\n  http://releases.llvm.org/download.html\nNote: Also adjust Visual Studio options!")
   else()
     message(WARNING "clang-format was not found")
   endif()


Be less noisy about missing clang-format

--- cmake/ClangFormat.cmake
+++ cmake/ClangFormat.cmake
@@ -42,6 +42,6 @@
       " from http://releases.llvm.org/download.html\n"
 	  "Also adjust Visual Studio options and PATH variable as necessary!")
   else()
-    message(WARNING "clang-format was not found")
+    message(STATUS "clang-format: not found")
   endif()
 endfunction(add_clang_format)


cmake: Don't bother searching for D3DX headers/libraries.

We never used them and never will.

--- cmake/FindDirectX.cmake
+++ cmake/FindDirectX.cmake
@@ -11,18 +11,13 @@
 #
 #  DDRAW
 #  D3D
-#  D3DX
 #  D3D8
-#  D3DX8
 #  D3D9
-#  D3DX9
 #  D3D10
 #  D3D10_1
-#  D3DX10
 #  D3D11
 #  D3D11_1
 #  D3D11_2
-#  D3DX11
 #  D2D1
 #

@@ -150,24 +145,13 @@
     find_winsdk_header  (D3D     d3d.h)
     find_combined       (D3D     D3D DDRAW)

-    find_dxsdk_header   (D3DX    d3dx.h)
-    find_combined       (D3DX    D3DX D3DX)
-
     find_dxsdk_header   (D3D8    d3d8.h)
     find_dxsdk_library  (D3D8    d3d8)
     find_combined       (D3D8    D3D8 D3D8)

-    find_dxsdk_header   (D3DX8   d3dx8.h)
-    find_dxsdk_library  (D3DX8   d3dx8)
-    find_combined       (D3DX8   D3DX8 D3DX8)
-
     find_winsdk_header  (D3D9    d3d9.h)
     find_winsdk_library (D3D9    d3d9)
     find_combined       (D3D9    D3D9 D3D9)
-
-    find_dxsdk_header   (D3DX9   d3dx9.h)
-    find_dxsdk_library  (D3DX9   d3dx9)
-    find_combined       (D3DX9   D3DX9 D3DX9)

     find_winsdk_header  (DXGI    dxgi.h)
     find_winsdk_header  (DXGI1_2 dxgi1_2.h)
@@ -183,10 +167,6 @@
     find_winsdk_library (D3D10_1 d3d10_1)
     find_combined       (D3D10_1 D3D10_1 D3D10_1)

-    find_dxsdk_header   (D3DX10  d3dx10.h)
-    find_dxsdk_library  (D3DX10  d3dx10)
-    find_combined       (D3DX10  D3DX10 D3DX10)
-
     find_winsdk_header  (D3D11   d3d11.h)
     find_winsdk_library (D3D11   d3d11)
     find_combined       (D3D11   D3D11 D3D11)
@@ -196,10 +176,6 @@
     find_combined       (D3D11_2 D3D11_2 D3D11)
     find_winsdk_header  (D3D11_3 d3d11_3.h)
     find_combined       (D3D11_3 D3D11_3 D3D11)
-
-    find_dxsdk_header   (D3DX11  d3dx11.h)
-    find_dxsdk_library  (D3DX11  d3dx11)
-    find_combined       (D3DX11  D3DX11 D3DX11)

     find_winsdk_header  (D2D1    d2d1.h)
     find_winsdk_library (D2D1    d2d1)


Apply patch by Fabrice Ménard <menard.fabrice orange fr>, from kde-buildsystem. He says :
"As ${PKG_GOBJECT2_INCLUDE_DIRS} might be a list we can't simply append path components to it.
For example, on my system pkg-config --cflags gobject-2.0 returns :
        '-I/opt/gnome/include/glib-2.0 -I/opt/gnome/lib/glib-2.0/include' "

svn path=/trunk/kdesupport/phonon/; revision=937281

--- cmake/FindGObject.cmake
+++ cmake/FindGObject.cmake
@@ -25,11 +25,10 @@
    SET(GOBJECT_DEFINITIONS ${PKG_GOBJECT2_CFLAGS})
 ENDIF (NOT WIN32)

-FIND_PATH(GOBJECT_INCLUDE_DIR gobject.h
+FIND_PATH(GOBJECT_INCLUDE_DIR gobject/gobject.h
    PATHS
    ${PKG_GOBJECT2_INCLUDE_DIRS}
-   ${PKG_GOBJECT2_INCLUDE_DIRS}/glib-2.0/gobject/
-   /usr/include/glib-2.0/gobject/
+   /usr/include/glib-2.0/
    #PATH_SUFFIXES gst
    )


BUG: FindJsonCpp wrong library identifier.

libjson.so is provided by the json-c project, not JsonCpp.

Also fix find_package_handle_standard_args variables.

--- cmake/FindJsonCpp.cmake
+++ cmake/FindJsonCpp.cmake
@@ -33,7 +33,7 @@
   HINTS ${JsonCpp_INCLUDEDIR} ${PC_JsonCpp_INCLUDEDIR} ${PC_JsonCpp_INCLUDE_DIRS}
   PATH_SUFFIXES jsoncpp )

-find_library( JsonCpp_LIBRARY NAMES json jsoncpp libjson libjsoncpp
+find_library( JsonCpp_LIBRARY NAMES jsoncpp libjsoncpp
   HINTS ${JsonCpp_LIBDIR} ${PC_JsonCpp_LIBDIR} ${PC_JsonCpp_LIBRARY_DIRS} )

 set( JsonCpp_INCLUDE_DIRS ${JsonCpp_INCLUDE_DIR} )
@@ -41,7 +41,7 @@

 include( FindPackageHandleStandardArgs )

-find_package_handle_standard_args( JsonCpp DEFAULT_MSG JsonCpp_LIBRARY
-  JsonCpp_INCLUDE_DIR )
+find_package_handle_standard_args( JsonCpp DEFAULT_MSG JsonCpp_LIBRARIES
+  JsonCpp_INCLUDE_DIRS )

 mark_as_advanced( JsonCpp_INCLUDE_DIR JsonCpp_LIBRARY )


Find SDL2_ttf with NO_DEFAULT_PATH

Find SDL2_ttf with NO_DEFAULT_PATH

--- cmake/FindSDL2TTF.cmake
+++ cmake/FindSDL2TTF.cmake
@@ -2,9 +2,9 @@
 find_library(SDL2TTF_LIBRARY_TEMP "SDL2_ttf" PATH_SUFFIXES lib/x86 PATHS ${SDL2TTF_ROOT_DIR})

 if(WIN32)
-	find_file(SDL2TTF_DYLIB          "SDL2_ttf.dll"      PATH_SUFFIXES lib/x86 PATHS ${SDL2TTF_ROOT_DIR})
-	find_file(SDL2TTF_ZLIB_DYLIB     "zlib1.dll"         PATH_SUFFIXES lib/x86 PATHS ${SDL2TTF_ROOT_DIR})
-	find_file(SDL2TTF_FREETYPE_DYLIB "libfreetype-6.dll" PATH_SUFFIXES lib/x86 PATHS ${SDL2TTF_ROOT_DIR})
+	find_file(SDL2TTF_DYLIB          "SDL2_ttf.dll"      PATH_SUFFIXES lib/x86 PATHS ${SDL2TTF_ROOT_DIR} NO_DEFAULT_PATH)
+	find_file(SDL2TTF_ZLIB_DYLIB     "zlib1.dll"         PATH_SUFFIXES lib/x86 PATHS ${SDL2TTF_ROOT_DIR} NO_DEFAULT_PATH)
+	find_file(SDL2TTF_FREETYPE_DYLIB "libfreetype-6.dll" PATH_SUFFIXES lib/x86 PATHS ${SDL2TTF_ROOT_DIR} NO_DEFAULT_PATH)

 	set(SDL2TTF_DYLIBS
 		${SDL2TTF_DYLIB}


Fix compilation problem with vcpkg-provided TinyXML

--- cmake/FindTinyXML.cmake
+++ cmake/FindTinyXML.cmake
@@ -30,7 +30,8 @@

 include(StandardFindModule)
-standard_find_module(TinyXML tinyxml)
+standard_find_module(TinyXML tinyxml
+                     SKIP_CMAKE_CONFIG)

 # Set package properties if FeatureSummary was included
 if(COMMAND set_package_properties)


Spelling tweak in warning message.

Spelling tweak in warning message.

svn path=/trunk/; revision=7671

--- cmake/modules/gcw.cmake
+++ cmake/modules/gcw.cmake
@@ -103,7 +103,7 @@
 else(PLD_gcw)
   message(STATUS
   "WARNING: PLD_gcw is OFF so "
-  "Setting ENABLE_gnome2 and ENABLE_pygcw to OFF."
+  "setting ENABLE_gnome2 and ENABLE_pygcw to OFF."
   )
   set(ENABLE_gnome2 OFF CACHE BOOL "Enable Gnome2 bindings" FORCE)
   set(ENABLE_pygcw OFF CACHE BOOL "Enable Python Gnome2 bindings" FORCE)


install shared libraries

install shared libraries

git-svn-id: 5398946ba177a3e438c2dae55e2cdfc2fb96c905@777 a9d63959-f2ad-4865-b262-bf0e56cfafb6

--- cmake/pcl_targets.cmake
+++ cmake/pcl_targets.cmake
@@ -91,7 +91,9 @@
         VERSION ${PCL_VERSION}
         SOVERSION ${PCL_MAJOR_VERSION}
         DEFINE_SYMBOL "PCLAPI_EXPORTS")
-    install(TARGETS ${_name} LIBRARY DESTINATION ${LIB_INSTALL_DIR}
+    install(TARGETS ${_name}
+        RUNTIME DESTINATION ${BIN_INSTALL_DIR}
+        LIBRARY DESTINATION ${LIB_INSTALL_DIR}
         ARCHIVE DESTINATION ${LIB_INSTALL_DIR}
         COMPONENT ${_component})
 endmacro(PCL_ADD_LIBRARY)