Support VS 2011 / Windows 8 SDK.

Support VS 2011 / Windows 8 SDK.

--- cmake/FindDirectX.cmake
+++ cmake/FindDirectX.cmake
@@ -1,56 +1,83 @@
 # - try to find DirectX include dirs and libraries

+
 if (${CMAKE_SYSTEM_NAME} STREQUAL "Windows")
+
+
+	if (CMAKE_CL_64)
+		set (DirectX_ARCHITECTURE x64)
+	else ()
+		set (DirectX_ARCHITECTURE x86)
+	endif ()
+
+
+	# DirectX SDK
 	find_path (DirectX_ROOT_DIR
 		Include/d3d9.h
 		PATHS
 			"$ENV{DXSDK_DIR}"
 			"$ENV{ProgramFiles}/Microsoft DirectX SDK (June 2010)"
+			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (June 2010)"
 			"$ENV{ProgramFiles}/Microsoft DirectX SDK (February 2010)"
+			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (February 2010)"
 			"$ENV{ProgramFiles}/Microsoft DirectX SDK (March 2009)"
+			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (March 2009)"
 			"$ENV{ProgramFiles}/Microsoft DirectX SDK (August 2008)"
+			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (August 2008)"
 			"$ENV{ProgramFiles}/Microsoft DirectX SDK (June 2008)"
+			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (June 2008)"
 			"$ENV{ProgramFiles}/Microsoft DirectX SDK (March 2008)"
+			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (March 2008)"
 			"$ENV{ProgramFiles}/Microsoft DirectX SDK (November 2007)"
+			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (November 2007)"
 			"$ENV{ProgramFiles}/Microsoft DirectX SDK (August 2007)"
+			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (August 2007)"
 			"$ENV{ProgramFiles}/Microsoft DirectX SDK"
-			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (June 2010)"
-			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (February 2010)"
-			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (March 2009)"
-			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (August 2008)"
-			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (June 2008)"
-			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (March 2008)"
-			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (November 2007)"
-			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK (August 2007)"
 			"$ENV{ProgramFiles(x86)}/Microsoft DirectX SDK"
-		DOC "DirectX SDK root directory")
-
-
-	if (CMAKE_CL_64)
-		set (DirectX_ARCHITECTURE x64)
-	else ()
-		set (DirectX_ARCHITECTURE x86)
+		DOC "DirectX SDK root directory"
+	)
+	if (DirectX_ROOT_DIR)
+		set (DirectX_INC_SEARCH_PATH "${DirectX_ROOT_DIR}/Include")
+		set (DirectX_LIB_SEARCH_PATH "${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}")
+	endif ()
+
+
+	# With VS 2011 and Windows 8 SDK, the DirectX SDK is included as part of
+	# the Windows SDK.
+	#
+	# See also:
+	# - http://msdn.microsoft.com/en-us/library/windows/desktop/ee663275.aspx
+	# TODO: Allow using DirectX SDK with VS 2011
+	if (DEFINED MSVC_VERSION AND NOT ${MSVC_VERSION} LESS 1700)
+		find_path (WIN8_SDK_ROOT_DIR
+			Include/um/windows.h
+			PATHS
+				"$ENV{ProgramFiles}/Windows Kits/8.0"
+				"$ENV{ProgramFiles(x86)}/Windows Kits/8.0"
+				DOC "Windows 8 SDK root directory"
+		)
+
+		if (WIN8_SDK_ROOT_DIR)
+			set (DirectX_INC_SEARCH_PATH "${WIN8_SDK_ROOT_DIR}/Include/um" "${WIN8_SDK_ROOT_DIR}/Include/shared")
+			set (DirectX_LIB_SEARCH_PATH "${WIN8_SDK_ROOT_DIR}/Lib/Win8/um/${DirectX_ARCHITECTURE}")
+		endif ()
 	endif ()

 	find_path (DirectX_D3D_INCLUDE_DIR d3d.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3d.h resides")

 	find_path (DirectX_D3DX_INCLUDE_DIR d3dx.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3dx.h resides")

 	find_library (DirectX_DDRAW_LIBRARY ddraw
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where ddraw resides")

 	find_library (DirectX_D3DX_LIBRARY d3dx
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3dx resides")

 	if (DirectX_D3D_INCLUDE_DIR AND DirectX_DDRAW_LIBRARY)
@@ -62,23 +89,19 @@

 	find_path (DirectX_D3D8_INCLUDE_DIR d3d8.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3d8.h resides")

 	find_path (DirectX_D3DX8_INCLUDE_DIR d3dx8.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3dx8.h resides")

 	find_library (DirectX_D3D8_LIBRARY d3d8
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3d8 resides")

 	find_library (DirectX_D3DX8_LIBRARY d3dx8
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3dx8 resides")

 	if (DirectX_D3D8_INCLUDE_DIR AND DirectX_D3D8_LIBRARY)
@@ -90,23 +113,19 @@

 	find_path (DirectX_D3D9_INCLUDE_DIR d3d9.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3d9.h resides")

 	find_path (DirectX_D3DX9_INCLUDE_DIR d3dx9.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3dx9.h resides")

 	find_library (DirectX_D3D9_LIBRARY d3d9
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3d9 resides")

 	find_library (DirectX_D3DX9_LIBRARY d3dx9
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3dx9 resides")

 	if (DirectX_D3D9_INCLUDE_DIR AND DirectX_D3D9_LIBRARY)
@@ -118,23 +137,19 @@

 	find_path (DirectX_D3D10_INCLUDE_DIR d3d10.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3d10.h resides")

 	find_path (DirectX_D3DX10_INCLUDE_DIR d3dx10.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3dx10.h resides")

 	find_library (DirectX_D3D10_LIBRARY d3d10
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3d10 resides")

 	find_library (DirectX_D3DX10_LIBRARY d3dx10
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3dx10 resides")

 	if (DirectX_D3D10_INCLUDE_DIR AND DirectX_D3D10_LIBRARY)
@@ -146,13 +161,11 @@

 	find_path (DirectX_D3D10_1_INCLUDE_DIR d3d10_1.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3d10_1.h resides")

 	find_library (DirectX_D3D10_1_LIBRARY d3d10_1
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3d10_1 resides")

 	if (DirectX_D3D10_1_INCLUDE_DIR AND DirectX_D3D10_1_LIBRARY)
@@ -161,23 +174,19 @@

 	find_path (DirectX_D3D11_INCLUDE_DIR d3d11.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3d11.h resides")

 	find_path (DirectX_D3DX11_INCLUDE_DIR d3dx11.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3dx11.h resides")

 	find_library (DirectX_D3D11_LIBRARY d3d11
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3d11 resides")

 	find_library (DirectX_D3DX11_LIBRARY d3dx11
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
+		PATHS ${DirectX_LIB_SEARCH_PATH}
 		DOC "The directory where d3dx11 resides")

 	if (DirectX_D3D11_INCLUDE_DIR AND DirectX_D3D11_LIBRARY)
@@ -189,21 +198,15 @@

 	find_path (DirectX_D3D11_1_INCLUDE_DIR d3d11_1.h
-		PATHS
-			"${DirectX_ROOT_DIR}/Include"
+		PATHS ${DirectX_INC_SEARCH_PATH}
 		DOC "The directory where d3d11_1.h resides")

-	find_library (DirectX_D3D11_1_LIBRARY d3d11_1
-		PATHS
-			"${DirectX_ROOT_DIR}/Lib/${DirectX_ARCHITECTURE}"
-		DOC "The directory where d3d11_1 resides")
-
-	if (DirectX_D3D11_1_INCLUDE_DIR AND DirectX_D3D11_1_LIBRARY)
+	if (DirectX_D3D11_1_INCLUDE_DIR AND DirectX_D3D11_LIBRARY)
 		set (DirectX_D3D11_1_FOUND 1)
 	endif ()

-	mark_as_advanced(
+	mark_as_advanced (
 		DirectX_D3D_INCLUDE_DIR
 		DirectX_D3D_INCLUDE_DIR
 		DirectX_DDRAW_LIBRARY
@@ -235,10 +238,11 @@
 		DirectX_D3DX11_INCLUDE_DIR
 		DirectX_D3DX11_LIBRARY
 		DirectX_D3D11_1_INCLUDE_DIR
-		DirectX_D3D11_1_LIBRARY
 	)

+
 endif ()
+

 mark_as_advanced (
 	DirectX_D3D_FOUND
@@ -254,3 +258,6 @@
 	DirectX_D3DX11_FOUND
 	DirectX_D3D11_1_FOUND
 )
+
+
+# vim:set sw=4 ts=4 noet:


typo in legacy cmake function for resource install

--- cmake/installFunc.cmake
+++ cmake/installFunc.cmake
@@ -25,7 +25,7 @@
     )
     if (NOT PARSED_ARGS_DIRECTORY)
         message(FATAL_ERROR " [installResources] You must provide a resource directory")
-    endif (NOT PARSED_ARGS_DIRECTORY)
+    endif ()
     get_filename_component(rsc_dir ${PARSED_ARGS_DIRECTORY} NAME)
     get_filename_component(buildtree_dir ${CMAKE_CURRENT_BINARY_DIR} DIRECTORY)
     message(STATUS " [installResources] Linking resources directory ${PARSED_ARGS_DIRECTORY} for target ${PARSED_ARGS_TARGET} into ${buildtree_dir}/Resources/${rsc_dir}")
@@ -35,21 +35,25 @@
         file(CREATE_LINK ${PARSED_ARGS_DIRECTORY} "${buildtree_dir}/Resources/${rsc_dir}" COPY_ON_ERROR SYMBOLIC)
     else ()
         if (MSVC OR MSVC_IDE OR MINGW)
-            add_custom_command(TARGET ${TRGT}
+            add_custom_command(
+                    TARGET ${PARSED_ARGS_TARGET}
                     POST_BUILD
                     COMMAND ${CMAKE_COMMAND} -E copy_directory ${PARSED_ARGS_DIRECTORY} "${buildtree_dir}/Resources/${rsc_dir}"
+                    VERBATIM
                     )
-        else (MSVC OR MSVC_IDE OR MINGW)
-            add_custom_command(TARGET ${TRGT}
+        else ()
+            add_custom_command(
+                    TARGET ${PARSED_ARGS_TARGET}
                     POST_BUILD
                     COMMAND ${CMAKE_COMMAND} -E create_symlink ${PARSED_ARGS_DIRECTORY} "${buildtree_dir}/Resources/${rsc_dir}"
+                    VERBATIM
                     )
-        endif (MSVC OR MSVC_IDE OR MINGW)
-    endif (${CMAKE_VERSION} VERSION_GREATER_EQUAL 3.14)
+        endif ()
+    endif ()
     # build the list of files to install
     if (NOT PARSED_ARGS_FILES)
         file(GLOB_RECURSE PARSED_ARGS_FILES RELATIVE ${PARSED_ARGS_DIRECTORY} ${PARSED_ARGS_DIRECTORY}/*)
-    endif (NOT PARSED_ARGS_FILES)
+    endif ()
     message(STATUS " [installResources] Installing files ${PARSED_ARGS_FILES}")
     foreach (file ${PARSED_ARGS_FILES})
         get_filename_component( file_dir ${file} DIRECTORY )


disabling testing by default, added config option for model repository

--- common/cmake/test.cmake
+++ common/cmake/test.cmake
@@ -14,52 +14,76 @@
 ## limitations under the License.                                           ##
 ## ======================================================================== ##

-ENABLE_TESTING()
+IF(NOT BUILD_TESTING)
+  SET(BUILD_TESTING OFF CACHE BOOL "Build the testing tree.")
+ENDIF()
+
 INCLUDE(CTest)

-SET(EMBREE_MODEL_DIR /Users/swoop/Work/models/embree-models)
+IF (BUILD_TESTING)
+
+  SET(BUILD_TESTING_MODEL_DIR "${PROJECT_SOURCE_DIR}/models" CACHE FILEPATH "Path to the folder containing the Embree models for regression testing.")

-FILE(READ "${EMBREE_MODEL_DIR}/embree-models-subdiv.txt" models_subdiv)
-STRING(REGEX REPLACE "\n" ";" models_subdiv "${models_subdiv}")
-
-FILE(READ "${EMBREE_MODEL_DIR}/embree-models-small-win32.txt" models_small_win32)
-STRING(REGEX REPLACE "\n" ";" models_small_win32 "${models_small_win32}")
-
-FILE(READ "${EMBREE_MODEL_DIR}/embree-models-small-x64.txt" models_small_x64)
-STRING(REGEX REPLACE "\n" ";" models_small_x64 "${models_small_x64}")
-
-FILE(READ "${EMBREE_MODEL_DIR}/embree-models-large.txt" models_large)
-STRING(REGEX REPLACE "\n" ";" models_large "${models_large}")
-
-SET(models ${models_small_win32}) # FIXME: configure all models
-
-#if platform == 'Win32': models += models_small_win32
-#else:                   models += models_small_x64
-#if platform == 'x64' and OS != 'macosx':
-#  models += models_large
-
-MACRO (ADD_EMBREE_TEST name executable)
-  ADD_TEST(NAME ${name}
-           WORKING_DIRECTORY ${PROJECT_BINARY_DIR}
-           COMMAND ${PROJECT_SOURCE_DIR}/scripts/invoke_test.py
-                   --name ${name}
-                   --modeldir ${EMBREE_MODEL_DIR}
-                   --model default
-                   --execute ${PROJECT_BINARY_DIR}/${executable})
-
-ENDMACRO()
-
-MACRO (ADD_EMBREE_MODELS_TEST name executable)
-  FOREACH (model ${models})
-    STRING(REGEX REPLACE "/" "_" modelname "${model}")
-    STRING(REGEX REPLACE ".ecs" "" modelname "${modelname}")
-    ADD_TEST(NAME "${name}_${modelname}"
+  IF(   NOT EXISTS "${BUILD_TESTING_MODEL_DIR}/embree-models-subdiv.txt"
+     OR NOT EXISTS "${BUILD_TESTING_MODEL_DIR}/embree-models-small-win32.txt"
+     OR NOT EXISTS "${BUILD_TESTING_MODEL_DIR}/embree-models-small-x64.txt"
+     OR NOT EXISTS "${BUILD_TESTING_MODEL_DIR}/embree-models-large.txt")
+    MESSAGE(FATAL_ERROR "Invalid Embree testing model repository. Either disable BUILD_TESTING or properly set BUILD_TESTING_MODEL_DIR.")
+  ENDIF()
+
+  FILE(READ "${BUILD_TESTING_MODEL_DIR}/embree-models-subdiv.txt" models_subdiv)
+  STRING(REGEX REPLACE "\n" ";" models_subdiv "${models_subdiv}")
+
+  FILE(READ "${BUILD_TESTING_MODEL_DIR}/embree-models-small-win32.txt" models_small_win32)
+  STRING(REGEX REPLACE "\n" ";" models_small_win32 "${models_small_win32}")
+
+  FILE(READ "${BUILD_TESTING_MODEL_DIR}/embree-models-small-x64.txt" models_small_x64)
+  STRING(REGEX REPLACE "\n" ";" models_small_x64 "${models_small_x64}")
+
+  FILE(READ "${BUILD_TESTING_MODEL_DIR}/embree-models-large.txt" models_large)
+  STRING(REGEX REPLACE "\n" ";" models_large "${models_large}")
+
+  SET(models ${models_small_win32}) # FIXME: configure all models
+
+  #if platform == 'Win32': models += models_small_win32
+  #else:                   models += models_small_x64
+  #if platform == 'x64' and OS != 'macosx':
+  #  models += models_large
+
+  MACRO (ADD_EMBREE_TEST name executable)
+    ADD_TEST(NAME ${name}
              WORKING_DIRECTORY ${PROJECT_BINARY_DIR}
              COMMAND ${PROJECT_SOURCE_DIR}/scripts/invoke_test.py
-                     --name "${name}_${modelname}"
-                     --modeldir ${EMBREE_MODEL_DIR}
-                     --model ${model}
+                     --name ${name}
+                     --modeldir ${BUILD_TESTING_MODEL_DIR}
+                     --model default
                      --execute ${PROJECT_BINARY_DIR}/${executable})
-  ENDFOREACH()
-  SET_TESTS_PROPERTIES("${name}_${modelname}" PROPERTIES ATTACHED_FILES "${name}_${modelname}.jpg")
-ENDMACRO()
+
+    SET_TESTS_PROPERTIES(${name} PROPERTIES ATTACHED_FILES "${name}.jpg")
+
+  ENDMACRO()
+
+  MACRO (ADD_EMBREE_MODELS_TEST name executable)
+    FOREACH (model ${models})
+      STRING(REGEX REPLACE "/" "_" modelname "${model}")
+      STRING(REGEX REPLACE ".ecs" "" modelname "${modelname}")
+      ADD_TEST(NAME "${name}_${modelname}"
+               WORKING_DIRECTORY ${PROJECT_BINARY_DIR}
+               COMMAND ${PROJECT_SOURCE_DIR}/scripts/invoke_test.py
+                       --name "${name}_${modelname}"
+                       --modeldir ${BUILD_TESTING_MODEL_DIR}
+                       --model ${model}
+                       --execute ${PROJECT_BINARY_DIR}/${executable})
+    ENDFOREACH()
+  #  SET_TESTS_PROPERTIES("${name}_${modelname}" PROPERTIES ATTACHED_FILES "${name}_${modelname}.jpg")
+  ENDMACRO()
+
+ELSE()
+
+  MACRO (ADD_EMBREE_TEST name executable)
+  ENDMACRO()
+
+  MACRO (ADD_EMBREE_MODELS_TEST name executable)
+  ENDMACRO()
+
+ENDIF()


support symlink install for config specific targets

--- ament_cmake_core/cmake/symlink_install/ament_cmake_symlink_install_targets.cmake
+++ ament_cmake_core/cmake/symlink_install/ament_cmake_symlink_install_targets.cmake
@@ -86,18 +86,20 @@
     string(REPLACE "\"RUNTIME\" \"DESTINATION\"" "\"RUNTIME_DESTINATION\"" argn_quoted "${argn_quoted}")

     # generate unique files
-    set(generated_file
-      "${CMAKE_CURRENT_BINARY_DIR}/ament_cmake_symlink_install_targets_${__AMENT_CMAKE_SYMLINK_INSTALL_TARGETS_INDEX}.cmake")
+    set(generated_file_base
+      "${CMAKE_CURRENT_BINARY_DIR}/ament_cmake_symlink_install_targets_${__AMENT_CMAKE_SYMLINK_INSTALL_TARGETS_INDEX}")
+    set(generated_file_generator_suffix "${generated_file_base}_$<CONFIG>.cmake")
+    set(generated_file_variable_suffix "${generated_file_base}_\${CMAKE_INSTALL_CONFIG_NAME}.cmake")
     math(EXPR __AMENT_CMAKE_SYMLINK_INSTALL_TARGETS_INDEX
       "${__AMENT_CMAKE_SYMLINK_INSTALL_TARGETS_INDEX} + 1")
     set(__AMENT_CMAKE_SYMLINK_INSTALL_TARGETS_INDEX "${__AMENT_CMAKE_SYMLINK_INSTALL_TARGETS_INDEX}"
       CACHE INTERNAL "Index for unique symlink install targets")

-    file(GENERATE OUTPUT "${generated_file}"
+    file(GENERATE OUTPUT "${generated_file_generator_suffix}"
       CONTENT
-      "ament_cmake_symlink_install_targets(${target_files_quoted} ${argn_quoted})")
+      "ament_cmake_symlink_install_targets(${target_files_quoted} ${argn_quoted})\n")
     ament_cmake_symlink_install_append_install_code(
-      "include(\"${generated_file}\")"
+      "include(\"${generated_file_variable_suffix}\")"
       COMMENTS "install(${argn_quoted})"
     )
   endif()


Update TF version

Update TF version

--- tensorflow_cc/cmake/TensorflowBase.cmake
+++ tensorflow_cc/cmake/TensorflowBase.cmake
@@ -3,7 +3,7 @@
 ExternalProject_Add(
   tensorflow_base
   GIT_REPOSITORY http://github.com/tensorflow/tensorflow.git
-  GIT_TAG v1.5.0-rc1
+  GIT_TAG v1.5.0
   TMP_DIR "/tmp"
   STAMP_DIR "tensorflow-stamp"
   DOWNLOAD_DIR "tensorflow"


Create tbag_modules__apply_soname3() cmake macro.

--- cmake/TbagModules.cmake
+++ cmake/TbagModules.cmake
@@ -244,6 +244,38 @@
         list (APPEND TBAG_PROJECT_LDFLAGS -lpthread) # -pthread
     endif ()
     if (CMAKE_HP_PTHREADS_INIT)
+    endif ()
+endmacro ()
+
+macro (tbag_modules__apply_install_name __dir)
+    if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+        list (APPEND TBAG_PROJECT_LDFLAGS -install_name ${__dir})
+    endif ()
+endmacro ()
+
+macro (tbag_modules__apply_soname __soname)
+    if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
+        list (APPEND TBAG_PROJECT_LDFLAGS -Wl,-soname,${__soname})
+    endif ()
+endmacro ()
+
+macro (tbag_modules__apply_soname2 __lib_name __version)
+    tbag_modules__apply_soname (${CMAKE_SHARED_LIBRARY_PREFIX}${__lib_name}${CMAKE_SHARED_LIBRARY_SUFFIX}.${__version})
+endmacro ()
+
+macro (tbag_modules__apply_soname3 __version)
+    tbag_modules__apply_soname2 (${TBAG_PROJECT_CONST_NAME} ${__version})
+endmacro ()
+
+macro (tbag_modules__apply_current_version __current_version)
+    if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+        list (APPEND TBAG_PROJECT_LDFLAGS -current_version ${__current_version})
+    endif ()
+endmacro ()
+
+macro (tbag_modules__apply_compatibility_version __compatibility_version)
+    if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+        list (APPEND TBAG_PROJECT_LDFLAGS -compatibility_version ${__compatibility_version})
     endif ()
 endmacro ()


fix: bug #5

fix: bug #5

git-svn-id: e7ea667a1d39a4453c4efcc4ba7bca3d620c3f19@141 a9d63959-f2ad-4865-b262-bf0e56cfafb6

--- cmake/pcl_targets.cmake
+++ cmake/pcl_targets.cmake
@@ -78,7 +78,7 @@
     add_library(${_name} ${_lib_type} ${ARGN})
     set_target_properties(${_name} PROPERTIES
         VERSION ${PCL_VERSION}
-        SOVERSION ${PROJECT_MAJOR_VERSION})
+        SOVERSION ${PCL_MAJOR_VERSION})
     install(TARGETS ${_name} LIBRARY DESTINATION ${LIB_INSTALL_DIR}
         ARCHIVE DESTINATION ${LIB_INSTALL_DIR}
         COMPONENT ${_component})


fix: bug #5

fix: bug #5

git-svn-id: 1af002208e930b4d920e7c2b948d1e98a012c795@141 a9d63959-f2ad-4865-b262-bf0e56cfafb6


added clang libraries to unit tests

added clang libraries to unit tests

git-svn-id: e7ea667a1d39a4453c4efcc4ba7bca3d620c3f19@6999 a9d63959-f2ad-4865-b262-bf0e56cfafb6

--- cmake/pcl_targets.cmake
+++ cmake/pcl_targets.cmake
@@ -311,7 +311,7 @@
       set_target_properties(${_exename} PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
     endif(NOT WIN32)
     #target_link_libraries(${_exename} ${GTEST_BOTH_LIBRARIES} ${PCL_ADD_TEST_LINK_WITH})
-    target_link_libraries(${_exename} ${PCL_ADD_TEST_LINK_WITH})
+    target_link_libraries(${_exename} ${PCL_ADD_TEST_LINK_WITH} ${CLANG_LIBRARIES})
     #
     # Only link if needed
     if(CMAKE_SYSTEM_NAME STREQUAL "Darwin")


Apply cmake-init 400f3654f4b77f3d745c6b48d5f40ef09dbf0598

--- deploy/packages/pack-globjects.cmake
+++ deploy/packages/pack-globjects.cmake
@@ -47,21 +47,29 @@
 # Package components
 #

-set(CPACK_COMPONENTS_ALL runtime dev examples docs)
-
-set(CPACK_COMPONENT_RUNTIME_DISPLAY_NAME "globjects libraries")
-set(CPACK_COMPONENT_RUNTIME_DESCRIPTION "Runtime components for the globjects libraries")
+set(CPACK_COMPONENT_RUNTIME_DISPLAY_NAME "${META_PROJECT_NAME} library")
+set(CPACK_COMPONENT_RUNTIME_DESCRIPTION "Runtime components for ${META_PROJECT_NAME} library")

 set(CPACK_COMPONENT_DEV_DISPLAY_NAME "C/C++ development files")
-set(CPACK_COMPONENT_DEV_DESCRIPTION "Development files for the globjects libraries")
+set(CPACK_COMPONENT_DEV_DESCRIPTION "Development files for ${META_PROJECT_NAME} library")
 set(CPACK_COMPONENT_DEV_DEPENDS runtime)

-set(CPACK_COMPONENT_EXAMPLES_DISPLAY_NAME "Example applications")
-set(CPACK_COMPONENT_EXAMPLES_DESCRIPTION "Example applications for the globjects libraries")
-set(CPACK_COMPONENT_EXAMPLES_DEPENDS runtime)
-
-set(CPACK_COMPONENT_DOCS_DISPLAY_NAME "Documentation")
-set(CPACK_COMPONENT_DOCS_DESCRIPTION "Documentation of the globjects libraries")
+set(CPACK_COMPONENTS_ALL runtime dev)
+
+if (OPTION_BUILD_EXAMPLES)
+    set(CPACK_COMPONENT_EXAMPLES_DISPLAY_NAME "Example applications")
+    set(CPACK_COMPONENT_EXAMPLES_DESCRIPTION "Example applications for ${META_PROJECT_NAME} library")
+    set(CPACK_COMPONENT_EXAMPLES_DEPENDS runtime)
+
+    set(CPACK_COMPONENTS_ALL ${CPACK_COMPONENTS_ALL} examples)
+endif()
+
+if (OPTION_BUILD_DOCS)
+    set(CPACK_COMPONENT_DOCS_DISPLAY_NAME "Documentation")
+    set(CPACK_COMPONENT_DOCS_DESCRIPTION "Documentation of ${META_PROJECT_NAME} library")
+
+    set(CPACK_COMPONENTS_ALL ${CPACK_COMPONENTS_ALL} docs)
+endif()

 #
@@ -122,7 +130,7 @@
 set(CPACK_RESOURCE_FILE_README                 "${PROJECT_SOURCE_DIR}/README.md")
 set(CPACK_RESOURCE_FILE_WELCOME                "${PROJECT_SOURCE_DIR}/README.md")
 set(CPACK_PACKAGE_DESCRIPTION_FILE             "${PROJECT_SOURCE_DIR}/README.md")
-# set(CPACK_PACKAGE_ICON                         "${PROJECT_SOURCE_DIR}/deploy/images/logo.bmp")
+set(CPACK_PACKAGE_ICON                         "${PROJECT_SOURCE_DIR}/deploy/images/logo.bmp")
 set(CPACK_PACKAGE_FILE_NAME                    "${package_name}-${CPACK_PACKAGE_VERSION}")
 set(CPACK_PACKAGE_INSTALL_DIRECTORY            "${package_name}")
 set(CPACK_PACKAGE_INSTALL_REGISTRY_KEY         "${package_name}")


Fix a problem when cross compiling using NMake.

The previous behaviour was to add a CXX flags when
msdev/devenv/nmake/VCExpress was detected.
However these tools have nothing to do with the compiler used.
The /W4 applies only when CL (aka MS-VC) is the current compiler.
It avoids a compilation issue when nmake is used with another
toolchain than the MS one (eg. the Android NDK which is base on GCC,
and of course GCC do not know the /W4 flag!).
Use MSVC instead of MSVC_VERSION variable to do the test.

Change-Id: I287796dcba9c39a8f912db10bd8b8f527a544bdb

--- CMake/vtkDetermineCompilerFlags.cmake
+++ CMake/vtkDetermineCompilerFlags.cmake
@@ -101,15 +101,15 @@
 ENDIF(_MAY_BE_INTEL_COMPILER)

-IF(CMAKE_BUILD_TOOL MATCHES "(msdev|devenv|nmake|VCExpress)")
-# Use the highest warning level for visual studio.
+IF(MSVC)
+# Use the highest warning level for visual c++ compiler.
   SET(CMAKE_CXX_WARNING_LEVEL 4)
   IF(CMAKE_CXX_FLAGS MATCHES "/W[0-4]")
     STRING(REGEX REPLACE "/W[0-4]" "/W4" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
   ELSE(CMAKE_CXX_FLAGS MATCHES "/W[0-4]")
     SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /W4")
   ENDIF(CMAKE_CXX_FLAGS MATCHES "/W[0-4]")
-ENDIF(CMAKE_BUILD_TOOL MATCHES "(msdev|devenv|nmake|VCExpress)")
+ENDIF(MSVC)

 # Disable deprecation warnings for standard C and STL functions in VS2005
 # and later


[cmake] Expand $(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) in LLVM CMake paths.

In order to support swapping build types without reconfiguring, Swift's CMake
generated Xcode project has one directory for each cmake build type. This
behavior is implemented by placing in variables for Xcode to expand at build
time. This causes issues with our build, namely that our cmake scripts like to
"poke" around the LLVM build directory at configure time. Since the xcode
variables from the commit title are not expanded, failures occur since the
unexpanded paths do not exist.

This patch fixes this problem by expanding out those variables at configure time
from specific LLVM paths. This is essentially tieing LLVM to the specific
build-script build mode used. This is reasonable since we do not support
building in Xcode for configurations that were not selected at build-script
time.

rdar://27062396

--- cmake/modules/SwiftSharedCMakeConfig.cmake
+++ cmake/modules/SwiftSharedCMakeConfig.cmake
@@ -11,6 +11,34 @@
 else()
   set(cmake_3_2_USES_TERMINAL USES_TERMINAL)
 endif()
+
+function(get_effective_platform_for_triple triple output)
+  string(FIND "${triple}" "macos" IS_MACOS)
+  if (IS_MACOS)
+    set(${output} "" PARENT_SCOPE)
+    return()
+  endif()
+  message(FATAL_ERROR "Not supported")
+endfunction()
+
+# Eliminate $(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) from a path.
+#
+# We do not support compiling llvm with an Xcode setting beyond the one that was
+# used with build-script. This allows us to remove those paths. Right now,
+# nothing here is tested for cross compiling with Xcode, but it is in principal
+# possible.
+function(escape_llvm_path_for_xcode path outvar)
+  # First check if we are using Xcode. If not, return early.
+  if (NOT XCODE)
+    set(${outvar} "${path}" PARENT_SCOPE)
+    return()
+  endif()
+
+  get_effective_platform_for_triple("${SWIFT_HOST_TRIPLE}" SWIFT_EFFECTIVE_PLATFORM_NAME)
+  string(REPLACE "$(CONFIGURATION)" "${LLVM_BUILD_TYPE}" path "${path}")
+  string(REPLACE "$(EFFECTIVE_PLATFORM_NAME)" "${SWIFT_EFFECTIVE_PLATFORM_NAME}" path "${path}")
+  set(${outvar} "${path}" PARENT_SCOPE)
+endfunction()

 macro(swift_common_standalone_build_config_llvm product is_cross_compiling)
   option(LLVM_ENABLE_WARNINGS "Enable compiler warnings." ON)
@@ -55,20 +83,23 @@
   mark_as_advanced(LLVM_ENABLE_ASSERTIONS)

   precondition(LLVM_TOOLS_BINARY_DIR)
+  escape_llvm_path_for_xcode("${LLVM_TOOLS_BINARY_DIR}" LLVM_TOOLS_BINARY_DIR)
   precondition_translate_flag(LLVM_BUILD_LIBRARY_DIR LLVM_LIBRARY_DIR)
+  escape_llvm_path_for_xcode("${LLVM_LIBRARY_DIR}" LLVM_LIBRARY_DIR)
   precondition_translate_flag(LLVM_BUILD_MAIN_INCLUDE_DIR LLVM_MAIN_INCLUDE_DIR)
   precondition_translate_flag(LLVM_BUILD_BINARY_DIR LLVM_BINARY_DIR)
   precondition_translate_flag(LLVM_BUILD_MAIN_SRC_DIR LLVM_MAIN_SRC_DIR)
-
-  if(${is_cross_compiling})
-    find_program(SWIFT_TABLEGEN_EXE "llvm-tblgen" "${${product}_NATIVE_LLVM_TOOLS_PATH}"
-      NO_DEFAULT_PATH)
-    if ("${SWIFT_TABLEGEN_EXE}" STREQUAL "SWIFT_TABLEGEN_EXE-NOTFOUND")
-      message(FATAL_ERROR "Failed to find tablegen in ${${product}_NATIVE_LLVM_TOOLS_PATH}")
-    endif()
-  else()
-    set(SWIFT_TABLEGEN_EXE llvm-tblgen)
-    set(${product}_NATIVE_LLVM_TOOLS_PATH "${PATH_TO_LLVM_TOOLS_BINARY_DIR}")
+  precondition(LLVM_LIBRARY_DIRS)
+  escape_llvm_path_for_xcode("${LLVM_LIBRARY_DIRS}" LLVM_LIBRARY_DIRS)
+
+  if(NOT ${is_cross_compiling})
+    set(${product}_NATIVE_LLVM_TOOLS_PATH "${LLVM_TOOLS_BINARY_DIR}")
+  endif()
+
+  find_program(SWIFT_TABLEGEN_EXE "llvm-tblgen" "${${product}_NATIVE_LLVM_TOOLS_PATH}"
+    NO_DEFAULT_PATH)
+  if ("${SWIFT_TABLEGEN_EXE}" STREQUAL "SWIFT_TABLEGEN_EXE-NOTFOUND")
+    message(FATAL_ERROR "Failed to find tablegen in ${${product}_NATIVE_LLVM_TOOLS_PATH}")
   endif()

   include(AddLLVM)
@@ -86,6 +117,7 @@
     "Version number that will be placed into the libclang library , in the form XX.YY")

   foreach (INCLUDE_DIR ${LLVM_INCLUDE_DIRS})
+    escape_llvm_path_for_xcode("${INCLUDE_DIR}" INCLUDE_DIR)
     include_directories(${INCLUDE_DIR})
   endforeach ()

@@ -144,7 +176,7 @@
   set(CLANG_BUILD_INCLUDE_DIR "${PATH_TO_CLANG_BUILD}/tools/clang/include")

   if (NOT ${is_cross_compiling})
-    set(${product}_NATIVE_CLANG_TOOLS_PATH "${PATH_TO_LLVM_TOOLS_BINARY_DIR}")
+    set(${product}_NATIVE_CLANG_TOOLS_PATH "${LLVM_TOOLS_BINARY_DIR}")
   endif()

   set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include")


CMake: Improve renaming

CMake: Improve renaming

git-svn-id: 31d9d2f6432a47c86a3640814024c107794ea77c@30010 0785d39b-7218-0410-832d-ea1e28bc413d

--- deal.II/cmake/setup_cached_variables.cmake
+++ deal.II/cmake/setup_cached_variables.cmake
@@ -299,20 +299,18 @@
 GET_CMAKE_PROPERTY(_res VARIABLES)
 FOREACH(_var ${_res})
   #
-  # Rename WITH_* by DEAL_II_WITH_*
-  #
-  IF(_var MATCHES "^WITH_")
-    SET(DEAL_II_${_var} ${${_var}} CACHE BOOL "" FORCE)
-    UNSET(${_var} CACHE)
-  ENDIF()
+  # Rename (ALLOW|WITH|FORCE|COMPONENT)_* by DEAL_II_(ALLOW|WITH|FORCE|COMPONENT)_*
+  #
+  FOREACH(_match ALLOW_ WITH_ FORCE_ COMPONENT_)
+    IF(_var MATCHES "^${_match}")
+      SET(DEAL_II_${_var} ${${_var}} CACHE BOOL "" FORCE)
+      UNSET(${_var} CACHE)
+    ENDIF()
+  ENDFOREACH()

   #
   # Same for components:
   #
-  IF(_var MATCHES "^COMPONENT_")
-    SET(DEAL_II_${_var} ${${_var}} CACHE BOOL "" FORCE)
-    UNSET(${_var} CACHE)
-  ENDIF()
   IF(_var MATCHES "^(COMPAT_FILES|DOCUMENTATION|EXAMPLES|MESH_CONVERTER|PARAMETER_GUI)")
     SET(DEAL_II_COMPONENT_${_var} ${${_var}} CACHE BOOL "" FORCE)
     UNSET(${_var} CACHE)


toolchain-pc.cmake: small fixes

toolchain-pc.cmake: small fixes

--- cmake/qibuild/templates/toolchain-pc.cmake
+++ cmake/qibuild/templates/toolchain-pc.cmake
@@ -6,18 +6,26 @@

 # Warning ! This file is NOT usable for cross-compilation

-# Set _ROOT_DIR to the dirname of this file (/path/to/sdk)
-get_filename_component(_ROOT_DIR ${CMAKE_CURRENT_LIST_FILE} PATH)
+# Set _SDK_ROOT_DIR to the dirname of this file (/path/to/sdk)
+get_filename_component(_SDK_ROOT_DIR ${CMAKE_CURRENT_LIST_FILE} PATH)

 # Librairies are looked for in /path/to/sdk/lib,
-# headers in /path/to/include, and so on.
-set(CMAKE_FIND_ROOT_PATH "${_ROOT_DIR}")
+# headers in /path/to/sdk/include, and so on.
+set(CMAKE_FIND_ROOT_PATH "${_SDK_ROOT_DIR}")

 # Path to the qibuild framework:
-list(APPEND CMAKE_MODULE_PATH "${_ROOT_DIR}/share/cmake")
+list(APPEND CMAKE_MODULE_PATH "${_SDK_ROOT_DIR}/share/cmake")

 # Enable usage of the qi_ cmake functions:
 include(qibuild/general)

 # Enable backward compatibility:
 include(qibuild/compat/compat)
+
+# Force 32 bits compilation even if we are on a
+# 64 bits OS:
+set(CMAKE_OSX_ARCHITECTURES i386 CACHE INTERNAL "" FORCE)
+
+# By default, generate output of the compilation in this SDK.
+# This is useful for naoqi to find the module you've just compiled
+set(QI_SDK_DIR "${_SDK_ROOT_DIR}" CACHE INTERNAL "" FORCE)


Only display actually included modules in the CMake log (closing #122)

--- support/cmake/support_macros.cmake
+++ support/cmake/support_macros.cmake
@@ -363,7 +363,10 @@

     message(STATUS "Included modules:")
     foreach (module ${sortedModules})
-        message(STATUS "\t${module}")
+        create_option_name(${module} optionName)
+        if (${optionName})
+            message(STATUS "\t${module}")
+        endif ()
     endforeach ()

     # Add subdirectories in the correct order


Enable Edit and Continue feature

Enable Edit and Continue feature

--- support/cmake/support_macros.cmake
+++ support/cmake/support_macros.cmake
@@ -68,7 +68,12 @@
     set_property(TARGET ${project} PROPERTY CXX_STANDARD_REQUIRED On)

     if (MSVC)
-        target_compile_options(${project} PUBLIC "/MP" "/wd4201" "/wd4127")
+        target_compile_options(${project} PUBLIC
+            "/MP"       # Multi-threading support
+            "/ZI"       # Edit and continue support
+            "/wd4201"   # Disable "nameless struct" warning
+            "/wd4127"   # Disable "conditional expression is constant" warning
+        )
         if (OPENSPACE_WARNINGS_AS_ERRORS)
             target_compile_options(${project} PUBLIC "/WX")
         endif ()


DTK tools should be built for mac, removing option

--- cmake/externals/projects_modules/dtk.cmake
+++ cmake/externals/projects_modules/dtk.cmake
@@ -86,7 +86,6 @@
   -DQT_QMAKE_EXECUTABLE:FILEPATH=${QT_QMAKE_EXECUTABLE}
   -DDTK_BUILD_COMPOSER:BOOL=${BUILD_DTK_COMPOSER}
   -DDTK_HAVE_NITE:BOOL=OFF
-  -DDTK_BUILD_TOOLS:BOOL=OFF
   )


[cmake] When not cross compiling, instead of searching for llvm-tblgen, just use the real native cmake target.

This fixes part of the Xcode build by allowing us to avoid having to use cmake
variables with an unexpanded CMAKE_CFG_INTDIR.

Since those variables are not expanded, they point to a non-existant path like:

.../$(CONFIGURATION)$(...)/lib

So finding tablegen fails. In the cross compile case, we still try to find the
native tablegen.

rdar://26154980

--- cmake/modules/SwiftSharedCMakeConfig.cmake
+++ cmake/modules/SwiftSharedCMakeConfig.cmake
@@ -26,15 +26,6 @@

   precondition_translate_flag(${product}_PATH_TO_LLVM_SOURCE PATH_TO_LLVM_SOURCE)
   precondition_translate_flag(${product}_PATH_TO_LLVM_BUILD PATH_TO_LLVM_BUILD)
-  set(PATH_TO_LLVM_TOOLS_BINARY_DIR "${PATH_TO_LLVM_BUILD}/bin")
-
-  if(NOT ${is_cross_compiling})
-    set(${product}_NATIVE_LLVM_TOOLS_PATH "${PATH_TO_LLVM_TOOLS_BINARY_DIR}")
-    set(${product}_NATIVE_CLANG_TOOLS_PATH "${PATH_TO_LLVM_TOOLS_BINARY_DIR}")
-  endif()
-
-  find_program(LLVM_TABLEGEN_EXE "llvm-tblgen" "${${product}_NATIVE_LLVM_TOOLS_PATH}"
-    NO_DEFAULT_PATH)

   set(LLVM_CMAKE_PATHS
       "${PATH_TO_LLVM_BUILD}/share/llvm/cmake"
@@ -125,6 +116,18 @@
   endif()

   list(APPEND CMAKE_MODULE_PATH "${${product}_PATH_TO_LLVM_BUILD}/share/llvm/cmake")
+
+  if(${is_cross_compiling})
+    find_program(LLVM_TABLEGEN_EXE "llvm-tblgen" "${${product}_NATIVE_LLVM_TOOLS_PATH}"
+      NO_DEFAULT_PATH)
+    if ("${LLVM_TABLEGEN_EXE}" STREQUAL "LLVM_TABLEGEN_EXE-NOTFOUND")
+      message(FATAL_ERROR "Failed to find tablegen in ${${product}_NATIVE_LLVM_TOOLS_PATH}")
+    endif()
+  else()
+    set(LLVM_TABLEGEN_EXE llvm-tblgen)
+    set(${product}_NATIVE_LLVM_TOOLS_PATH "${PATH_TO_LLVM_TOOLS_BINARY_DIR}")
+    set(${product}_NATIVE_CLANG_TOOLS_PATH "${PATH_TO_LLVM_TOOLS_BINARY_DIR}")
+  endif()

   include(AddLLVM)
   include(TableGen)


set LANG=en_US to get the expected output

--- test.cmake
+++ test.cmake
@@ -8,6 +8,9 @@
 endif()
 set(target_architecture "$ENV{target_architecture}")
 set(skip_tests "$ENV{skip_tests}")
+
+# better make sure we get english output (this is vital for the implicit_type_conversion_failures tests)
+set(ENV{LANG} "en_US")

 find_program(UNAME uname)
 if(UNAME)


multi-jobs build options

multi-jobs build options

--- project/cmake/modules/FindConfigurePackage.cmake
+++ project/cmake/modules/FindConfigurePackage.cmake
@@ -89,6 +89,25 @@
         endif()
     endif()
 endfunction()
+
+if (CMAKE_VERSION VERSION_GREATER_EQUAL "3.12")
+    include(ProcessorCount)
+    ProcessorCount(CPU_CORE_NUM)
+    set(FindConfigurePackageCMakeBuildMultiJobs "--parallel" ${CPU_CORE_NUM} CACHE INTERNAL "Build options for multi-jobs")
+    unset(CPU_CORE_NUM)
+elseif ( (CMAKE_MAKE_PROGRAM STREQUAL "make") OR (CMAKE_MAKE_PROGRAM STREQUAL "gmake") OR (CMAKE_MAKE_PROGRAM STREQUAL "ninja") )
+    include(ProcessorCount)
+    ProcessorCount(CPU_CORE_NUM)
+    set(FindConfigurePackageCMakeBuildMultiJobs "--" "-j${CPU_CORE_NUM}" CACHE INTERNAL "Build options for multi-jobs")
+    unset(CPU_CORE_NUM)
+elseif ( CMAKE_MAKE_PROGRAM STREQUAL "xcodebuild" )
+    include(ProcessorCount)
+    ProcessorCount(CPU_CORE_NUM)
+    set(FindConfigurePackageCMakeBuildMultiJobs "--" "-jobs" ${CPU_CORE_NUM} CACHE INTERNAL "Build options for multi-jobs")
+    unset(CPU_CORE_NUM)
+elseif (CMAKE_VS_MSBUILD_COMMAND)
+    set(FindConfigurePackageCMakeBuildMultiJobs "--" "/m" CACHE INTERNAL "Build options for multi-jobs")
+endif()

 macro (FindConfigurePackage)
     include(CMakeParseArguments)
@@ -315,14 +334,6 @@
                     WORKING_DIRECTORY ${FindConfigurePackage_BUILD_DIRECTORY}
                 )

-                if (MSVC)
-                    set(FindConfigurePackage_BUILD_WITH_CMAKE_MULTI_CORE_BUILD_FLAG "--" "/m")
-                else ()
-                    include(ProcessorCount)
-                    ProcessorCount(CPU_CORE_NUM)
-                    set(FindConfigurePackage_BUILD_WITH_CMAKE_MULTI_CORE_BUILD_FLAG "--" "-j${CPU_CORE_NUM}")
-                endif ()
-
                 # cmake --build and install
                 if(MSVC)
                     if (NOT FindConfigurePackage_MSVC_CONFIGURE)
@@ -330,13 +341,13 @@
                     endif()
                     execute_process(
                         COMMAND ${CMAKE_COMMAND} --build . --target install --config ${FindConfigurePackage_MSVC_CONFIGURE}
-                            ${FindConfigurePackage_BUILD_WITH_CMAKE_MULTI_CORE_BUILD_FLAG}
+                            ${FindConfigurePackageCMakeBuildMultiJobs}
                         WORKING_DIRECTORY ${FindConfigurePackage_BUILD_DIRECTORY}
                     )
                 else()
                     execute_process(
                         COMMAND ${CMAKE_COMMAND} --build . --target install
-                            ${FindConfigurePackage_BUILD_WITH_CMAKE_MULTI_CORE_BUILD_FLAG}
+                            ${FindConfigurePackageCMakeBuildMultiJobs}
                         WORKING_DIRECTORY ${FindConfigurePackage_BUILD_DIRECTORY}
                     )
                 endif()


Sync file

Sync file

svn path=/trunk/kdesupport/strigi/; revision=811132

--- cmake/FindCLucene.cmake
+++ cmake/FindCLucene.cmake
@@ -19,9 +19,6 @@
 if(NOT CLUCENE_MAX_SUPPORTED_VERSION)
   set(CLUCENE_MAX_SUPPORTED_VERSION "0.9.17")
 endif(NOT CLUCENE_MAX_SUPPORTED_VERSION)
-
-MESSAGE(STATUS "min version ${CLUCENE_MIN_VERSION}")
-

 IF(EXISTS ${PROJECT_CMAKE}/CLuceneConfig.cmake)
   INCLUDE(${PROJECT_CMAKE}/CLuceneConfig.cmake)


Fix FindDataMan.cmake missing include.

Fix FindDataMan.cmake missing include.

FindPackageHandleStandardArgs needs to be included in every find module
that the find_package_handle_standard_args is used.  I was getting
transitively included by othger find modules before but when all other
options are turned off except DataMan, it's missing.  This ensures it's
always included before calling find_package_handle_standard_args.

--- cmake/FindDataMan.cmake
+++ cmake/FindDataMan.cmake
@@ -51,6 +51,7 @@
   find_library(DataMan_LIBRARY dataman ${_DataMan_LIBRARY_HINT})
   unset(_DataMan_LIBRARY_HINT)

+  include(FindPackageHandleStandardArgs)
   find_package_handle_standard_args(DataMan
     FOUND_VAR DataMan_FOUND
     REQUIRED_VARS


Add hint cache to Findpanda3d

Add hint cache to Findpanda3d

--- cmake/Findpanda3d.cmake
+++ cmake/Findpanda3d.cmake
@@ -190,8 +190,10 @@
         set(_panda3d_new_found_components ${_panda3d_new_found_components} panda3d::${component_name} PARENT_SCOPE)

         # Make variables changeable to the advanced user
-        mark_as_advanced(panda3d_${component_name}_LIBRARY_RELEASE)
-        mark_as_advanced(panda3d_${component_name}_LIBRARY_DEBUG)
+        mark_as_advanced(
+            panda3d_${component_name}_LIBRARY_DEBUG
+            panda3d_${component_name}_LIBRARY_RELEASE
+        )
     endif()
 endfunction()

@@ -204,6 +206,10 @@
 if(panda3d_ROOT AND NOT panda3d_ROOT_DEBUG)
     set(panda3d_ROOT_DEBUG "${panda3d_ROOT}")
 endif()
+
+set(panda3d_ROOT "${panda3d_ROOT}" CACHE PATH "Hint for finding panda3d root directory")
+set(panda3d_ROOT_DEBUG "${panda3d_ROOT_DEBUG}" CACHE PATH "Hint for finding panda3d-debug root directory")
+set(panda3d_ROOT_RELEASE "${panda3d_ROOT_RELEASE}" CACHE PATH "Hint for finding panda3d-release root directory")

 _panda3d_find_include()

@@ -235,7 +241,11 @@
         )
     endif()

-    mark_as_advanced(panda3d_INCLUDE_DIR)
-    mark_as_advanced(panda3d_INCLUDE_DIR_DEBUG)
-    mark_as_advanced(panda3d_INCLUDE_DIR_RELEASE)
+    mark_as_advanced(
+        panda3d_INCLUDE_DIR
+        panda3d_INCLUDE_DIR_DEBUG
+        panda3d_INCLUDE_DIR_RELEASE
+        panda3d_ROOT_DEBUG
+        panda3d_ROOT_RELEASE
+    )
 endif()


cmake: use relative path for mode vars

cmake: use relative path for mode vars

--- cmake/OpenCVUtils.cmake
+++ cmake/OpenCVUtils.cmake
@@ -1978,4 +1978,4 @@
 #
 # Include configuration override settings
 #
-include(cmake/vars/EnableModeVars.cmake)
+include("${CMAKE_CURRENT_LIST_DIR}/vars/EnableModeVars.cmake")


Fix a bug in PostInstall.cmake and mention issues.

--- cmake/PostInstall.cmake
+++ cmake/PostInstall.cmake
@@ -1,4 +1,5 @@
-# Copy dependencies into the install directory in Linux for quick and dirty distribution.
+# Copy dependencies into the install directory in Linux for quick and dirty
+# distribution.
 #
 # This assumes a standard distribution, i.e.
 #   install(TARGETS ...
@@ -22,6 +23,17 @@
 #
 # Now when you run `make install', it will call this script afterwards and
 # copy dependencies, just like is done with CMake-OSX's FixupBundle.
+#
+# Issues
+# -----
+# Determining system libraries is not foolproof so we make our own list. Look
+# for the known_system_libraries and add your own to the list.
+#
+# While this script does the job of copying libraries, you need to also set the
+# RPATH on the copies yourself. Check out the awesome `patchelf' utility for
+# this purpose at
+#
+#   git@github.com:NixOS/patchelf.git

 message(STATUS "FOOBAR")
 include(GetPrerequisites)
@@ -64,6 +76,8 @@
         set(known_system_libraries ${known_system_libraries} "libgcc_s.so")
         set(known_system_libraries ${known_system_libraries} "libm.so")
         set(known_system_libraries ${known_system_libraries} "libstdc++.so")
+        set(known_system_libraries ${known_system_libraries} "libGL.so")
+        set(known_system_libraries ${known_system_libraries} "libnvidia")
         get_prerequisites("${fullexepath}" prereqs ${do_not_exclude_system_libraries} ${recursive_mode_on} "${exepath}" "")
         foreach(pr ${prereqs})
             get_filename_component(item_name "${pr}" NAME)
@@ -187,6 +201,6 @@
 # Wow this is null
 #message(STATUS ${PROJECT_SOURCE_DIR})
 include("${PROJECT_DIR}/.build_targets")
-get_project_keys(my_targets BUILD_TARGETS)
+get_project_keys(BUILD_TARGETS keys)
 copy_project_keys(keys)
 clear_project_keys(keys)


gtest 1.5 fix (again)

gtest 1.5 fix (again)

git-svn-id: e7ea667a1d39a4453c4efcc4ba7bca3d620c3f19@738 a9d63959-f2ad-4865-b262-bf0e56cfafb6

--- cmake/pcl_targets.cmake
+++ cmake/pcl_targets.cmake
@@ -135,8 +135,6 @@
     add_executable(${_exename} ${PCL_ADD_TEST_FILES})
     PCL_ADD_OPENMP_FLAGS(${_exename})
     target_link_libraries(${_exename} ${GTEST_BOTH_LIBRARIES} ${PCL_ADD_TEST_LINK_WITH})
-    # must link explicitly against boost only on Windows
-    target_link_libraries(${_exename} ${Boost_LIBRARIES})
     #
     # Only link if needed
     if(UNIX)
@@ -148,7 +146,9 @@
     endif()
     #
     PCL_LINK_OPENMP(${_exename})
-
+    # must link explicitly against boost only on Windows
+    target_link_libraries(${_exename} ${Boost_LIBRARIES})
+    #
     if(${CMAKE_VERSION} VERSION_LESS 2.8.4)
       add_test(${_name} ${_exename} ${PCL_ADD_TEST_ARGUMENTS})
     else(${CMAKE_VERSION} VERSION_LESS 2.8.4)


fix xpSourceListAppend (check if git repo), rm SunOS conditional

--- modules/xpfunmac.cmake
+++ modules/xpfunmac.cmake
@@ -851,44 +851,42 @@
     set(masterSrcList "${masterSrcList}" PARENT_SCOPE)
   else()
     list(REMOVE_DUPLICATES masterSrcList)
-    ####
-    xpGitIgnoredDirs(ignoredDirs ${CMAKE_SOURCE_DIR} .git/)
-    xpGitUntrackedFiles(untrackedFiles ${CMAKE_SOURCE_DIR})
-    file(GLOB topdir ${_dir}/*)
-    xpListAppendTrailingSlash(topdir ${topdir})
-    list(REMOVE_ITEM topdir ${ignoredDirs} ${untrackedFiles})
-    list(SORT topdir) # sort list in-place alphabetically
-    foreach(item ${topdir})
-      xpGlobFiles(repoFiles ${item} *)
-      xpGlobFiles(fmtFiles ${item} *.c *.h *.cpp *.hpp *.cu *.cuh *.proto)
-    endforeach()
-    list(REMOVE_ITEM repoFiles ${masterSrcList})
-    if(repoFiles)
-      string(REPLACE ";" "\n" repoFiles "${repoFiles}")
-      file(WRITE ${CMAKE_BINARY_DIR}/notincmake.txt ${repoFiles}\n)
-      list(APPEND masterSrcList ${CMAKE_BINARY_DIR}/notincmake.txt)
-    endif()
-    ####
-    # Windows can't handle passing very many files to clang-format
-    # and Solaris/SunOS can't build clang-format
-    if(NOT MSVC AND NOT ${CMAKE_SYSTEM_NAME} STREQUAL SunOS
-       AND fmtFiles AND NOT ${CMAKE_PROJECT_NAME} STREQUAL externpro)
-      # make paths relative to CMAKE_SOURCE_DIR
-      xpListRemoveFromAll(fmtFiles ${CMAKE_SOURCE_DIR} . ${fmtFiles})
-      list(LENGTH fmtFiles lenFmtFiles)
-      xpGetPkgVar(clangformat EXE)
-      add_custom_command(OUTPUT format_cmake
-        COMMAND ${CLANGFORMAT_EXE} -style=file -i ${fmtFiles}
-        WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
-        COMMENT "Running clang-format on ${lenFmtFiles} files..."
-        )
-      string(REPLACE ";" "\n" fmtFiles "${fmtFiles}")
-      file(WRITE ${CMAKE_BINARY_DIR}/formatfiles.txt ${fmtFiles}\n)
-      add_custom_target(format SOURCES ${CMAKE_BINARY_DIR}/formatfiles.txt DEPENDS format_cmake)
-      list(APPEND masterSrcList ${CMAKE_BINARY_DIR}/formatfiles.txt)
-      set_property(TARGET format PROPERTY FOLDER CMakeTargets)
-    endif()
-    ####
+    if(EXISTS ${CMAKE_SOURCE_DIR}/.git)
+      xpGitIgnoredDirs(ignoredDirs ${CMAKE_SOURCE_DIR} .git/)
+      xpGitUntrackedFiles(untrackedFiles ${CMAKE_SOURCE_DIR})
+      file(GLOB topdir ${_dir}/*)
+      xpListAppendTrailingSlash(topdir ${topdir})
+      list(REMOVE_ITEM topdir ${ignoredDirs} ${untrackedFiles})
+      list(SORT topdir) # sort list in-place alphabetically
+      foreach(item ${topdir})
+        xpGlobFiles(repoFiles ${item} *)
+        xpGlobFiles(fmtFiles ${item} *.c *.h *.cpp *.hpp *.cu *.cuh *.proto)
+      endforeach()
+      list(REMOVE_ITEM repoFiles ${masterSrcList})
+      if(repoFiles)
+        string(REPLACE ";" "\n" repoFiles "${repoFiles}")
+        file(WRITE ${CMAKE_BINARY_DIR}/notincmake.txt ${repoFiles}\n)
+        list(APPEND masterSrcList ${CMAKE_BINARY_DIR}/notincmake.txt)
+      endif()
+      ####
+      # Windows can't handle passing very many files to clang-format
+      if(NOT MSVC AND fmtFiles AND NOT ${CMAKE_PROJECT_NAME} STREQUAL externpro)
+        # make paths relative to CMAKE_SOURCE_DIR
+        xpListRemoveFromAll(fmtFiles ${CMAKE_SOURCE_DIR} . ${fmtFiles})
+        list(LENGTH fmtFiles lenFmtFiles)
+        xpGetPkgVar(clangformat EXE)
+        add_custom_command(OUTPUT format_cmake
+          COMMAND ${CLANGFORMAT_EXE} -style=file -i ${fmtFiles}
+          WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
+          COMMENT "Running clang-format on ${lenFmtFiles} files..."
+          )
+        string(REPLACE ";" "\n" fmtFiles "${fmtFiles}")
+        file(WRITE ${CMAKE_BINARY_DIR}/formatfiles.txt ${fmtFiles}\n)
+        add_custom_target(format SOURCES ${CMAKE_BINARY_DIR}/formatfiles.txt DEPENDS format_cmake)
+        list(APPEND masterSrcList ${CMAKE_BINARY_DIR}/formatfiles.txt)
+        set_property(TARGET format PROPERTY FOLDER CMakeTargets)
+      endif()
+    endif() # is a .git repo
     option(XP_CSCOPE "always update cscope database" OFF)
     if(XP_CSCOPE)
       file(GLOB cscope_files ${CMAKE_BINARY_DIR}/cscope.*)


Search for Qsci/qsciapis.h.

Search for Qsci/qsciapis.h.

	* build-aux/cmake/modules/FindQScintilla2.cmake: Do that.

Signed-off-by: Nicolas Despres <abdeb541ca46f1651c9cc594d44e707056e73d5d@gostai.com>

--- build-aux/cmake/modules/FindQScintilla2.cmake
+++ build-aux/cmake/modules/FindQScintilla2.cmake
@@ -42,10 +42,10 @@
   # Search for the include directory.
   if(NOT QSCINTILLA2_INCLUDE_DIR)
     find_path(QSCINTILLA2_INCLUDE_DIR
-      NAMES Qsci
+      NAMES Qsci/qsciapis.h
       PATHS ${QT_INCLUDE_DIR} ${QSCINTILLA2_ROOT_DIR}/include)
     if(QSCINTILLA2_INCLUDE_DIR)
-      message(STATUS "Found qscintilla2 include directory: "
+      message(STATUS "Found qscintilla2 headers directory: "
 	"${QSCINTILLA2_INCLUDE_DIR}")
     else(QSCINTILLA2_INCLUDE_DIR)
       message(FATAL_ERROR "no qscintilla2 headers found "


modules: updated FindMagnum.cmake.

modules: updated FindMagnum.cmake.

--- modules/FindMagnum.cmake
+++ modules/FindMagnum.cmake
@@ -327,7 +327,7 @@
         ${MAGNUM_INCLUDE_DIR})
     # Some deprecated APIs use headers (but not externally defined symbols)
     # from the GL library, link those includes as well
-    if(MAGNUM_BUILD_DEPRECATED)
+    if(MAGNUM_BUILD_DEPRECATED AND MAGNUM_TARGET_GL)
         set_property(TARGET Magnum::Magnum APPEND PROPERTY
             INTERFACE_INCLUDE_DIRECTORIES ${MAGNUM_INCLUDE_DIR}/MagnumExternal/OpenGL)
     endif()


Updated FindMagnum.cmake from Magnum repository.

--- modules/FindMagnum.cmake
+++ modules/FindMagnum.cmake
@@ -16,7 +16,7 @@
 find_package(OpenGL REQUIRED)
 find_package(GLEW REQUIRED)

-if (MAGNUM_INCLUDE_DIR AND MAGNUM_LIBRARY AND MAGNUM_PRIMITIVES_LIBRARY AND MAGNUM_MESHTOOLS_LIBRARY)
+if (MAGNUM_INCLUDE_DIR AND MAGNUM_LIBRARY AND MAGNUM_PRIMITIVES_LIBRARY AND MAGNUM_MESHTOOLS_LIBRARY AND MAGNUM_SHADERS_LIBRARY)

     # Already in cache
     set(MAGNUM_FOUND TRUE)
@@ -26,6 +26,7 @@
     find_library(MAGNUM_LIBRARY Magnum)
     find_library(MAGNUM_PRIMITIVES_LIBRARY MagnumPrimitives)
     find_library(MAGNUM_MESHTOOLS_LIBRARY MagnumMeshTools)
+    find_library(MAGNUM_SHADERS_LIBRARY MagnumShaders)

     # Paths
     find_path(MAGNUM_INCLUDE_DIR
@@ -39,12 +40,14 @@
         MAGNUM_LIBRARY
         MAGNUM_PRIMITIVES_LIBRARY
         MAGNUM_MESHTOOLS_LIBRARY
+        MAGNUM_SHADERS_LIBRARY
     )

 endif()

 # Installation dirs
-set_parent_scope(MAGNUM_LIBRARY_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/lib)
+include(CorradeLibSuffix)
+set_parent_scope(MAGNUM_LIBRARY_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX})
 set_parent_scope(MAGNUM_PLUGINS_INSTALL_DIR ${MAGNUM_LIBRARY_INSTALL_DIR}/magnum)
 set_parent_scope(MAGNUM_PLUGINS_IMPORTER_INSTALL_DIR ${MAGNUM_PLUGINS_INSTALL_DIR}/importers)
 set_parent_scope(MAGNUM_CMAKE_MODULE_INSTALL_DIR ${CMAKE_ROOT}/Modules)


Added gcov flag to generate relative path for .gcda files

--- coverage/coverage.cmake
+++ coverage/coverage.cmake
@@ -8,5 +8,5 @@
     if(${s})
         get_target_property(flags ${YOTTA_MODULE_NAME} COMPILE_FLAGS)
     endif()
-    set_target_properties(${YOTTA_MODULE_NAME} PROPERTIES COMPILE_FLAGS "${flags} -fprofile-arcs -ftest-coverage")
+    set_target_properties(${YOTTA_MODULE_NAME} PROPERTIES COMPILE_FLAGS "${flags} -fprofile-arcs -ftest-coverage -fprofile-dir=.")
 endif()


Upgrade to Go 1.3.1

Upgrade to Go 1.3.1

--- golang.cmake
+++ golang.cmake
@@ -11,9 +11,9 @@
 include (BuildSupport)

 external_source (golang
-    1.3
-    go1.3.src.tar.gz
-    4b66d7249554181c314f139ea78920b1
+    1.3.1
+    go1.3.1.src.tar.gz
+    13e32d14e974e3d903fa2de03581c681
     http://golang.org/dl)

 message ("Installing ${golang_NAME} into build area: ${BUILDEM_DIR} ...")


fixed incorrect behavior

fixed incorrect behavior

--- FindTREEJUCE.cmake
+++ FindTREEJUCE.cmake
@@ -57,14 +57,20 @@
 endif()

 if(NOT TREEJUCE_LIBRARIES)
-    unset(TREEJUCE_LIBRARIES)
-    find_library(TREEJUCE_LIBRARIES ${treejuce_lib_name}
+    message("find treejuce libraries")
+    find_library(treejuce_main_lib ${treejuce_lib_name}
         HINTS
             ${TREEJUCE_SEARCH_PREFIX_LIB}
             ${TREEJUCE_SEARCH_PREFIX}/${CMAKE_INSTALL_LIBDIR}
             ${TREEJUCE_SEARCH_PREFIX}/lib
     )
-    list(APPEND TREEJUCE_LIBRARIES ${treejuce_dep_libs})
+    set_property(CACHE treejuce_main_lib
+        PROPERTY
+            ADVANCED 1
+    )
+    message(${treejuce_main_lib})
+    set(TREEJUCE_LIBRARIES ${treejuce_dep_libs} ${treejuce_main_lib} CACHE STRING "" FORCE)
+    message("for user: ${TREEJUCE_LIBRARIES}")
 endif()

 #
@@ -72,6 +78,7 @@
 #
 FIND_PACKAGE_HANDLE_STANDARD_ARGS(TREEJUCE
     REQUIRED_VARS
+        treejuce_main_lib
         TREEJUCE_BIN_BUILDER
         TREEJUCE_INCLUDE_DIR
         TREEJUCE_LIBRARIES


Build Hostx86/arm32 crossgen when CROSSCOMPILE is "1" and Hostx64/arm32 crossgen otherwise in configurecompiler.cmake

--- configurecompiler.cmake
+++ configurecompiler.cmake
@@ -9,7 +9,11 @@
         # CMAKE_HOST_SYSTEM_PROCESSOR returns the value of `uname -p` on host.
         if(CMAKE_HOST_SYSTEM_PROCESSOR STREQUAL x86_64 OR CMAKE_HOST_SYSTEM_PROCESSOR STREQUAL amd64)
             if(CLR_CMAKE_TARGET_ARCH STREQUAL "arm")
-                set(CLR_CMAKE_PLATFORM_UNIX_X86 1)
+                if($ENV{CROSSCOMPILE} STREQUAL "1")
+                    set(CLR_CMAKE_PLATFORM_UNIX_X86 1)
+                else()
+                    set(CLR_CMAKE_PLATFORM_UNIX_AMD64 1)
+                endif()
             else()
                 set(CLR_CMAKE_PLATFORM_UNIX_AMD64 1)
             endif()


Add forward declaration map.

Add forward declaration map.

The implementation, as planned, for forward declarations should solve an
existing problem for exported modules.

--- CPM.cmake
+++ CPM.cmake
@@ -126,11 +126,22 @@
 #                                 targets associated with an exported module.
 #  CPM_KV_LIST_LIB_TARGET_MAP   - A list of all key values in the library
 #                                 target map (CPM_KV_LIB_TARGET_MAP_*).
+#  CPM_KV_FORWARD_DECL_MAP_*    - A key/value mapping of unique id to forward
+#                                 declaration pairs. This map is also used
+#                                 during the export module process to determine
+#                                 what the module was named by the exporter
+#                                 module.
+#                                 Key: unique path (with version)
+#                                 Value: Pairs consisting of the following:
+#                                        (unique_id_for_fwd_decl, new_name).
+#  CPM_KV_LIST_FORWARD_DECL_MAP - A list of entries in CPM_KV_FORWARD_DECL_MAP.
+#
 #  CPM_KV_EXPORT_MAP_*          - A key/value mapping of all exported modules
 #                                 from a module.
 #                                 Key: unique path (with version).
-#                                 Value: A list of modules that have been exported.
-#                                        in particular, their unique ids with version.
+#                                 Value: A list of modules that have been
+#                                        exported. In particular, this value is
+#                                        their full unique id.
 #  CPM_KV_LIST_EXPORT_MAP       - List of values from exported module map.
 #
 #  CPM_KV_UNID_MAP_*            - Map of full unique IDs. This map is cleared
@@ -497,9 +508,6 @@

 # Propogates the list of directories we have sourced upwards.
 macro(_cpm_propogate_source_added_map_up)
-  # Use CPM_KV_LIST_MOD_VERSION_MAP to propogate constraints up into the
-  # parent CPM_AddModule function's namespace. CPM_AddModule will
-  # propogate the versioning information up again to it's parent's namespace.
   if (NOT CPM_HIERARCHY_LEVEL EQUAL 0)
     foreach(_cpm_kvName IN LISTS CPM_KV_LIST_SOURCE_ADDED_MAP)
       set(CPM_KV_SOURCE_ADDED_MAP_${_cpm_kvName} ${CPM_KV_SOURCE_ADDED_MAP_${_cpm_kvName}} PARENT_SCOPE)
@@ -513,9 +521,6 @@

 # Propogates include map up.
 macro(_cpm_propogate_include_map_up)
-  # Use CPM_KV_LIST_MOD_VERSION_MAP to propogate constraints up into the
-  # parent CPM_AddModule function's namespace. CPM_AddModule will
-  # propogate the versioning information up again to it's parent's namespace.
   if (NOT CPM_HIERARCHY_LEVEL EQUAL 0)
     foreach(_cpm_kvName IN LISTS CPM_KV_LIST_INCLUDE_MAP)
       set(CPM_KV_INCLUDE_MAP_${_cpm_kvName} ${CPM_KV_INCLUDE_MAP_${_cpm_kvName}} PARENT_SCOPE)
@@ -529,9 +534,6 @@

 # Propogates definition map up.
 macro(_cpm_propogate_definition_map_up)
-  # Use CPM_KV_LIST_MOD_VERSION_MAP to propogate constraints up into the
-  # parent CPM_AddModule function's namespace. CPM_AddModule will
-  # propogate the versioning information up again to it's parent's namespace.
   if (NOT CPM_HIERARCHY_LEVEL EQUAL 0)
     foreach(_cpm_kvName IN LISTS CPM_KV_LIST_DEFINITION_MAP)
       set(CPM_KV_DEFINITION_MAP_${_cpm_kvName} ${CPM_KV_DEFINITION_MAP_${_cpm_kvName}} PARENT_SCOPE)
@@ -543,11 +545,21 @@
   endif()
 endmacro()

+# Propogates forward declaration map up.
+macro(_cpm_propogate_forward_decl_map_up)
+  if (NOT CPM_HIERARCHY_LEVEL EQUAL 0)
+    foreach(_cpm_kvName IN LISTS CPM_KV_LIST_FORWARD_DECL_MAP)
+      set(CPM_KV_FORWARD_DECL_MAP_${_cpm_kvName} ${CPM_KV_FORWARD_DECL_MAP_${_cpm_kvName}} PARENT_SCOPE)
+    endforeach()
+    set(_cpm_kvName) # Clear kvName
+
+    # Now propogate the list itself upwards.
+    set(CPM_KV_LIST_FORWARD_DECL_MAP ${CPM_KV_LIST_FORWARD_DECL_MAP} PARENT_SCOPE)
+  endif()
+endmacro()
+
 # Propogates target library map up.
 macro(_cpm_propogate_target_lib_map_up)
-  # Use CPM_KV_LIST_MOD_VERSION_MAP to propogate constraints up into the
-  # parent CPM_AddModule function's namespace. CPM_AddModule will
-  # propogate the versioning information up again to it's parent's namespace.
   if (NOT CPM_HIERARCHY_LEVEL EQUAL 0)
     foreach(_cpm_kvName IN LISTS CPM_KV_LIST_LIB_TARGET_MAP)
       set(CPM_KV_LIB_TARGET_MAP_${_cpm_kvName} ${CPM_KV_LIB_TARGET_MAP_${_cpm_kvName}} PARENT_SCOPE)
@@ -561,9 +573,6 @@

 # Propogates export module map up.
 macro(_cpm_propogate_export_map_up)
-  # Use CPM_KV_LIST_MOD_VERSION_MAP to propogate constraints up into the
-  # parent CPM_AddModule function's namespace. CPM_AddModule will
-  # propogate the versioning information up again to it's parent's namespace.
   if (NOT CPM_HIERARCHY_LEVEL EQUAL 0)
     foreach(_cpm_kvName IN LISTS CPM_KV_LIST_EXPORT_MAP)
       set(CPM_KV_EXPORT_MAP_${_cpm_kvName} ${CPM_KV_EXPORT_MAP_${_cpm_kvName}} PARENT_SCOPE)
@@ -615,6 +624,7 @@
   _cpm_propogate_definition_map_up()
   _cpm_propogate_target_lib_map_up()
   _cpm_propogate_export_map_up()
+  _cpm_propogate_forward_decl_map_up()

   # Setup the module with appropriate definitions and includes.
   # We can do this because we are not in a new scope; instead, we are in a macro
@@ -1045,6 +1055,10 @@
         message(FATAL_ERROR "Logic error: All exported modules must be in the source map.")
       endif()

+      # TODO: Add forward declarations for the module. All forward declarations
+      #       should add another preprocessor element to the
+      #       _cpm_check_and_add_preproc function.
+
       # Ensure we don't attempt to handle exports for a module we've already
       # covered.
       set(_CPM_SAVE_REC_MOD_VAR_${recUNID} ${_CPM_REC_MOD_VAR})
@@ -1380,6 +1394,7 @@
   _cpm_propogate_definition_map_up()
   _cpm_propogate_target_lib_map_up()
   _cpm_propogate_export_map_up()
+  _cpm_propogate_forward_decl_map_up()

   if (COMMAND CPM_PostModuleExecCallback)
     CPM_PostModuleExecCallback()


Removing debug message.

Removing debug message.

--- CPM.cmake
+++ CPM.cmake
@@ -697,8 +697,6 @@
   # Setup the project.
   add_subdirectory("${__CPM_MODULE_SOURCE_DIR}" "${__CPM_MODULE_BIN_DIR}")

-  message("CPM module: ${CPM_LAST_MODULE_NAME}")
-
   # Parse the arguments once again after adding the subdirectory (since we
   # cleared them all).
   _cpm_parse_arguments(CPM_AddModule _CPM_ "${ARGN}")


Change the install path for the doc

Change the install path for the doc

This commit changes the install path for the documentation. Previously: install/share/doc/tixi. Now: install/share/tixi3/doc

addresses #87

--- contrib/createDoc.cmake
+++ contrib/createDoc.cmake
@@ -2,7 +2,7 @@
 if(DOXYGEN_FOUND)
 	configure_file(${PROJECT_SOURCE_DIR}/doc/Doxyfile.in ${PROJECT_BINARY_DIR}/doc/Doxyfile @ONLY)
 	configure_file(${PROJECT_SOURCE_DIR}/doc/footer.html ${PROJECT_BINARY_DIR}/doc/footer.html @ONLY)
-	add_custom_command(
+	add_custom_command(
 		DEPENDS ${PROJECT_SOURCE_DIR}/src/tixi.h
 		OUTPUT ${PROJECT_BINARY_DIR}/doc/html/index.html
 		OUTPUT ${PROJECT_BINARY_DIR}/doc/latex/refman.tex
@@ -15,7 +15,7 @@
 	)

 	install(DIRECTORY ${PROJECT_BINARY_DIR}/doc/html
-			DESTINATION	share/doc/tixi
+                        DESTINATION	share/${TIXI_LIB_NAME}/doc
 			COMPONENT docu
 			OPTIONAL)

@@ -24,7 +24,7 @@
 	if(LATEX)
 	    # run latex twice to fix links
 		add_custom_command(
-			OUTPUT ${PROJECT_BINARY_DIR}/doc/tixi.pdf
+                        OUTPUT ${PROJECT_BINARY_DIR}/doc/tixi.pdf
 			DEPENDS ${PROJECT_BINARY_DIR}/doc/latex/refman.tex
 			WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/doc/latex/
 			COMMAND ${LATEX}
@@ -32,12 +32,12 @@
 			COMMAND ${LATEX}
 			ARGS ${PROJECT_BINARY_DIR}/doc/latex/refman.tex
 			COMMAND ${CMAKE_COMMAND}
-			ARGS -E copy ${PROJECT_BINARY_DIR}/doc/latex/refman.pdf ${PROJECT_BINARY_DIR}/doc/tixi.pdf
+                        ARGS -E copy ${PROJECT_BINARY_DIR}/doc/latex/refman.pdf ${PROJECT_BINARY_DIR}/doc/tixi.pdf
 		)

 		add_custom_target(pdf
 			COMMENT "Generating PDF documentation with latex" VERBATIM
-			DEPENDS ${PROJECT_BINARY_DIR}/doc/tixi.pdf
+                        DEPENDS ${PROJECT_BINARY_DIR}/doc/tixi.pdf
 		)

 		add_custom_target(doc
@@ -45,8 +45,8 @@
 			COMMENT "Generating API documentation with Doxygen" VERBATIM
 		)

-		install(FILES ${PROJECT_BINARY_DIR}/doc/tixi.pdf
-				DESTINATION	share/doc/tixi
+                install(FILES ${PROJECT_BINARY_DIR}/doc/tixi.pdf
+                                DESTINATION	share/${TIXI_LIB_NAME}/doc
 				COMPONENT docu
 				OPTIONAL)
 	else()
@@ -55,4 +55,4 @@
 			COMMENT "Generating API documentation with Doxygen" VERBATIM
 		)
 	endif()
-endif(DOXYGEN_FOUND)
+endif(DOXYGEN_FOUND)


COMP: in REMOVE_FROM_CACHE_LIST macro, remove items a few times to make sure they're gone

--- CMake/FunctionalityHelpers.cmake
+++ CMake/FunctionalityHelpers.cmake
@@ -4,6 +4,8 @@
 MACRO( REMOVE_FROM_CACHE_LIST listname item )
    IF(${listname})
      SET(TMP_VALUE ${${listname}})
+     LIST(REMOVE_ITEM TMP_VALUE ${item})
+     LIST(REMOVE_ITEM TMP_VALUE ${item})
      LIST(REMOVE_ITEM TMP_VALUE ${item})
      # todo: maybe check for equality
      # IF(${listname} STREQUAL ${TMP_VALUE})
@@ -80,7 +82,7 @@
     SET(${KITNAME}_FUNCTIONALITY_NAMES ${${KITNAME}_FUNCTIONALITY_NAMES};${FUNC_NAME} CACHE INTERNAL "Names of all ${KITNAME} functionalities." FORCE)
     SET(ALL_FUNCTIONALITY_DIRS ${ALL_FUNCTIONALITY_DIRS};${CMAKE_CURRENT_SOURCE_DIR} CACHE INTERNAL "Directories of all enabled functionalities." FORCE)
     # SET(${KITNAME}_FUNCTIONALITY_NAMES-MODIFIED 1 CACHE INTERNAL "test")
-  #   CLEANUP_FUNCTIONALITY_LIST()
+    # CLEANUP_FUNCTIONALITY_LIST()
     ADD_LIBRARY(${FUNC_NAME} ${FUNC_CPP_LIST} "${CMAKE_CURRENT_BINARY_DIR}/Register${FUNC_NAME}.cpp" )
     TARGET_LINK_LIBRARIES(${FUNC_NAME} ${LIBS_FOR_QFUNCTIONALITY})
     ADD_DEPENDENCIES(${FUNC_NAME} ${LIBS_FOR_QFUNCTIONALITY})


Fixes configuration when enabling PythonQt wrapping

This commit fixes the incorrect Qt version check
introduced by commit 47b34216.

--- CMake/ctkMacroWrapPythonQt.cmake
+++ CMake/ctkMacroWrapPythonQt.cmake
@@ -163,9 +163,8 @@
     COMMENT "PythonQt Wrapping - Generating ${wrapper_init_cpp_filename}"
     VERBATIM
     )
-
-  if (CTK_QT_VERSION VERSION_EQUAL "4")
-    QT5_WRAP_CPP(${TARGET}_MOC_CXX ${CMAKE_CURRENT_BINARY_DIR}/${wrapper_h_filename})
+  if(CTK_QT_VERSION VERSION_GREATER "4")
+    qt5_wrap_cpp(${TARGET}_MOC_CXX ${CMAKE_CURRENT_BINARY_DIR}/${wrapper_h_filename})
   else()
     QT4_WRAP_CPP(${TARGET}_MOC_CXX ${CMAKE_CURRENT_BINARY_DIR}/${wrapper_h_filename})
   endif()


Require Compute 6.0

Require Compute 6.0

--- CMake/hoomd/HOOMDCUDASetup.cmake
+++ CMake/hoomd/HOOMDCUDASetup.cmake
@@ -26,7 +26,7 @@
         list(GET _cuda_arch_list_sorted 0 _cuda_min_arch)
         list(GET _cuda_arch_list_sorted -1 _cuda_max_arch)

-        if (_cuda_min_arch LESS 35)
+        if (_cuda_min_arch LESS 60)
             message(SEND_ERROR "HOOMD requires compute 6.0 or newer")
         endif ()


Added options for static FreeImage in CMAKE

--- CMakeModules/FindFreeImage.cmake
+++ CMakeModules/FindFreeImage.cmake
@@ -6,6 +6,8 @@
 # FREEIMAGE_INCLUDE_PATH
 # FREEIMAGE_LIBRARY
 #
+
+OPTION(FREEIMAGE_STATIC "Use Static FreeImage Lib" OFF)

 FIND_PATH( FREEIMAGE_INCLUDE_PATH
         NAMES FreeImage.h
@@ -16,6 +18,21 @@
         /sw/include
         /opt/local/include
         DOC "The directory where FreeImage.h resides")
+IF(FREEIMAGE_STATIC)
+  SET(CMAKE_FIND_LIBRARY_SUFFIXES ${CMAKE_STATIC_LIBRARY_SUFFIX})
+  FIND_LIBRARY( FREEIMAGE_LIBRARY
+  NAMES FreeImageLIB FreeImage freeimage
+        HINTS ${PROJECT_SOURCE_DIR}/FreeImage
+        PATHS
+        /usr/lib64
+        /usr/lib
+        /usr/local/lib64
+        /usr/local/lib
+        /sw/lib
+        /opt/local/lib
+        DOC "The FreeImage library")
+  ADD_DEFINITIONS(-DFREEIMAGE_LIB)
+ELSE(FREEIMAGE_STATIC)
 FIND_LIBRARY( FREEIMAGE_LIBRARY
         NAMES FreeImage freeimage
         HINTS ${PROJECT_SOURCE_DIR}/FreeImage
@@ -27,13 +44,14 @@
         /sw/lib
         /opt/local/lib
         DOC "The FreeImage library")
+ENDIF(FREEIMAGE_STATIC)

 SET(FREEIMAGE_INCLUDE_DIRS ${FREEIMAGE_INCLUDE_PATH})
 SET(FREEIMAGE_LIBRARIES ${FREEIMAGE_LIBRARY})

 MARK_AS_ADVANCED(
     FREEIMAGE_LIBRARY
-        FREEIMAGE_INCLUDE_PATH)
+    FREEIMAGE_INCLUDE_PATH)
 INCLUDE(FindPackageHandleStandardArgs)
 FIND_PACKAGE_HANDLE_STANDARD_ARGS(FREEIMAGE DEFAULT_MSG
     FREEIMAGE_INCLUDE_PATH FREEIMAGE_LIBRARY)


less printing in cmake

less printing in cmake

--- gaf.cmake
+++ gaf.cmake
@@ -40,7 +40,7 @@

     list(APPEND ${SRCS} "${CMAKE_CURRENT_BINARY_DIR}/${Gaf_CUSTOM_PREFIX}${FIL_NAME}.cc")
     list(APPEND ${HDRS} "${CMAKE_CURRENT_BINARY_DIR}/${Gaf_CUSTOM_PREFIX}${FIL_NAME}.h")
-    message(STATUS "Appending ${CMAKE_CURRENT_BINARY_DIR}/${Gaf_CUSTOM_PREFIX}${FIL_NAME}.h")
+    # message(STATUS "Appending ${CMAKE_CURRENT_BINARY_DIR}/${Gaf_CUSTOM_PREFIX}${FIL_NAME}.h")

     SET(ABSOLUTE_GAF ${GAF_ROOT_DIR}/gaf.py)

@@ -58,6 +58,6 @@
   set(${SRCS} ${${SRCS}} PARENT_SCOPE)
   set(${HDRS} ${${HDRS}} PARENT_SCOPE)

-  message(STATUS "headers ${HDRS}")
-  message(STATUS "hh ${${HDRS}}")
+  # message(STATUS "headers ${HDRS}")
+  # message(STATUS "hh ${${HDRS}}")
 endfunction()


Fix small gramatical typo.

Fix small gramatical typo.

--- CMakeModules/EmbedBinaryFiles.cmake
+++ CMakeModules/EmbedBinaryFiles.cmake
@@ -4,14 +4,14 @@
     # Collect input files
     file(GLOB bins ${file_glob})
     # Stop when output file is newer than all binary files
-    set(output_new_than_bins 1)
+    set(output_newer_than_bins 1)
     foreach(bin ${bins})
         if(bin IS_NEWER_THAN output)
-            set(output_new_than_bins 0)
+            set(output_newer_than_bins 0)
             break()
         endif()
     endforeach()
-    if(output_new_than_bins)
+    if(output_newer_than_bins)
         return()
     endif()
     # Create empty output file


remove the dependency of the static libs on the dynamic libs

--- Code/cmake/Modules/RDKitUtils.cmake
+++ Code/cmake/Modules/RDKitUtils.cmake
@@ -56,15 +56,6 @@
       if(RDK_INSTALL_STATIC_LIBS)
         add_library(${RDKLIB_NAME}_static ${RDKLIB_SOURCES})
         target_link_libraries(${RDKLIB_NAME}_static PUBLIC rdkit_base)
-        foreach(RDKLIB_LINK_LIBRARY ${RDKLIB_LINK_LIBRARIES})
-          set(STATIC_LIB ${RDKLIB_LINK_LIBRARY}_static)
-          # if the static variant exist, link against it, otherwise link against the unmodified name (-> boost, etc)
-          if (TARGET ${STATIC_LIB})
-            target_link_libraries(${RDKLIB_NAME}_static PUBLIC ${STATIC_LIB})
-          else()
-            target_link_libraries(${RDKLIB_NAME}_static PUBLIC ${RDKLIB_LINK_LIBRARY})
-          endif()
-        endforeach()
         INSTALL(TARGETS ${RDKLIB_NAME}_static EXPORT ${RDKit_EXPORTED_TARGETS}
                 DESTINATION ${RDKit_LibDir}/${RDKLIB_DEST}
                 COMPONENT dev )


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 04)

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


defined TT_PLATFORM_WIN even on Mingw

defined TT_PLATFORM_WIN even on Mingw

--- Shared/CMake/JamomaPlatformSpecific.cmake
+++ Shared/CMake/JamomaPlatformSpecific.cmake
@@ -57,11 +57,12 @@
 			endif()
 		endif()
 	elseif(MINGW)
-		add_definitions(-DTT_PLATFORM_LINUX)
+		add_definitions(-DTT_PLATFORM_WIN)
 		SET(CPACK_GENERATOR "NSIS")
 	endif()
 elseif(WIN32)
 	if(MINGW)
+		add_definitions(-DTT_PLATFORM_WIN)
 		set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -Wno-unknown-pragmas -Wno-conversion -Wno-deprecated-declarations -Wno-trigraphs")
 	else()
 		set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4996 /wd4275 /wd4273 /wd4068 /LD /MD")


CMake: Bump version

CMake: Bump version

--- version.cmake
+++ version.cmake
@@ -2,9 +2,9 @@
 	set(PROJECT_NAME "mGBA")
 endif()
 set(LIB_VERSION_MAJOR 0)
-set(LIB_VERSION_MINOR 7)
+set(LIB_VERSION_MINOR 8)
 set(LIB_VERSION_PATCH 0)
-set(LIB_VERSION_ABI 0.7)
+set(LIB_VERSION_ABI 0.8)
 set(LIB_VERSION_STRING ${LIB_VERSION_MAJOR}.${LIB_VERSION_MINOR}.${LIB_VERSION_PATCH})
 set(SUMMARY "${PROJECT_NAME} Game Boy Advance Emulator")


Split off 7.12.68

Split off 7.12.68

Signed-off-by: Richard Chapman <5900d56196fe29dba8e3ae556d57eae28e9f0195@hpccsystems.com>

--- version.cmake
+++ version.cmake
@@ -5,7 +5,7 @@
 set ( HPCC_PROJECT "nagios-monitoring" )
 set ( HPCC_MAJOR 7 )
 set ( HPCC_MINOR 12 )
-set ( HPCC_POINT 67 )
+set ( HPCC_POINT 69 )
 set ( HPCC_MATURITY "closedown" )
 set ( HPCC_SEQUENCE 0 )
 ###


Split off 8.10.0

Split off 8.10.0

Signed-off-by: Richard Chapman <5900d56196fe29dba8e3ae556d57eae28e9f0195@hpccsystems.com>

--- version.cmake
+++ version.cmake
@@ -4,7 +4,7 @@
 set ( HPCC_NAME "Nagios Monitoring" )
 set ( HPCC_PROJECT "nagios-monitoring" )
 set ( HPCC_MAJOR 8 )
-set ( HPCC_MINOR 9 )
+set ( HPCC_MINOR 11 )
 set ( HPCC_POINT 0 )
 set ( HPCC_MATURITY "trunk" )
 set ( HPCC_SEQUENCE 0 )


CTestConfig: Submit to dedicated KWSys dashboard

Change-Id: I08fd8c6ed7e9ba16216f1e8c52285f2f8e6be7fe

--- CTestConfig.cmake
+++ CTestConfig.cmake
@@ -1,6 +1,6 @@
 #=============================================================================
 # KWSys - Kitware System Library
-# Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
+# Copyright 2000-2012 Kitware, Inc., Insight Software Consortium
 #
 # Distributed under the OSI-approved BSD License (the "License");
 # see accompanying file Copyright.txt for details.
@@ -9,10 +9,9 @@
 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 # See the License for more information.
 #=============================================================================
-set (CTEST_PROJECT_NAME "kwsys")
-set (CTEST_NIGHTLY_START_TIME "21:00:00 EDT")
-set (CTEST_DART_SERVER_VERSION "2")
+set(CTEST_PROJECT_NAME "KWSys")
+set(CTEST_NIGHTLY_START_TIME "21:00:00 EDT")
 set(CTEST_DROP_METHOD "http")
-set(CTEST_DROP_SITE "www.cdash.org")
-set(CTEST_DROP_LOCATION "/CDash/submit.php?project=PublicDashboard")
+set(CTEST_DROP_SITE "open.cdash.org")
+set(CTEST_DROP_LOCATION "/submit.php?project=KWSys")
 set(CTEST_DROP_SITE_CDASH TRUE)


Make package project name and components overrideable

--- CommonCPack.cmake
+++ CommonCPack.cmake
@@ -2,16 +2,19 @@
 # Copyright (c) 2012 Stefan Eilemann <eile@eyescale.ch>
 # Info: http://www.itk.org/Wiki/CMake:Component_Install_With_CPack

-string(TOUPPER ${CMAKE_PROJECT_NAME} UPPER_PROJECT_NAME)
+if(NOT CPACK_PROJECT_NAME)
+  set(CPACK_PROJECT_NAME ${CMAKE_PROJECT_NAME})
+endif()
+string(TOUPPER ${CPACK_PROJECT_NAME} UPPER_PROJECT_NAME)

 set(${UPPER_PROJECT_NAME}_PACKAGE_VERSION "" CACHE
   STRING "Additional build version for packages")
 mark_as_advanced(${UPPER_PROJECT_NAME}_PACKAGE_VERSION)

 if(CMAKE_SYSTEM_NAME MATCHES "Linux")
-  set(CPACK_PACKAGE_NAME "${CMAKE_PROJECT_NAME}${VERSION_ABI}")
+  set(CPACK_PACKAGE_NAME "${CPACK_PROJECT_NAME}${VERSION_ABI}")
 else()
-  set(CPACK_PACKAGE_NAME "${CMAKE_PROJECT_NAME}")
+  set(CPACK_PACKAGE_NAME "${CPACK_PROJECT_NAME}")
 endif()

 if(NOT APPLE)
@@ -24,24 +27,27 @@
 set(CPACK_PACKAGE_VERSION_PATCH ${VERSION_PATCH})
 set(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_SOURCE_DIR}/LICENSE.txt)

-# Feel free to override components and description after including this file
-if(RELEASE_VERSION)
-  set(CPACK_COMPONENTS_ALL lib dev)
-else()
-  set(CPACK_COMPONENTS_ALL unspecified lib dev)
+# Default component definition
+if(NOT CPACK_COMPONENTS_ALL)
+  if(RELEASE_VERSION)
+    set(CPACK_COMPONENTS_ALL lib dev)
+  else()
+    set(CPACK_COMPONENTS_ALL unspecified lib dev)
+  endif()
+
+  set(CPACK_COMPONENT_UNSPECIFIED_DISPLAY_NAME "Unspecified")
+  set(CPACK_COMPONENT_UNSPECIFIED_DESCRIPTION
+    "Unspecified Component - set COMPONENT in CMake install() command")
+
+  set(CPACK_COMPONENT_LIB_DISPLAY_NAME "${CPACK_PROJECT_NAME} Libraries")
+  set(CPACK_COMPONENT_LIB_DESCRIPTION "${CPACK_PROJECT_NAME} Runtime Libraries")
+
+  set(CPACK_COMPONENT_DEV_DISPLAY_NAME
+    "${CPACK_PROJECT_NAME} Development Files")
+  set(CPACK_COMPONENT_DEV_DESCRIPTION
+    "Header and Library Files for ${CPACK_PROJECT_NAME} Development")
+  set(CPACK_COMPONENT_DEV_DEPENDS lib)
 endif()
-
-set(CPACK_COMPONENT_UNSPECIFIED_DISPLAY_NAME "Unspecified")
-set(CPACK_COMPONENT_UNSPECIFIED_DESCRIPTION
-  "Unspecified Component - set COMPONENT in CMake install() command")
-
-set(CPACK_COMPONENT_LIB_DISPLAY_NAME "${CMAKE_PROJECT_NAME} Libraries")
-set(CPACK_COMPONENT_LIB_DESCRIPTION "${CMAKE_PROJECT_NAME} Runtime Libraries")
-
-set(CPACK_COMPONENT_DEV_DISPLAY_NAME "${CMAKE_PROJECT_NAME} Development Files")
-set(CPACK_COMPONENT_DEV_DESCRIPTION
-  "Header and Library Files for ${CMAKE_PROJECT_NAME} Development")
-set(CPACK_COMPONENT_DEV_DEPENDS lib)

 # LSB system information
 set(LSB_DISTRIBUTOR_ID "unknown")


increase minimal CUDA archtitecture for CUDA 9

use `sm_30` as minimal CUDA architecture for CUDA 9+

--- alpakaConfig.cmake
+++ alpakaConfig.cmake
@@ -289,7 +289,11 @@

         ELSE()
             SET(ALPAKA_CUDA_VERSION "${CUDA_VERSION}")
-            SET(ALPAKA_CUDA_ARCH "20" CACHE STRING "GPU architecture")
+            IF(CUDA_VERSION VERSION_LESS 9.0)
+                SET(ALPAKA_CUDA_ARCH "20" CACHE STRING "GPU architecture")
+            ELSE()
+                SET(ALPAKA_CUDA_ARCH "30" CACHE STRING "GPU architecture")
+            ENDIF()
             SET(ALPAKA_CUDA_COMPILER "nvcc" CACHE STRING "CUDA compiler")
             SET_PROPERTY(CACHE ALPAKA_CUDA_COMPILER PROPERTY STRINGS "nvcc;clang")


build: udpate seastar to include fix for sanitizers

--- recipe/wellknown.cmake
+++ recipe/wellknown.cmake
@@ -98,8 +98,8 @@
     -DSeastar_DPDK=ON
     -DSeastar_TESTING=OFF
   EXTERNAL_PROJECT_ARGS
-    GIT_REPOSITORY https://github.com/scylladb/seastar/
-    GIT_TAG c9d6e20
+    GIT_REPOSITORY https://github.com/scylladb/seastar
+    GIT_TAG 245ca34
     )


xc7/make/device_define.cmake: fixed bug

xc7/make/device_define.cmake: fixed bug

Signed-off-by: Alessandro Comodi <622632e70fd6771cf2cd943f69e5e51ab66adef8@antmicro.com>

--- xc7/make/device_define.cmake
+++ xc7/make/device_define.cmake
@@ -45,7 +45,7 @@
     get_target_property_required(PYTHON3_TARGET env PYTHON3_TARGET)

     set(SYNTH_TILES_TO_PINMAP_CSV ${symbiflow-arch-defs_SOURCE_DIR}/xc7/utils/prjxray_synth_tiles_to_pinmap_csv.py)
-    set(PINMAP_CSV xc7z010-roi-virt/synth_tiles_pinmap.csv)
+    set(PINMAP_CSV ${DEVICE}-roi-virt/synth_tiles_pinmap.csv)

     set(PINMAP_CSV_DEPS ${PYTHON3} ${PYTHON3_TARGET} ${SYNTH_TILES_TO_PINMAP_CSV})
     append_file_dependency(PINMAP_CSV_DEPS ${SYNTH_TILES})


COMP: update wcslib git hash for fixing mac compilation

--- SuperBuild/External_wcslib.cmake
+++ SuperBuild/External_wcslib.cmake
@@ -33,7 +33,7 @@
   ExternalProject_Add(${proj}
     ${${proj}_EP_ARGS}
     GIT_REPOSITORY "${git_protocol}://github.com/Punzo/wcslib"
-    GIT_TAG "9b45438b15c6421e15da2c1a942fa9bd125339e7"
+    GIT_TAG "b1ed2e4d09d68a4b53ef83bbee8b31b110291884"
     SOURCE_DIR ${${proj}_SOURCE_DIR}
     BINARY_DIR ${${proj}_BINARY_DIR}
     CMAKE_CACHE_ARGS


Retabbed block tabs to spaces

Retabbed block tabs to spaces

--- CMakeModules/FindGLEWmx.cmake
+++ CMakeModules/FindGLEWmx.cmake
@@ -19,65 +19,65 @@
     )

 IF (WIN32)
-	IF (USE_GLEWmx_STATIC)
-		FIND_LIBRARY( GLEWmxs_LIBRARY
-			NAMES glewmxs GLEWmxs glew32mxs glew32mxs
-			PATHS
-			$ENV{PROGRAMFILES}/GLEW/lib
-			${GLEW_ROOT_DIR}/lib
-			${GLEW_ROOT_DIR}
-			${PROJECT_SOURCE_DIR}/../dependencies/glew/lib
-			PATH_SUFFIXES "Release MX/x64" "lib64"
-			DOC "The GLEWmxs Static library"
-		)
-	ELSE (USE_GLEWmx_STATIC)
-		FIND_LIBRARY( GLEWmxd_LIBRARY
-			NAMES glewmx GLEWmx glew32mx glew32mx
-			PATHS
-			$ENV{PROGRAMFILES}/GLEW/lib
-			${GLEW_ROOT_DIR}/lib
-			${GLEW_ROOT_DIR}
-			${PROJECT_SOURCE_DIR}/../dependencies/glew/lib
-			PATH_SUFFIXES "Release MX/x64" "lib64"
-			DOC "The GLEWmx library"
-		)
-	ENDIF (USE_GLEWmx_STATIC)
+    IF (USE_GLEWmx_STATIC)
+        FIND_LIBRARY( GLEWmxs_LIBRARY
+            NAMES glewmxs GLEWmxs glew32mxs glew32mxs
+            PATHS
+            $ENV{PROGRAMFILES}/GLEW/lib
+            ${GLEW_ROOT_DIR}/lib
+            ${GLEW_ROOT_DIR}
+            ${PROJECT_SOURCE_DIR}/../dependencies/glew/lib
+            PATH_SUFFIXES "Release MX/x64" "lib64"
+            DOC "The GLEWmxs Static library"
+        )
+    ELSE (USE_GLEWmx_STATIC)
+        FIND_LIBRARY( GLEWmxd_LIBRARY
+            NAMES glewmx GLEWmx glew32mx glew32mx
+            PATHS
+            $ENV{PROGRAMFILES}/GLEW/lib
+            ${GLEW_ROOT_DIR}/lib
+            ${GLEW_ROOT_DIR}
+            ${PROJECT_SOURCE_DIR}/../dependencies/glew/lib
+            PATH_SUFFIXES "Release MX/x64" "lib64"
+            DOC "The GLEWmx library"
+        )
+    ENDIF (USE_GLEWmx_STATIC)
 ELSE (WIN32)
-	IF (USE_GLEWmx_STATIC)
-		SET(PX ${CMAKE_STATIC_LIBRARY_PREFIX})
-		SET(SX ${CMAKE_STATIC_LIBRARY_SUFFIX})
-		FIND_LIBRARY( GLEWmxs_LIBRARY
-			NAMES ${PX}GLEWmx${SX} ${PX}glewmx${SX}
-			PATHS
-			/usr/lib64
-			/usr/lib
-			/usr/lib/x86_64-linux-gnu
-			/usr/lib/arm-linux-gnueabihf
-			/usr/local/lib64
-			/usr/local/lib
-			/sw/lib
-			/opt/local/lib
-			${GLEW_ROOT_DIR}/lib
-			NO_DEFAULT_PATH
-			DOC "The GLEWmx library")
-		UNSET(PX)
-		UNSET(SX)
-	ELSE (USE_GLEWmx_STATIC)
-		FIND_LIBRARY( GLEWmxd_LIBRARY
-			NAMES GLEWmx glewmx
-			PATHS
-			/usr/lib64
-			/usr/lib
-			/usr/lib/x86_64-linux-gnu
-			/usr/lib/arm-linux-gnueabihf
-			/usr/local/lib64
-			/usr/local/lib
-			/sw/lib
-			/opt/local/lib
-			${GLEW_ROOT_DIR}/lib
-			NO_DEFAULT_PATH
-			DOC "The GLEWmx library")
-	ENDIF (USE_GLEWmx_STATIC)
+    IF (USE_GLEWmx_STATIC)
+        SET(PX ${CMAKE_STATIC_LIBRARY_PREFIX})
+        SET(SX ${CMAKE_STATIC_LIBRARY_SUFFIX})
+        FIND_LIBRARY( GLEWmxs_LIBRARY
+            NAMES ${PX}GLEWmx${SX} ${PX}glewmx${SX}
+            PATHS
+            /usr/lib64
+            /usr/lib
+            /usr/lib/x86_64-linux-gnu
+            /usr/lib/arm-linux-gnueabihf
+            /usr/local/lib64
+            /usr/local/lib
+            /sw/lib
+            /opt/local/lib
+            ${GLEW_ROOT_DIR}/lib
+            NO_DEFAULT_PATH
+            DOC "The GLEWmx library")
+        UNSET(PX)
+        UNSET(SX)
+    ELSE (USE_GLEWmx_STATIC)
+        FIND_LIBRARY( GLEWmxd_LIBRARY
+            NAMES GLEWmx glewmx
+            PATHS
+            /usr/lib64
+            /usr/lib
+            /usr/lib/x86_64-linux-gnu
+            /usr/lib/arm-linux-gnueabihf
+            /usr/local/lib64
+            /usr/local/lib
+            /sw/lib
+            /opt/local/lib
+            ${GLEW_ROOT_DIR}/lib
+            NO_DEFAULT_PATH
+            DOC "The GLEWmx library")
+    ENDIF (USE_GLEWmx_STATIC)
 ENDIF (WIN32)

 IF(USE_GLEWmx_STATIC)


Fixed script warnings

Fixed script warnings

git-svn-id: aa838dfc23441284dd616281de4245daec5d2135@14623 16af8721-9629-0410-8352-f15c8da7e697

--- CMakeModules/FindLIBLAS.cmake
+++ CMakeModules/FindLIBLAS.cmake
@@ -42,8 +42,7 @@
      /opt/local/lib
      /opt/csw/lib
      /opt/lib
-     [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\
-Manager\\Environment;LIBLAS_ROOT]/lib
+     [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;LIBLAS_ROOT]/lib
      /usr/freeware/lib64
    )

@@ -82,8 +81,7 @@
      /opt/local/lib
      /opt/csw/lib
      /opt/lib
-     [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\
-Manager\\Environment;LIBLAS_ROOT]/lib
+     [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;LIBLAS_ROOT]/lib
      /usr/freeware/lib64
    )

@@ -102,4 +100,4 @@
 if(LIBLAS_LIBRARY AND LIBLASC_LIBRARY AND LIBLAS_INCLUDE_DIR)
    set(LIBLAS_LIBRARIES ${LIBLAS_LIBRARY} ${LIBLASC_LIBRARY} )
    set(LIBLAS_FOUND "YES")
-endif(LIBLAS_LIBRARY AND LIBLASC_LIBRARY LIBLAS_INCLUDE_DIR)+endif()


Fixed issue with distribution DCMTK and missing dictionary file

--- cmake/ExternalDCMTK.cmake
+++ cmake/ExternalDCMTK.cmake
@@ -13,6 +13,7 @@
             -DCMAKE_MACOSX_RPATH=ON
             -DBUILD_SHARED_LIBS=ON
             -DBUILD_APPS=OFF
+            -DDCMTK_ENABLE_BUILTIN_DICTIONARY=ON
             -DDCMTK_WITH_DOXYGEN=OFF
             -DCMAKE_INSTALL_RPATH:STRING=$ORIGIN/../lib
         CMAKE_CACHE_ARGS


Fix for problem with the CMake XCode generator ignoring the CMAKE_BUILD_TYPE value.

--- cmake/PlatformMacOS.cmake
+++ cmake/PlatformMacOS.cmake
@@ -13,6 +13,19 @@
 else ()

     message(STATUS "Configuring for platform MacOS with XCode Version 5+.")
+
+    # The XCode generator seems to ignore the value in the CMAKE_BUILD_TYPE variable.
+    # Instead, it uses the first value of the CMAKE_CONFIGURATION_TYPES list as build
+    # type (cf. http://www.cmake.org/pipermail/cmake/2006-December/012288.html)
+    # Therefore, we re-define the CMAKE_CONFIGURATION_TYPES here according to the value
+    # in CMAKE_BUILD_TYPES.
+    if (${CMAKE_BUILD_TYPE} STREQUAL "Release")
+	set(CMAKE_CONFIGURATION_TYPES ${CMAKE_BUILD_TYPE})
+	message(STATUS ">> Re-defining as follows: CMAKE_CONFIGURATION_TYPES = ${CMAKE_CONFIGURATION_TYPES}")
+    else ()
+	set(CMAKE_CONFIGURATION_TYPES ${CMAKE_BUILD_TYPE})
+	message(STATUS ">> Re-defining as follows: CMAKE_CONFIGURATION_TYPES = ${CMAKE_CONFIGURATION_TYPES}")
+    endif()

 endif()


Add specific linkers for MacOSPlatform

Add specific linkers for MacOSPlatform

--- cmake/PlatformMacOS.cmake
+++ cmake/PlatformMacOS.cmake
@@ -29,5 +29,8 @@
 set(DEFAULT_COMPILE_DEFS_DEBUG   ${MACOS_COMPILE_DEFS} _DEBUG) # Debug build
 set(DEFAULT_COMPILE_DEFS_RELEASE ${MACOS_COMPILE_DEFS} NDEBUG) # Release build

+set(MACOS_LINKER_FLAGS "-framework Cocoa -framework OpenGL -framework IOKit -framework CoreVideo")
+set(DEFAULT_LINKER_FLAGS_RELEASE ${MACOS_LINKER_FLAGS})
+
 set(MACOS_COMPILE_FLAGS)
 set(DEFAULT_COMPILE_FLAGS ${MACOS_COMPILE_FLAGS})


cmake: define S3 and Kinesis Firehose plugin for Windows (#2632)

Turn off plugins that do not work on Windows yet, so that we
can compile the master HEAD on MSVC.

This patch is required for v1.6 release.

Signed-off-by: Fujimoto Seiji <ef879192bb1e41d519c82cf76440dc8e9a530806@ceptord.net>

--- cmake/windows-setup.cmake
+++ cmake/windows-setup.cmake
@@ -9,6 +9,7 @@
 set(FLB_EXAMPLES              Yes)
 set(FLB_PARSER                Yes)
 set(FLB_TLS                   Yes)
+set(FLB_AWS                   Yes)

 # INPUT plugins
 # =============
@@ -66,6 +67,8 @@
 set(FLB_OUT_KAFKA              No)
 set(FLB_OUT_KAFKA_REST         No)
 set(FLB_OUT_CLOUDWATCH_LOGS   Yes)
+set(FLB_OUT_S3                 No)
+set(FLB_OUT_KINESIS_FIREHOSE   No)

 # FILTER plugins
 # ==============


build: boost use release version

build: boost use release version

--- recipe/wellknown.cmake
+++ recipe/wellknown.cmake
@@ -44,7 +44,7 @@
       --layout=system
       --build-dir=<BINARY_DIR>
       install
-      variant=debug
+      variant=release
       link=static # different from seastar
       threading=multi
       hardcode-dll-paths=true


COMP: ITK_BUILD_ALL_MODULES deprecated.

COMP: ITK_BUILD_ALL_MODULES deprecated.

In ITK v4.5, ITK_BUILD_ALL_MODULES is deprecated in favor of
ITK_BUILD_DEFAULT_MODULES.  Updating the ExternalProject.

--- CMake/Superbuild/External_ITK.cmake
+++ CMake/Superbuild/External_ITK.cmake
@@ -78,7 +78,7 @@
       -DBUILD_EXAMPLES:BOOL=OFF
       -DBUILD_TESTING:BOOL=OFF
       -DITKV3_COMPATIBILITY:BOOL=ON
-      -DITK_BUILD_ALL_MODULES:BOOL=ON
+      -DITK_BUILD_DEFAULT_MODULES:BOOL=ON
       -DITK_INSTALL_NO_DEVELOPMENT:BOOL=ON
       -DITK_LEGACY_REMOVE:BOOL=OFF
       -DKWSYS_USE_MD5:BOOL=ON


Create .app bundles for samples on OS X

Create .app bundles for samples on OS X

--HG--
extra : convert_revision : svn%3A8631bf8a-c64b-0410-883c-f3eb003322f7/trunk%40654

--- CMake/Utils/OgreConfigTargets.cmake
+++ CMake/Utils/OgreConfigTargets.cmake
@@ -99,6 +99,11 @@
       INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/lib)
     set_property(TARGET ${SAMPLENAME} PROPERTY INSTALL_RPATH_USE_LINK_PATH TRUE)
   endif ()
+
+  # On OS X, create .app bundle
+  if (APPLE)
+    set_property(TARGET ${SAMPLENAME} PROPERTY MACOSX_BUNDLE TRUE)
+  endif ()

   if (OGRE_INSTALL_SAMPLES)
     install(TARGETS ${SAMPLENAME}


ManageRPMScript: Fixed comment

ManageRPMScript: Fixed comment

--- Modules/ManageRPMScript.cmake
+++ Modules/ManageRPMScript.cmake
@@ -19,7 +19,7 @@
     -Dmainfests: Path to install_manifests.txt
     -Drelease: Path to RELEASE-NOTES.txt
   Note: Please pass the necessary variables via -Dvar=VALUE,
-      e.g. "-DPROJECT_NAME=cmake-fedora"
+      e.g. \"-DPROJECT_NAME=cmake-fedora\"

 cmake -Dcmd=spec_manifests
       -Dmanifests=<path/install_manifests.txt>
@@ -33,7 +33,7 @@
       %config instead of %config(noreplace)
     -Dmainfests: Path to install_manifests.txt
   Note: Please pass the necessary variables via -Dvar=VALUE,
-    e.g. "-DPROJECT_NAME=cmake-fedora"
+    e.g. \"-DPROJECT_NAME=cmake-fedora\"

 cmake -Dcmd=spec_changelog
       -Dmanifests=<path/install_manifests.txt>
@@ -45,10 +45,10 @@
     Options:
       -Dmainfests: Path to install_manifests.txt
     Note: Please pass the necessary variables via -Dvar=VALUE,
-       e.g. -DPROJECT_NAME=cmake-fedora
+       e.g. \"-DPROJECT_NAME=cmake-fedora\"

 cmake -Dcmd=make_manifests
-       [\"-Dmanifests=<path/install_manifests.txt>\"]
+       [\"-Dmanifests=<path>/install_manifests.txt>\"]
        [\"-Dtmp_dir=<dir>\"]
   Make install_manifests.txt.
   Options:


Split off 7.8.82

Split off 7.8.82

Signed-off-by: Richard Chapman <5900d56196fe29dba8e3ae556d57eae28e9f0195@hpccsystems.com>

--- version.cmake
+++ version.cmake
@@ -5,7 +5,7 @@
 set ( HPCC_PROJECT "nagios-monitoring" )
 set ( HPCC_MAJOR 7 )
 set ( HPCC_MINOR 8 )
-set ( HPCC_POINT 81 )
+set ( HPCC_POINT 83 )
 set ( HPCC_MATURITY "closedown" )
 set ( HPCC_SEQUENCE 0 )
 ###


update NAME to DISTRIBUTION_ID

update NAME to DISTRIBUTION_ID

--- packaging/linux/LinuxPackaging.cmake
+++ packaging/linux/LinuxPackaging.cmake
@@ -48,7 +48,7 @@
 ## Set right package generator
 ## #############################################################################

-if(${NAME} MATCHES fc|fedora|Fedora|Centos|centos|SUSE|Suse|suse)
+if(${DISTRIBUTOR_ID} MATCHES fc|fedora|Fedora|Centos|centos|SUSE|Suse|suse)
   set(CPACK_GENERATOR RPM)
 else()
   set(CPACK_GENERATOR DEB)


Undo last commit.

Undo last commit.

git-svn-id: 31d9d2f6432a47c86a3640814024c107794ea77c@31448 0785d39b-7218-0410-832d-ea1e28bc413d

--- deal.II/cmake/macros/macro_add_test.cmake
+++ deal.II/cmake/macros/macro_add_test.cmake
@@ -148,7 +148,7 @@
         SET_TARGET_PROPERTIES(${_target} PROPERTIES
           LINK_FLAGS "${DEAL_II_LINKER_FLAGS} ${DEAL_II_LINKER_FLAGS_${_build}}"
           COMPILE_DEFINITIONS "${DEAL_II_USER_DEFINITIONS};${DEAL_II_USER_DEFINITIONS_${_build}}"
-          COMPILE_FLAGS "${CMAKE_CXX_FLAGS} ${DEAL_II_CXX_FLAGS_${_build}}"
+          COMPILE_FLAGS "${DEAL_II_CXX_FLAGS} ${DEAL_II_CXX_FLAGS_${_build}}"
           LINKER_LANGUAGE "CXX"
           RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${_target}"
           )


create BufferObject .cpp file (cmake)

create BufferObject .cpp file (cmake)

--- allocore/modules/gl_module.cmake
+++ allocore/modules/gl_module.cmake
@@ -26,6 +26,7 @@
 message(STATUS "Building OpenGL module (OpenGL + GLEW).")

 list(APPEND ALLOCORE_SRC
+  src/graphics/al_BufferObject.cpp
   src/graphics/al_Graphics.cpp
   src/graphics/al_FBO.cpp
   src/graphics/al_GPUObject.cpp


Correction to allow PARAVIS compilation using paraview 3.98

--- salome_adm/cmake_files/FindSalomeVTK.cmake
+++ salome_adm/cmake_files/FindSalomeVTK.cmake
@@ -50,7 +50,7 @@
   MESSAGE(STATUS "Looking for VTK in the ParaView installation (PARAVIEW_ROOT_DIR exists and VTK_ROOT_DIR is not defined) ...")

   # Extract sub-directory "paraview-x.xx":
-  FILE(GLOB VTK_DIR "${PARAVIEW_ROOT_DIR}/lib/cmake/paraview-[1-9].[0-9]")
+  FILE(GLOB VTK_DIR "${PARAVIEW_ROOT_DIR}/lib/cmake/paraview-[1-9].[0-9]*")
   MESSAGE(STATUS "Setting VTK_DIR to: ${VTK_DIR}")
 ENDIF()


Use -Werror in configure.cmake

Use -Werror in configure.cmake

--- src/Native/Unix/configure.cmake
+++ src/Native/Unix/configure.cmake
@@ -24,6 +24,9 @@
     message(FATAL_ERROR "Unknown platform.  Cannot define PAL_UNIX_NAME, used by RuntimeInformation.")
 endif ()

+# We compile with -Werror, so we need to make sure these code fragments compile without warnings.
+set(CMAKE_REQUIRED_FLAGS -Werror)
+
 # in_pktinfo: Find whether this struct exists
 check_include_files(
     linux/in.h
@@ -168,7 +171,11 @@
 check_cxx_source_compiles(
     "
     #include <string.h>
-    int main() { char* c = strerror_r(0, 0, 0); }
+    int main()
+    {
+        char buffer[1];
+        char* c = strerror_r(0, buffer, 0);
+    }
     "
     HAVE_GNU_STRERROR_R)


test failed

test failed

--- mlpack.cmake
+++ mlpack.cmake
@@ -13,6 +13,7 @@

 include (armadillo)
 include (boost)
+include (doxygen)

 external_source (mlpack
@@ -24,7 +25,7 @@

 message ("Installing ${mlpack_NAME} into FlyEM build area: ${BUILDEM_DIR} ...")
 ExternalProject_Add(${mlpack_NAME}
-    DEPENDS             ${armadillo_NAME} ${boost_NAME}
+    DEPENDS             ${armadillo_NAME} ${boost_NAME} ${doxygen_NAME}
     PREFIX              ${BUILDEM_DIR}
     URL                 ${mlpack_URL}
     URL_MD5             ${mlpack_MD5}
@@ -39,7 +40,7 @@

     BUILD_COMMAND       ${BUILDEM_ENV_STRING} make
     INSTALL_COMMAND     ${BUILDEM_ENV_STRING} make install
-    TEST_COMMAND        ${BUILDEM_ENV_STRING} make check
+    # TEST_COMMAND        ${BUILDEM_ENV_STRING} make test
 )

 set_target_properties(${mlpack_NAME} PROPERTIES EXCLUDE_FROM_ALL ON)


ENH: Moved to ITKv4.5.0

ENH: Moved to ITKv4.5.0

--- CMake/Superbuild/ExternalProjectsConfig.cmake
+++ CMake/Superbuild/ExternalProjectsConfig.cmake
@@ -25,5 +25,5 @@
   http://midas3.kitware.com/midas/download/item/208771/fltk-1.3.2.20130812084657.source.tar.gz )
 set( FLTK_URL_MD5_TAG f8b2e249701cf77520546e3c37130f0b )

-set( ITK_URL https://github.com/Kitware/ITK/archive/v4.4.2.tar.gz )
-set( ITK_URL_MD5_TAG aa9006b3dcf05d615988c67aef241f4b )
+set( ITK_URL https://github.com/Kitware/ITK/archive/v4.5.0.tar.gz )
+set( ITK_URL_MD5_TAG c7c5b1adadeba66c49941709375c38dd )


COMP: Temporarily disabled mitkSurfaceToImageFilterTest.

--- Modules/MitkExt/Testing/files.cmake
+++ Modules/MitkExt/Testing/files.cmake
@@ -25,7 +25,7 @@
   #mitkExtractImageFilterTest.cpp
   mitkManualSegmentationToSurfaceFilterTest.cpp
   mitkOverwriteSliceImageFilterTest.cpp
-  mitkSurfaceToImageFilterTest.cpp
+  #mitkSurfaceToImageFilterTest.cpp
 )
 SET(MODULE_CUSTOM_TESTS
   mitkLabeledImageToSurfaceFilterTest.cpp


Resources removed from files.cmake, too.

--- Modules/US/USNavigation/files.cmake
+++ Modules/US/USNavigation/files.cmake
@@ -5,9 +5,3 @@
   Filter/mitkNeedleProjectionFilter.cpp
   Filter/mitkNodeDisplacementFilter.cpp
 )
-
-SET(RESOURCE_FILES
-  Interactions/USZoneInteractions.xml
-  Interactions/USZoneInteractionsHold.xml
-  Interactions/USPointMarkInteractions.xml
-)


remove CXX -pedantic for now

remove CXX -pedantic for now

--- cmake/CFlags.cmake
+++ cmake/CFlags.cmake
@@ -1,4 +1,4 @@
-set(CMAKE_CXX_FLAGS "-std=c++0x -ftemplate-depth=500 -mno-omit-leaf-frame-pointer -fno-omit-frame-pointer -Wall -pedantic ${CMAKE_CXX_FLAGS}")
+set(CMAKE_CXX_FLAGS "-std=c++0x -ftemplate-depth=500 -mno-omit-leaf-frame-pointer -fno-omit-frame-pointer -Wall ${CMAKE_CXX_FLAGS}")
 set(CMAKE_C_FLAGS "-std=c11 -mno-omit-leaf-frame-pointer -fno-omit-frame-pointer -Wall -pedantic ${CMAKE_C_FLAGS}")

 set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -lprotobuf -lz -lpthread")


[c++] Use /permissive- for Visual C++ 2017

Visual C++ 2017 has a new compiler switch to enable a more
standards-compliant mode. Since we build cross-compiler and
cross-platform, this flag can help us catch certain errors faster, so we
now enable it if the compiler supports it.

Closes https://github.com/Microsoft/bond/pull/422

--- cmake/Config.cmake
+++ cmake/Config.cmake
@@ -35,6 +35,17 @@
     # Bond with MSVC CRT-specific code too much. More details at
     # https://msdn.microsoft.com/en-us/library/ms175759.aspx
     add_definitions (-D_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES=1 -D_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES_COUNT=1)
+
+    # Enable standards-conformance mode for MSVC compilers that support this
+    # flag (Visual C++ 2017 and later).
+    #
+    # Our minimum required version of CMake doesn't have GREATER_EQUAL, so
+    # we invert a less-than comparison instead. CMake 3.7 added
+    # GREATER_EQUAL.
+    if (NOT (MSVC_VERSION LESS 1900))
+      add_compile_options (/permissive-)
+    endif()
+
     set (Boost_USE_STATIC_LIBS ON)
 endif (MSVC)


Some minor improvements to the building (without packaging) of OpenCOR on OS X [ci skip].

--- cmake/common.cmake
+++ cmake/common.cmake
@@ -780,6 +780,21 @@
     # A few OS X specific things

     IF(APPLE)
+        # Make sure that the copy of our plugin in our plugins directory refers
+        # to the system version of the Qt libraries on which it depends, this in
+        # case we are not to package OpenCOR
+        # Note: see OS_X_CLEAN_UP_FILE_WITH_QT_LIBRARIES() for the reason...
+
+        IF(NOT "$ENV{PACKAGE_OPENCOR}" STREQUAL "True")
+            FOREACH(QT_LIBRARY ${QT_LIBRARIES})
+                ADD_CUSTOM_TARGET(${QT_LIBRARY}_UPDATE_OS_X_QT_REFERENCE_IN_BUNDLE ALL
+                                  DEPENDS ${PLUGIN_NAME}_COPY_PLUGIN_TO_BUILD_DIRECTORY
+                                  COMMAND install_name_tool -change @executable_path/../Frameworks/${QT_LIBRARY}.framework/Versions/${QT_VERSION_MAJOR}/${QT_LIBRARY}
+                                                                    ${QT_LIBRARY_DIR}/${QT_LIBRARY}.framework/Versions/${QT_VERSION_MAJOR}/${QT_LIBRARY}
+                                                                    ${DEST_PLUGINS_DIR}/${CMAKE_SHARED_LIBRARY_PREFIX}${PLUGIN_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
+            ENDFOREACH()
+        ENDIF()
+
         # Make sure that the copy of our plugin in our main build directory
         # refers to the system version of the Qt libraries on which it depends
         # Note: indeed, right now, it refers to our embedded version of the Qt
@@ -787,7 +802,7 @@
         #       to the system version of the Qt libraries, so...

         FOREACH(QT_LIBRARY ${QT_LIBRARIES})
-            ADD_CUSTOM_TARGET(${PLUGIN_NAME}_UPDATE_OS_X_QT_REFERENCE ALL
+            ADD_CUSTOM_TARGET(${QT_LIBRARY}_UPDATE_OS_X_QT_REFERENCE_IN_BUILD_DIRECTORY ALL
                               DEPENDS ${PLUGIN_NAME}_COPY_PLUGIN_TO_BUILD_DIRECTORY
                               COMMAND install_name_tool -change @executable_path/../Frameworks/${QT_LIBRARY}.framework/Versions/${QT_VERSION_MAJOR}/${QT_LIBRARY}
                                                                 ${QT_LIBRARY_DIR}/${QT_LIBRARY}.framework/Versions/${QT_VERSION_MAJOR}/${QT_LIBRARY}