bugfix for add_wast_executable DEPENDS

bugfix for add_wast_executable DEPENDS

--- CMakeModules/wasm.cmake
+++ CMakeModules/wasm.cmake
@@ -133,7 +133,8 @@
   compile_wast(TARGET ${ARG_TARGET} SOURCE_FILES ${ARG_SOURCE_FILES} INCLUDE_FOLDERS ${ARG_INCLUDE_FOLDERS})

   add_custom_target(${target} ALL DEPENDS ${ARG_TARGET}.bc)
-  set("${ARG_TARGET}_BC_FILENAME" ${CMAKE_CURRENT_SOURCE_DIR}/${ARG_TARGET}.bc CACHE INTERNAL "${target} .bc file")
+  get_filename_component("${ARG_TARGET}_BC_FILENAME" "${CMAKE_CURRENT_SOURCE_DIR}/${ARG_TARGET}.bc" ABSOLUTE CACHE)
+  #set("${ARG_TARGET}_BC_FILENAME" CACHE INTERNAL "${target} .bc file")

   add_custom_command(OUTPUT ${target}.bc
     DEPENDS ${outfiles}
@@ -155,7 +156,7 @@
   foreach(lib ${ARG_LIBRARIES})
      list(APPEND LIBRARIES ${${lib}_BC_FILENAME})
   endforeach()
-
+message("${target} DEPENDS ${outfiles} ${ARG_LIBRARIES} ${LIBRARIES}")
   add_custom_command(OUTPUT ${target}.bc
     DEPENDS ${outfiles} "${ARG_LIBRARIES}" ${LIBRARIES}
     COMMAND ${WASM_LLVM_LINK} -only-needed -o ${target}.bc ${outfiles} ${LIBRARIES} ${ARG_EXTERNAL_LIBRARIES} ${LIBRARIES}


Add dependencies dir to ktool-rom-processor command line

Change-Id: Ic410a20bd8b2e3e2dd715069a7179fa5a515f3c6

--- CMake/CodeGenerator.cmake
+++ CMake/CodeGenerator.cmake
@@ -4,6 +4,9 @@

 set (KTOOL_ROM_PROCESSOR_CHECK_FORMAT FALSE CACHE BOOL "Check if codding style of generated code is correct")
 mark_as_advanced(KTOOL_ROM_PROCESSOR_CHECK_FORMAT)
+
+set (KURENTO_MODULES_DIR /usr/share/kurento/modules CACHE STRING "Directory where kurento modules are installed")
+mark_as_advanced(KURENTO_MODULES_DIR)

 include (CMakeParseArguments)

@@ -46,7 +49,7 @@
     endif()
   endforeach()

-  set (COMMAND_LINE -c ${PARAM_GEN_FILES_DIR} -r ${PARAM_MODELS} -lf)
+  set (COMMAND_LINE -c ${PARAM_GEN_FILES_DIR} -r ${PARAM_MODELS} -dr ${KURENTO_MODULES_DIR} -lf)

   if (DEFINED PARAM_TEMPLATES_DIR)
     set (COMMAND_LINE ${COMMAND_LINE} -t ${PARAM_TEMPLATES_DIR})
@@ -210,12 +213,15 @@

   set(CUSTOM_PREFIX "kurento")

+  set (KURENTO_MODULES_DIR /usr/share/kurento/modules)
+  set (KTOOL_PROCESSOR_LINE ${KTOOL_ROM_PROCESSOR_EXECUTABLE} -r ${PARAM_MODELS} -dr ${KURENTO_MODULES_DIR})
+
   ###############################################################
   # Calculate modules dependencies
   ###############################################################

   execute_process(
-    COMMAND ${KTOOL_ROM_PROCESSOR_EXECUTABLE} -r ${PARAM_MODELS} -t ${CMAKE_CURRENT_SOURCE_DIR}/templates/ -c ${CMAKE_CURRENT_BINARY_DIR}
+    COMMAND ${KTOOL_PROCESSOR_LINE} -t ${CMAKE_CURRENT_SOURCE_DIR}/templates/ -c ${CMAKE_CURRENT_BINARY_DIR}
     OUTPUT_VARIABLE PROCESSOR_OUTPUT
   )

@@ -322,7 +328,7 @@
   set(includedir "\${prefix}/${CMAKE_INSTALL_INCLUDEDIR}/${CUSTOM_PREFIX}")

   execute_process (
-     COMMAND ${KTOOL_ROM_PROCESSOR_EXECUTABLE} -r ${PARAM_MODELS} -t ${CMAKE_CURRENT_SOURCE_DIR}/pkg-config-templates/ -c ${CMAKE_CURRENT_BINARY_DIR} -lf
+     COMMAND ${KTOOL_PROCESSOR_LINE} -t ${CMAKE_CURRENT_SOURCE_DIR}/pkg-config-templates/ -c ${CMAKE_CURRENT_BINARY_DIR} -lf
      OUTPUT_VARIABLE PROCESSOR_OUTPUT
   )

@@ -517,7 +523,7 @@
   endforeach()

   execute_process(
-    COMMAND ${KTOOL_ROM_PROCESSOR_EXECUTABLE} -r ${PARAM_MODELS} -s ${PARAM_KEYS}
+    COMMAND ${KTOOL_ROM_PROCESSOR_EXECUTABLE} -r ${PARAM_MODELS} -dr ${KURENTO_MODULES_DIR} -s ${PARAM_KEYS}
     OUTPUT_VARIABLE PROCESSOR_OUTPUT
   )


include "." in the search paths

include "." in the search paths

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

--- CMakeModules/Sagase.cmake
+++ CMakeModules/Sagase.cmake
@@ -43,8 +43,6 @@
     #    file (TO_CMAKE_PATH "${prefix}" p)
     #    set (normal_path_prefixes ${normal_path_prefixes} ${p})
     #endforeach ()
-
-    set (path_names ${path_names} ".")

     # add prefix+name paths
     foreach (prefix ${path_prefixes})
@@ -184,6 +182,9 @@
     if (NOT found_)
         message (STATUS "trying brute-force search ")

+        # take names to be directory names, and include "."
+        set (PKG_NAMES ${PKG_NAMES} ".")
+
         # generate a combination of possible search paths
         sagase_generate_paths (include_paths library_paths NAMES ${PKG_NAMES} PREFIXES ${PKG_PREFIXES})


convert cmake build to sagase/use_package: fixed typeo

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

--- CMakeModules/Sagase.cmake
+++ CMakeModules/Sagase.cmake
@@ -56,8 +56,8 @@
         foreach (pkgname ${path_names})

             set (includes ${includes}
-                ${prefix}/${pkgname}/includes
-                ${prefix}/includes/${pkgname})
+                ${prefix}/${pkgname}/include
+                ${prefix}/include/${pkgname})

             set (libraries ${libraries}
                 ${prefix}/${pkgname}/lib ${prefix}/lib/${pkgname}


Fix toolchain flags for release modes

Fix toolchain flags for release modes

Now proper flags are set when using this toolchain

--- toolchains/arm-cm4-gnu.cmake
+++ toolchains/arm-cm4-gnu.cmake
@@ -53,16 +53,22 @@
 	CACHE STRING "C++ flags")

 # Release flags, optimization is on,
-set(CMAKE_C_FLAGS_RELEASE "-O3 -flto=4 -ffat-lto-objects " CACHE STRING "Debug C flags")
-set(CMAKE_CXX_FLAGS_RELEASE ${CMAKE_C_FLAGS_RELEASE})
+set(CMAKE_C_FLAGS_RELEASE "-O3 -flto=4 -ffat-lto-objects "
+	CACHE STRING "Release C flags")
+set(CMAKE_CXX_FLAGS_RELEASE ${CMAKE_C_FLAGS_RELEASE}
+	CACHE STRING "Release C++ flags")

 # Minimum size release flags, LTO and minimum size
-set(CMAKE_C_FLAGS_MINSIZEREL "-Os -flto=4 -ffat-lto-objects ")
-set(CMAKE_CXX_FLAGS_MINSIZEREL ${CMAKE_C_FLAGS_MINSIZEREL})
+set(CMAKE_C_FLAGS_MINSIZEREL "-Os -flto=4 -ffat-lto-objects "
+	CACHE STRING "Minsize C flags")
+set(CMAKE_CXX_FLAGS_MINSIZEREL ${CMAKE_C_FLAGS_MINSIZEREL}
+	CACHE STRING "Minsize C++ flags")

 # Debug mode, no LTO and maximum debug info
-set(CMAKE_C_FLAGS_DEBUG  "-O0 -g3 " CACHE STRING "Debug C flags")
-set(CMAKE_CXX_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG} CACHE STRING "Debug C++ flags")
+set(CMAKE_C_FLAGS_DEBUG  "-O0 -g3 "
+	CACHE STRING "Debug C flags")
+set(CMAKE_CXX_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG}
+	CACHE STRING "Debug C++ flags")

 set(CMAKE_OBJCOPY arm-none-eabi-objcopy CACHE STRING "Objcopy executable")


numpy.cmake: Only apply patch to system_info.py when building on Mac. (It doesn't seem to harm other platforms, but it's better to avoid unecessary patches.)

--- numpy.cmake
+++ numpy.cmake
@@ -49,8 +49,12 @@
 endif()

 # Patch 2: system info (see above)
-set(NUMPY_PATCH_SYSTEM_INFO_PY ${PATCH_EXE} ${numpy_SRC_DIR}/numpy/distutils/system_info.py ${PATCH_DIR}/numpy.patch)
-set(NUMPY_PATCH_COMMAND ${NUMPY_REPLACE_SITE_CFG} && ${NUMPY_PATCH_SYSTEM_INFO_PY})
+if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
+	set(NUMPY_PATCH_SYSTEM_INFO_PY ${PATCH_EXE} ${numpy_SRC_DIR}/numpy/distutils/system_info.py ${PATCH_DIR}/numpy.patch)
+	set(NUMPY_PATCH_COMMAND ${NUMPY_REPLACE_SITE_CFG} && ${NUMPY_PATCH_SYSTEM_INFO_PY})
+else()
+	set(NUMPY_PATCH_COMMAND ${NUMPY_REPLACE_SITE_CFG})
+endif()

 # Download and install numpy
 message ("Installing ${numpy_NAME} into FlyEM build area: ${BUILDEM_DIR} ...")


dev: Fix FindCriterion.cmake package name

--- dev/FindCriterion.cmake
+++ dev/FindCriterion.cmake
@@ -4,9 +4,9 @@
 # - Try to find Criterion
 #
 # Once done this will define
-#  CRITERION_FOUND - System has LibXml2
-#  CRITERION_INCLUDE_DIRS - The LibXml2 include directories
-#  CRITERION_LIBRARIES - The libraries needed to use LibXml2
+#  CRITERION_FOUND - System has Criterion
+#  CRITERION_INCLUDE_DIRS - The Criterion include directories
+#  CRITERION_LIBRARIES - The libraries needed to use Criterion

 find_package(PkgConfig)

@@ -19,9 +19,9 @@
 set(CRITERION_INCLUDE_DIRS ${CRITERION_INCLUDE_DIR})

 include(FindPackageHandleStandardArgs)
-# handle the QUIETLY and REQUIRED arguments and set CRITERION_FOUND to TRUE
+# handle the QUIET and REQUIRED arguments and set CRITERION_FOUND to TRUE
 # if all listed variables are TRUE
-find_package_handle_standard_args(LibXml2 DEFAULT_MSG
+find_package_handle_standard_args(Criterion DEFAULT_MSG
                                   CRITERION_LIBRARY CRITERION_INCLUDE_DIR)

 mark_as_advanced(CRITERION_INCLUDE_DIR CRITERION_LIBRARY)


standardize target suffix

standardize target suffix

--- cmake/rosidl_typesupport_introspection_cpp_generate_interfaces.cmake
+++ cmake/rosidl_typesupport_introspection_cpp_generate_interfaces.cmake
@@ -63,7 +63,7 @@
   VERBATIM
 )

-set(_target_suffix "__typesupport_introspection_cpp")
+set(_target_suffix "__rosidl_typesupport_introspection_cpp")

 add_library(${rosidl_generate_interfaces_TARGET}${_target_suffix} SHARED ${_generated_files})
 if(WIN32)


fixed several bugs related to the combined compilation and installation commands in Examples.cmake;

--- Examples/Examples.cmake
+++ Examples/Examples.cmake
@@ -1,4 +1,5 @@
-option(WITH_MEX "Enable compilation of the Matlab interface. This will be automatically disabled if Matlab is not found. However, unresolved issues in Matlab cmake module can cause compilation errors even if a valid Matlab installation is found. This option can be turned off to avoid such issues." ON)
+option(WITH_PY "Enable compilation of the Python interface. This will be automatically disabled if Python is not found but can be manually disabled using this option if Python is found but some undocumented conflicts are causing build errors" ON)
+option(WITH_MEX "Enable compilation of the Matlab interface. This will be automatically disabled if Matlab is not found. However, unresolved issues in Matlab cmake module can cause build errors even if a valid Matlab installation is found. This option can be turned off to avoid such issues." ON)

 if (WIN32)
 	set(MTF_EXEC_INSTALL_DIR_DEFAULT C:/MTF/bin)
@@ -24,6 +25,9 @@
 # find_package(Boost REQUIRED COMPONENTS filesystem system)
 # message(STATUS "Boost_LIBRARIES:")
 # message(STATUS "Examples: MTF_RUNTIME_FLAGS: ${MTF_RUNTIME_FLAGS} ${MTF_COMPILETIME_FLAGS}")
+set(EX_TARGET_NAMES runMTF createMosaic generateSyntheticSeq trackUAVTrajectory extractPatch testMTF)
+set(EX_INSTALL_TARGET_NAMES install_exe install_mos install_syn install_uav install_patch install_test install_test_lib)
+set(EX_COMBINED_TARGET_NAMES mtfe mtfm mtfs mtfu mtfpa mtft)

 add_executable(runMTF Examples/cpp/runMTF.cc)
 target_compile_definitions(runMTF PUBLIC ${MTF_DEFINITIONS})
@@ -42,6 +46,7 @@
 	add_custom_target(mtfe DEPENDS runMTF install_exe)
 endif()

+
 add_executable(trackUAVTrajectory Examples/cpp/trackUAVTrajectory.cc)
 target_compile_definitions(trackUAVTrajectory PUBLIC ${MTF_DEFINITIONS})
 target_compile_options(trackUAVTrajectory PUBLIC ${MTF_RUNTIME_FLAGS} ${MTF_COMPILETIME_FLAGS})
@@ -58,6 +63,7 @@
 	  )
 	add_custom_target(mtfu DEPENDS trackUAVTrajectory install_uav)
 endif()
+
 if(FEAT_ENABLED)
 	add_executable(trackMarkers Examples/cpp/trackMarkers.cc)
 	target_compile_definitions(trackMarkers PUBLIC ${MTF_DEFINITIONS})
@@ -74,7 +80,10 @@
 		   DEPENDS trackMarkers
 		  )
 		add_custom_target(mtfq DEPENDS trackMarkers install_qr)
+		set(EX_INSTALL_TARGET_NAMES ${EX_INSTALL_TARGET_NAMES} install_qr)
+		set(EX_COMBINED_TARGET_NAMES ${EX_COMBINED_TARGET_NAMES} mtfq)
 	endif()
+	set(EX_TARGET_NAMES ${EX_TARGET_NAMES} trackMarkers)
 endif()

 add_executable(extractPatch Examples/cpp/extractPatch.cc)
@@ -128,38 +137,46 @@
 	add_custom_target(mtfm DEPENDS createMosaic install_mos)
 endif()

-find_package(PythonLibs 2.7)
-find_package(NumPy)
-if(PYTHONLIBS_FOUND AND PYTHON_NUMPY_FOUND)
-	if(PYTHONLIBS_VERSION_STRING VERSION_LESS 3.0.0)
-		add_library(pyMTF MODULE Examples/cpp/pyMTF.cc)
-		set_target_properties(pyMTF PROPERTIES PREFIX "")
-		if(WIN32)
-			set_target_properties(pyMTF PROPERTIES SUFFIX ".pyd")
-		endif()
-		target_compile_definitions(pyMTF PUBLIC ${MTF_DEFINITIONS})
-		target_compile_options(pyMTF PUBLIC ${MTF_RUNTIME_FLAGS} ${MTF_COMPILETIME_FLAGS})
-		target_include_directories(pyMTF PUBLIC ${MTF_INCLUDE_DIRS} ${MTF_EXT_INCLUDE_DIRS} ${PYTHON_INCLUDE_DIRS} ${PYTHON_NUMPY_INCLUDE_DIR})
-		message(STATUS "PYTHON_INCLUDE_DIRS: ${PYTHON_INCLUDE_DIRS}")
-		message(STATUS "PYTHON_LIBRARIES: ${PYTHON_LIBRARIES}")
-		target_link_libraries(pyMTF mtf ${MTF_LIBS} ${PYTHON_LIBRARIES} ${PYTHON_LIBS})
-		install(TARGETS pyMTF LIBRARY DESTINATION ${MTF_PY_INSTALL_DIR} COMPONENT py)
-		add_custom_target(py DEPENDS pyMTF)
-		if(NOT WIN32)
-			add_custom_target(install_py
-			  ${CMAKE_COMMAND}
-			  -D "CMAKE_INSTALL_COMPONENT=py"
-			  -P "${MTF_BINARY_DIR}/cmake_install.cmake"
-			   DEPENDS pyMTF
-			  )
-			  add_custom_target(mtfp DEPENDS pyMTF install_py)
-		  endif()
-	  else()
-		message(STATUS "Incompatible version of Python library found so pyMTF is disabled: " ${PYTHONLIBS_VERSION_STRING})
-	endif()
-else()
-	message(STATUS "Python and/or Numpy not found so pyMTF is disabled")
-endif()
+if(WITH_PY)
+	find_package(PythonLibs 2.7)
+	find_package(NumPy)
+	if(PYTHONLIBS_FOUND AND PYTHON_NUMPY_FOUND)
+		if(PYTHONLIBS_VERSION_STRING VERSION_LESS 3.0.0)
+			add_library(pyMTF MODULE Examples/cpp/pyMTF.cc)
+			set_target_properties(pyMTF PROPERTIES PREFIX "")
+			if(WIN32)
+				set_target_properties(pyMTF PROPERTIES SUFFIX ".pyd")
+			endif()
+			target_compile_definitions(pyMTF PUBLIC ${MTF_DEFINITIONS})
+			target_compile_options(pyMTF PUBLIC ${MTF_RUNTIME_FLAGS} ${MTF_COMPILETIME_FLAGS})
+			target_include_directories(pyMTF PUBLIC ${MTF_INCLUDE_DIRS} ${MTF_EXT_INCLUDE_DIRS} ${PYTHON_INCLUDE_DIRS} ${PYTHON_NUMPY_INCLUDE_DIR})
+			message(STATUS "PYTHON_INCLUDE_DIRS: ${PYTHON_INCLUDE_DIRS}")
+			message(STATUS "PYTHON_LIBRARIES: ${PYTHON_LIBRARIES}")
+			target_link_libraries(pyMTF mtf ${MTF_LIBS} ${PYTHON_LIBRARIES} ${PYTHON_LIBS})
+			install(TARGETS pyMTF LIBRARY DESTINATION ${MTF_PY_INSTALL_DIR} COMPONENT py)
+			add_custom_target(py DEPENDS pyMTF)
+			if(NOT WIN32)
+				add_custom_target(install_py
+				  ${CMAKE_COMMAND}
+				  -D "CMAKE_INSTALL_COMPONENT=py"
+				  -P "${MTF_BINARY_DIR}/cmake_install.cmake"
+				   DEPENDS pyMTF
+				  )
+				  add_custom_target(mtfp DEPENDS pyMTF install_py)
+				  set(EX_INSTALL_TARGET_NAMES ${EX_INSTALL_TARGET_NAMES} install_py)
+				  set(EX_COMBINED_TARGET_NAMES ${EX_COMBINED_TARGET_NAMES} mtfp)
+			  endif()
+			set(EX_TARGET_NAMES ${EX_TARGET_NAMES} pyMTF)
+		  else()
+			message(STATUS "Incompatible version of Python library found so pyMTF is disabled: " ${PYTHONLIBS_VERSION_STRING})
+		endif()
+	else()
+		message(STATUS "Python and/or Numpy not found so pyMTF is disabled")
+	endif()
+else(WITH_PY)
+	message(STATUS "Python interface (pyMTF) is disabled")
+endif(WITH_PY)
+

 if(WITH_MEX)
 	find_package(Matlab COMPONENTS MEX_COMPILER MX_LIBRARY)
@@ -183,8 +200,11 @@
 			  -P "${MTF_BINARY_DIR}/cmake_install.cmake"
 			   DEPENDS mexMTF
 			  )
-			add_custom_target(mtfx DEPENDS mexMTF install_mex)
+			add_custom_target(mtfx DEPENDS mexMTF install_mex)
+			set(EX_INSTALL_TARGET_NAMES ${EX_INSTALL_TARGET_NAMES} install_mex)
+			set(EX_COMBINED_TARGET_NAMES ${EX_COMBINED_TARGET_NAMES} mtfx)
 		endif()
+		set(EX_TARGET_NAMES ${EX_TARGET_NAMES} mexMTF)
 	else()
 		message(STATUS "Matlab not found so mexMTF is disabled")
 		if(NOT WIN32)
@@ -220,8 +240,8 @@
 	  )
 	add_custom_target(mtft DEPENDS testMTF mtf_test install_test install_test_lib)
 endif()
-add_custom_target(all DEPENDS runMTF createMosaic generateSyntheticSeq trackUAVTrajectory trackMarkers extractPatch pyMTF testMTF)
-if(NOT WIN32)
-	add_custom_target(install_all DEPENDS install_exe install_mos install_syn install_uav install_qr install_py)
-	add_custom_target(mtfall DEPENDS mtfe mtfu mtfm mtfs mtfq mtfpa mtft)
+add_custom_target(all DEPENDS ${EX_TARGET_NAMES})
+if(NOT WIN32)
+	add_custom_target(install_all DEPENDS ${EX_INSTALL_TARGET_NAMES})
+	add_custom_target(mtfall DEPENDS ${EX_COMBINED_TARGET_NAMES})
 endif()


Add missing include

Add missing include

--- Common.cmake
+++ Common.cmake
@@ -171,6 +171,7 @@
 endif(APPLE)

 # hooks to gather all targets (libraries & executables)
+include(ParseArguments)
 set(ALL_DEP_TARGETS "")
 set(ALL_LIB_TARGETS "")
 macro(add_executable _target)


Adding the number of filters that each plugin is compiling as additional information during cmake time

--- TransformationPhaseFilters/SourceList.cmake
+++ TransformationPhaseFilters/SourceList.cmake
@@ -30,6 +30,10 @@
 )

+
+list(LENGTH _PublicFilters PluginNumFilters)
+set_property(GLOBAL PROPERTY PluginNumFilters ${PluginNumFilters})
+
 #--------------
 # Loop on all the filters adding each one. In this loop we default to making each filter exposed in the user
 # interface in DREAM3D. If you want to have the filter compiled but NOT exposed to the user then use the next loop


[WIP] reveal koji_scratch_build for each dist.

--- Modules/UseFedpkg.cmake
+++ Modules/UseFedpkg.cmake
@@ -60,7 +60,7 @@
     SET(_bodhi_template_file "bodhi.NO_PACK.template")
     SET(PACK_SOURCE_IGNORE_FILES ${PACK_SOURCE_IGNORE_FILES} "/${FEDPKG_DIR}/")

-    MACRO(_use_koji_make_cmds srpm tags)
+    MACRO(_use_koji_make_targets srpm tags)
 	#commit
 	IF(DEFINED CHANGE_SUMMARY)
 	    SET (COMMIT_MSG  "-m \"${CHANGE_SUMMARY}\"")
@@ -81,10 +81,12 @@
 		COMMAND ${KOJI} build --scratch dist-${_branch} ${srpm}
 		COMMENT "koji scratch build on ${_branch} with ${srpm}"
 		)
+
+	    ADD_DEPENDENCIES(koji_scratch_build koji_scratch_build_${_branch})
 	ENDFOREACH(_tag ${tags})
-    ENDMACRO(_use_koji_make_cmds srpm tags)
-
-    MACRO(_use_fedpkg_make_cmds srpm tags)
+    ENDMACRO(_use_koji_make_targets srpm tags)
+
+    MACRO(_use_fedpkg_make_targets srpm tags)
 	#commit
 	IF (DEFINED CHANGE_SUMMARY)
 	    SET (COMMIT_MSG  "-m \"${CHANGE_SUMMARY}\"")
@@ -104,7 +106,16 @@
 	ADD_CUSTOM_TARGET(fedpkg_update
 	    COMMENT "fedpkg update"
 	    )
-	#MESSAGE("tags=${tags}")
+	MESSAGE("tags=${tags}")
+
+	## Know the tag file path
+	#LIST(GET tags 0 _first_tag)
+	LIST(LENGTH "${tags}"  _first_tag)
+	MESSAGE("_first_tag=${_first_tag}")
+	# bodhi tags is used as tag file name
+	_use_bodhi_convert_tag(_first_bodhi_tag ${_first_tag})
+	SET(_first_tag_path  ${FEDPKG_DIR}/${PROJECT_NAME}/.git/ref/tags/${PROJECT_NAME}-${PRJ_VER}-${PRJ_RELEASE_NO}.${_first_tag})
+	MESSAGE("_first_tag_path=${_first_tag_path}")

 	FOREACH(_tag ${tags})
 	    IF(_tag STREQUAL "${FEDORA_RAWHIDE_TAG}")
@@ -127,7 +138,7 @@
 		COMMAND git pull
 		COMMAND ${FEDPKG} build
 		WORKING_DIRECTORY ${FEDPKG_DIR}/${PROJECT_NAME}
-		DEPENDS ${FEDPKG_DIR}/${PROJECT_NAME}/.git/ref/tags/${PRJ_VER}
+		DEPENDS ${_first_tag_path}
 		COMMENT "fedpkg build on ${_branch} with ${srpm}"
 		)
 	    ADD_DEPENDENCIES(fedpkg_build fedpkg_build_${_branch})
@@ -137,7 +148,7 @@
 		COMMAND git pull
 		COMMAND ${FEDPKG} update
 		WORKING_DIRECTORY ${FEDPKG_DIR}/${PROJECT_NAME}
-		DEPENDS ${FEDPKG_DIR}/${PROJECT_NAME}/.git/ref/tags/${PRJ_VER}
+		DEPENDS ${_first_tag_path}
 		COMMENT "fedpkg update on ${_branch} with ${srpm}"
 		)
 	    ADD_DEPENDENCIES(fedpkg_update fedpkg_update_${_branch})
@@ -146,31 +157,28 @@
 		SET(_first_branch ${_branch})

 		# import first
-		ADD_CUSTOM_COMMAND(OUTPUT
-		    ${FEDPKG_DIR}/${PROJECT_NAME}/.git/ref/tags/${PRJ_VER}
+		ADD_CUSTOM_COMMAND(OUTPUT ${_first_tag_path}
 		    COMMAND COMMAND ${FEDPKG} switch-branch ${_branch}
 		    COMMAND git pull
 		    COMMAND ${FEDPKG} import  ${srpm}
 		    COMMAND ${FEDPKG} commit -t -m "Release version ${PRJ_VER}" -p
-		    COMMAND git push
-		    COMMAND git push --tags
 		    WORKING_DIRECTORY ${FEDPKG_DIR}/${PROJECT_NAME}
 		    COMMENT "fedpkg import on ${_branch} with ${srpm}"
 		    VERBATIM
 		    )

 		ADD_CUSTOM_TARGET(fedpkg_commit_${_branch}
-		    DEPENDS ${FEDPKG_DIR}/${PROJECT_NAME}/.git/ref/tags/${PRJ_VER}
+		    DEPENDS ${_first_tag_path}
 		    COMMENT "fedpkg commit on ${_branch} with ${srpm}"
 		    )

 	    ELSE(_first_branch STREQUAL "")
 		ADD_CUSTOM_TARGET(fedpkg_commit_${_branch}
 		    COMMAND ${FEDPKG} switch-branch ${_branch}
-		    COMMAND git pull
+		    COMMAND fedpkg pull
 		    COMMAND git merge ${_first_branch}
-		    COMMAND git push
-		    DEPENDS ${FEDPKG_DIR}/${PROJECT_NAME}/.git/ref/tags/${PRJ_VER}
+		    COMMAND fedpkg push
+		    DEPENDS ${_first_tag_path}
 		    WORKING_DIRECTORY ${FEDPKG_DIR}/${PROJECT_NAME}
 		    COMMENT "fedpkg commit on ${_branch} with ${srpm}"
 		    )
@@ -179,7 +187,7 @@
 	    ADD_DEPENDENCIES(fedpkg_build_${_branch} fedpkg_commit_${_branch})

 	ENDFOREACH(_tag ${tags})
-    ENDMACRO(_use_fedpkg_make_cmds tags srpm)
+    ENDMACRO(_use_fedpkg_make_targets tags srpm)

     MACRO(USE_FEDPKG srpm)
 	IF(EXISTS $ENV{HOME}/.fedora-upload-ca.cert)
@@ -227,7 +235,7 @@

 		## Make target commands for the released dist
-		_use_fedpkg_make_cmds("${srpm}" "${_koji_dist_tags}")
+		_use_fedpkg_make_targets("${srpm}" "${_koji_dist_tags}")

 		#ADD_DEPENDENCIES(fedpkg_build fedpkg_commit)

@@ -237,15 +245,11 @@
 		MESSAGE("Program koji is not found!")
 	    ELSE(KOJI STREQUAL "KOJI-NOTFOUND")
 		## Make target commands for the released dist
-		_use_koji_make_cmds("${srpm}" "${_koji_dist_tags}")
-
-		#MESSAGE("KOJI_SCRATCH_BUILD_CMD=${KOJI_SCRATCH_BUILD_CMD}")
 		ADD_CUSTOM_TARGET(koji_scratch_build
-		    COMMAND eval "${KOJI_SCRATCH_BUILD_CMD}"
-		    DEPENDS ${srpm} ChangeLog
-		    COMMENT "Start Koji scratch build"
-		    VERBATIM
-		    )
+		    COMMENT "Koji scratch build"
+		    )
+		_use_koji_make_targets("${srpm}" "${_koji_dist_tags}")
+
 	    ENDIF(KOJI STREQUAL "KOJI-NOTFOUND")

 	ENDIF(EXISTS $ENV{HOME}/.fedora-upload-ca.cert)


Use color Clang diagnostics when using Ninja build system

--- Source/CMake/Modules/Urho3D-CMake-magic.cmake
+++ Source/CMake/Modules/Urho3D-CMake-magic.cmake
@@ -241,6 +241,10 @@
         set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DDEBUG -D_DEBUG")
         set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DDEBUG -D_DEBUG")
     endif ()
+    if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang" AND CMAKE_GENERATOR STREQUAL "Ninja")
+      set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fcolor-diagnostics")
+      set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fcolor-diagnostics")
+    endif()
 endif ()

 # Include CMake builtin module for building shared library support


Fix HAL BASE cmake variable for stm32f104 projects.

--- backends/stm32/stm32f4/cmake/stm32f4.cmake
+++ backends/stm32/stm32f4/cmake/stm32f4.cmake
@@ -11,7 +11,6 @@
 endfunction()

 set (STM32F4_ROOT_DIR		"${CMAKE_CURRENT_LIST_DIR}/..")
-set (BASE_HAL_DIR			"${CMAKE_CURRENT_LIST_DIR}/../../../hal/")

 SET(CMAKE_CROSSCOMPILING TRUE)


Fixing bug where on OS X static libraries are found first

--- Resources/FindBoost-alt.cmake
+++ Resources/FindBoost-alt.cmake
@@ -176,7 +176,7 @@

   #MESSAGE (STATUS "BOOST_LIBRARIES_SUFFIXES==> ${BOOST_LIBRARIES_SUFFIXES}")

-  FOREACH (TMP_BOOST_LIBRARIES_SUFFIX "" ${BOOST_LIBRARIES_SUFFIXES})
+  FOREACH (TMP_BOOST_LIBRARIES_SUFFIX ${BOOST_LIBRARIES_SUFFIXES} "" )

     FIND_LIBRARY(BOOST_DATE_TIME_LIBRARY
         boost_date_time${TMP_BOOST_LIBRARIES_SUFFIX}


Pass CMAKE_CXX_FLAGS through to llvm configuration.

Change-Id: I231bfffab0cc9eab840afb8825c399f9a68fafff
Reviewed-on: https://wn-project.dnsalias.net/gerrit/160
Reviewed-by: Devon Powell <bef84a74f4a3947934cc58306a6aae518eaf1936@gmail.com>
Try: Devon Powell <bef84a74f4a3947934cc58306a6aae518eaf1936@gmail.com>
Reviewed-by: Andrew Woloszyn <2926f0436f8103ab8257713335cf26447d8bf68a@google.com>
Try: Andrew Woloszyn <2926f0436f8103ab8257713335cf26447d8bf68a@google.com>
Tested-by: WNBot <efa0942020584fb66fb8bea377b59e48fa0f85ef@gmail.com>

--- Utilities/helpers.cmake
+++ Utilities/helpers.cmake
@@ -226,6 +226,8 @@
   endif()
 endif()

+list(APPEND WN_LLVM_EXTRA_FLAGS "-DCMAKE_CXX_FLAGS=${CMAKE_CXX_FLAGS}")
+
 # Create the llvm build directory.
 execute_process(COMMAND ${CMAKE_COMMAND} -E
   make_directory ${CMAKE_CURRENT_BINARY_DIR}/Externals/llvm)


make the testsuite works on windows with nmake

--- test/testsuite.cmake
+++ test/testsuite.cmake
@@ -82,11 +82,7 @@
 endif(NOT EIGEN_SITE)

 if(NOT EIGEN_CMAKE_DIR)
-  if(WIN32)
-    SET(EIGEN_CMAKE_DIR "C:/Program Files/CMake/bin/")
-  else(WIN32)
-    SET(EIGEN_CMAKE_DIR "")
-  endif(WIN32)
+  SET(EIGEN_CMAKE_DIR "")
 endif(NOT EIGEN_CMAKE_DIR)

 if(NOT EIGEN_BUILD_STRING)
@@ -163,6 +159,8 @@
 # this is the initial cache to use for the binary tree, be careful to escape
 # any quotes inside of this string if you use it
 if(WIN32)
+  #message(SEND_ERROR "win32")
+  set(CTEST_CMAKE_COMMAND "${CTEST_CMAKE_COMMAND} -G \"NMake Makefiles\" -DCMAKE_MAKE_PROGRAM=nmake")
   SET (CTEST_INITIAL_CACHE "
     MAKECOMMAND:STRING=nmake -i
     CMAKE_MAKE_PROGRAM:FILEPATH=nmake


Disable ESXi builds by default, add arg_test_vmk flag; reviewed as http://codereview.appspot.com/1640042

SVN-Revision: 18

--- tests/runsuite.cmake
+++ tests/runsuite.cmake
@@ -56,7 +56,8 @@
 set(arg_nightly OFF)  # whether to report the results
 set(arg_long OFF)     # whether to run the long suite
 set(arg_already_built OFF) # for testing on ESXi w/ already-built suite
-set(arg_vmk_only OFF) # for testing on ESXi: only run vmk builds
+set(arg_test_vmk OFF) # for testing of ESXi on Linux: run vmk builds
+set(arg_vmk_only  OFF) # for testing on ESXi: run only vmk builds
 set(arg_include "")   # cmake file to include up front
 set(arg_preload "")   # cmake file to include prior to each 32-bit build
 set(arg_preload64 "") # cmake file to include prior to each 64-bit build
@@ -82,6 +83,9 @@
   if (${arg} STREQUAL "already_built")
     set(arg_already_built ON)
   endif (${arg} STREQUAL "already_built")
+  if (${arg} STREQUAL "test_vmk")
+    set(arg_test_vmk ON)
+  endif (${arg} STREQUAL "test_vmk")
   if (${arg} STREQUAL "vmk_only")
     set(arg_vmk_only ON)
   endif (${arg} STREQUAL "vmk_only")
@@ -113,21 +117,25 @@
   endif (UNIX)
 endforeach (arg)

+if (arg_test_vmk AND arg_vmk_only)
+  message(FATAL_ERROR "you can't specify both test_vmk and vmk_only")
+endif (arg_test_vmk AND arg_vmk_only)
+
 if (NOT arg_vmk_only)
   if (NOT EXISTS "${DR_path}")
     # env var DYNAMORIO_HOME is fallback
     set(DR_path "$ENV{DYNAMORIO_HOME}/cmake")
   endif (NOT EXISTS "${DR_path}")
   if (NOT EXISTS "${DR_path}")
-    message(FATAL_ERROR "cannot find DynamoRIO Linux build at ${DR_path}")
+    message(FATAL_ERROR "cannot find DynamoRIO build at ${DR_path}")
   endif (NOT EXISTS "${DR_path}")
 endif (NOT arg_vmk_only)

-if (UNIX)
+if (arg_vmk_only OR arg_test_vmk)
   if (NOT EXISTS "${DRvmk_path}")
     message(FATAL_ERROR "cannot find DynamoRIO VMKERNEL build at ${DRvmk_path}")
   endif (NOT EXISTS "${DRvmk_path}")
-endif (UNIX)
+endif (arg_vmk_only OR arg_test_vmk)

 # allow setting the base cache variables via an include file
 set(base_cache "")
@@ -368,18 +376,20 @@
       " ON) # only run release tests for long suite
   endif (NOT arg_vmk_only)
   if (UNIX)
-    testbuild("${name}-vmk-debug-32" OFF "
-      ${tool}
-      DynamoRIO_DIR:PATH=${DRvmk_path}
-      CMAKE_BUILD_TYPE:STRING=Debug
-      VMKERNEL:BOOL=ON
-      " OFF)
-    testbuild("${name}-vmk-release-32" OFF "
-      ${tool}
-      DynamoRIO_DIR:PATH=${DRvmk_path}
-      CMAKE_BUILD_TYPE:STRING=Release
-      VMKERNEL:BOOL=ON
-      " ON) # only run release tests for long suite
+    if (arg_vmk_only OR arg_test_vmk)
+      testbuild("${name}-vmk-debug-32" OFF "
+        ${tool}
+        DynamoRIO_DIR:PATH=${DRvmk_path}
+        CMAKE_BUILD_TYPE:STRING=Debug
+        VMKERNEL:BOOL=ON
+        " OFF)
+      testbuild("${name}-vmk-release-32" OFF "
+        ${tool}
+        DynamoRIO_DIR:PATH=${DRvmk_path}
+        CMAKE_BUILD_TYPE:STRING=Release
+        VMKERNEL:BOOL=ON
+        " ON) # only run release tests for long suite
+    endif (arg_vmk_only OR arg_test_vmk)
   else (UNIX)
     if ("${tool}" MATCHES "MEMORY")
       # No online symbol support for cygwin yet so using separate build


Fixed: don't look for Ogre library binaries for linking when we are using Ogre sources - instead, use the target names.

--HG--
branch : v1-9

--- CMake/Packages/FindOGRE.cmake
+++ CMake/Packages/FindOGRE.cmake
@@ -215,8 +215,17 @@
   set(OGRE_INCOMPATIBLE FALSE)
 endif ()

-find_library(OGRE_LIBRARY_REL NAMES ${OGRE_LIBRARY_NAMES} HINTS ${OGRE_LIB_SEARCH_PATH} ${OGRE_PKGC_LIBRARY_DIRS} ${OGRE_FRAMEWORK_SEARCH_PATH} PATH_SUFFIXES "" "Release" "RelWithDebInfo" "MinSizeRel")
-find_library(OGRE_LIBRARY_DBG NAMES ${OGRE_LIBRARY_NAMES_DBG} HINTS ${OGRE_LIB_SEARCH_PATH} ${OGRE_PKGC_LIBRARY_DIRS} ${OGRE_FRAMEWORK_SEARCH_PATH} PATH_SUFFIXES "" "Debug")
+if (NOT OGRE_SOURCE) # If using ogre sources, use the target names instead of library files to link.
+	find_library(OGRE_LIBRARY_REL NAMES ${OGRE_LIBRARY_NAMES} HINTS ${OGRE_LIB_SEARCH_PATH} ${OGRE_PKGC_LIBRARY_DIRS} ${OGRE_FRAMEWORK_SEARCH_PATH} PATH_SUFFIXES "" "Release" "RelWithDebInfo" "MinSizeRel")
+	find_library(OGRE_LIBRARY_DBG NAMES ${OGRE_LIBRARY_NAMES_DBG} HINTS ${OGRE_LIB_SEARCH_PATH} ${OGRE_PKGC_LIBRARY_DIRS} ${OGRE_FRAMEWORK_SEARCH_PATH} PATH_SUFFIXES "" "Debug")
+else()
+	if( NOT OGRE_LIBRARIES OR OGRE_LIBRARIES STREQUAL "" )
+		message( FATAL_ERROR "When using Ogre from sources, please specify target names in OGRE_LIBRARIES!" )
+	else()
+		message( "Using Ogre source instead of binary libraries - skipping library files search." )
+	endif()
+endif()
+
 make_library_set(OGRE_LIBRARY)

 if(APPLE)


CMAKE: Use ATen's new upstream location

CMAKE: Use ATen's new upstream location

--- SuperBuild/ExternalATen.cmake
+++ SuperBuild/ExternalATen.cmake
@@ -18,14 +18,15 @@
 #=========================================================================

 set( proj ATen )
-set( ATen_REPOSITORY https://github.com/zdevito/ATen )
-set( ATen_TAG 635e9ef1f881391539e7426899370ebfe094fabd )
+set( ATen_REPOSITORY https://github.com/pytorch/pytorch )
+set( ATen_TAG 82e995e0b9bc73cedf98016b910297b44563342f )

 ExternalProject_Add( ${proj}
   GIT_REPOSITORY ${ATen_REPOSITORY}
   GIT_TAG ${ATen_TAG}
   UPDATE_COMMAND ""
   SOURCE_DIR ${proj}
+  SOURCE_SUBDIR aten
   BINARY_DIR ${proj}-build
   CMAKE_ARGS
     --no-warn-unused-cli
@@ -34,7 +35,7 @@
     -DBUILD_TESTING:BOOL=OFF
     -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
     -DCMAKE_CONFIGURATION_TYPES:STRING=${CMAKE_CONFIGURATION_TYPES}
-    -DNO_CUDA=true
+    -DNO_CUDA:BOOL=TRUE
     -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
 )


Ported libpng to iOS

Ported libpng to iOS

--- ThirdPartyLibraries.cmake
+++ ThirdPartyLibraries.cmake
@@ -1914,7 +1914,12 @@
       cd <SOURCE_DIR> &&
       ./autogen.sh &&
       cd <BINARY_DIR> &&
-      <SOURCE_DIR>/configure --prefix=${LIBPNG_PREFIX} ${HOST})
+      <SOURCE_DIR>/configure --prefix=${LIBPNG_PREFIX} ${HOST}
+          CC=${CMAKE_C_COMPILER}
+          CXX=${CMAKE_CXX_COMPILER} CFLAGS=${CMAKE_C_FLAGS_WITH_ARCHS}
+          CXXFLAGS=${CMAKE_CXX_FLAGS_WITH_ARCHS}
+          LDFLAGS=${CMAKE_SHARED_LINKER_FLAGS}
+          ${CONFIGURE_LIB_TYPE})
 add_dependencies(${LIBPNG_TARGET} ${GNUAUTOMAKE_TARGET})

 ################################################################################


Squashed '3rdparty/github/cmake-utils/' changes from da88dd072..2c004ca88

2c004ca88 cmake/MyPackageCheckCommonSizes.cmake: Add float, double and long double

git-subtree-dir: 3rdparty/github/cmake-utils
git-subtree-split: 2c004ca881ba3eba4699af95f257789ddae3ed1d

--- cmake/MyPackageCheckCommonSizes.cmake
+++ cmake/MyPackageCheckCommonSizes.cmake
@@ -4,6 +4,9 @@
   CHECK_TYPE_SIZE("int" SIZEOF_INT)
   CHECK_TYPE_SIZE("long" SIZEOF_LONG)
   CHECK_TYPE_SIZE("long long" SIZEOF_LONG_LONG)
+  CHECK_TYPE_SIZE("float" SIZEOF_FLOAT)
+  CHECK_TYPE_SIZE("double" SIZEOF_DOUBLE)
+  CHECK_TYPE_SIZE("long double" SIZEOF_LONG_DOUBLE)
   CHECK_TYPE_SIZE("unsigned short" SIZEOF_UNSIGNED_SHORT)
   CHECK_TYPE_SIZE("unsigned int" SIZEOF_UNSIGNED_INT)
   CHECK_TYPE_SIZE("unsigned long" SIZEOF_UNSIGNED_LONG)


fix boost zlib detection configure check

We were missing the include dirs in #5318

closes #5351

--- cmake/configure/configure_boost.cmake
+++ cmake/configure/configure_boost.cmake
@@ -97,6 +97,8 @@
       RESET_CMAKE_REQUIRED()
       PUSH_CMAKE_REQUIRED("${DEAL_II_CXX_VERSION_FLAG}")
       SET(CMAKE_REQUIRED_LIBRARIES "${BOOST_LIBRARIES}")
+      LIST(APPEND CMAKE_REQUIRED_INCLUDES ${BOOST_INCLUDE_DIRS})
+
       CHECK_CXX_SOURCE_COMPILES(
         "
         #include <string>


Cmake: add compiler option in a more idiomatic way

git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@183995 91177308-0d34-0410-b5e6-96231b3b80d8

--- cmake/modules/HandleLLVMOptions.cmake
+++ cmake/modules/HandleLLVMOptions.cmake
@@ -268,8 +268,6 @@
 add_llvm_definitions( -D__STDC_LIMIT_MACROS )

 # clang doesn't print colored diagnostics when invoked from Ninja
-if (UNIX AND
-    CMAKE_CXX_COMPILER_ID STREQUAL "Clang" AND
-    CMAKE_GENERATOR STREQUAL "Ninja")
-  append("-fcolor-diagnostics" CMAKE_C_FLAGS CMAKE_CXX_FLAGS)
-endif()
+if (UNIX AND CMAKE_GENERATOR STREQUAL "Ninja")
+  add_flag_if_supported("-fcolor-diagnostics")
+endif()


Revert "Add include directories for externals to ROOT_INCLUDE_DIRS"

This reverts commit e5299b1f790f1450c1545659f4cc869de7ebef70.
We still have to copy headers to the binary directory, so this is
not necessary.

--- cmake/modules/RootConfiguration.cmake
+++ cmake/modules/RootConfiguration.cmake
@@ -634,8 +634,7 @@
 #---To be used from the binary tree--------------------------------------------------------------------------
 set(ROOT_INCLUDE_DIR_SETUP "
 # ROOT configured for use from the build tree - absolute paths are used.
-set(ROOT_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/include
-    ${CMAKE_BINARY_DIR}/externals/${CMAKE_INSTALL_PREFIX}/include)
+set(ROOT_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/include)
 ")
 set(ROOT_LIBRARY_DIR_SETUP "
 # ROOT configured for use from the build tree - absolute paths are used.


[Build System: CMake] Add CMake module paths before importing in StandaloneOverlay.cmake.

--- cmake/modules/StandaloneOverlay.cmake
+++ cmake/modules/StandaloneOverlay.cmake
@@ -7,6 +7,12 @@
   set(SWIFT_MASTER_LOADED TRUE)
   return()
 endif()
+
+
+list(APPEND CMAKE_MODULE_PATH
+  "${SWIFT_SOURCE_ROOT}/llvm/cmake/modules"
+  "${PROJECT_SOURCE_DIR}/../../../../cmake/modules"
+  "${PROJECT_SOURCE_DIR}/../../../cmake/modules")

 # -----------------------------------------------------------------------------
@@ -69,11 +75,6 @@
 set(CMAKE_INSTALL_PREFIX
   "${SWIFT_DEST_ROOT}${TOOLCHAIN_DIR}/usr")

-list(APPEND CMAKE_MODULE_PATH
-  "${SWIFT_SOURCE_ROOT}/llvm/cmake/modules"
-  "${PROJECT_SOURCE_DIR}/../../../../cmake/modules"
-  "${PROJECT_SOURCE_DIR}/../../../cmake/modules")
-

 set(SWIFT_APPLE_PLATFORMS
   OSX IOS IOS_SIMULATOR TVOS TVOS_SIMULATOR WATCHOS WATCHOS_SIMULATOR)


CMake: Weaken a platform introspection guard

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

--- deal.II/cmake/checks/check_01_cxx_features.cmake
+++ deal.II/cmake/checks/check_01_cxx_features.cmake
@@ -113,7 +113,7 @@
   #       configure_threads.cmake which will determine and setup threads
   #       has to be called later...
   #
-  IF(DEAL_II_ALLOW_PLATFORM_INTROSPECTION)
+  IF(NOT CMAKE_CROSSOMPILING) # Todo: Is it better to use DEAL_II_ALLOW_PLATFORM_INTROSPECTION here?
     PUSH_TEST_FLAG("-pthread")
     CHECK_CXX_SOURCE_RUNS(
       "


Disable another plugin we don't need

Disable another plugin we don't need

--- projects/paraview.cmake
+++ projects/paraview.cmake
@@ -31,6 +31,7 @@
     -DPARAVIEW_BUILD_PLUGIN_UncertaintyRendering:BOOL=FALSE
     -DPARAVIEW_BUILD_PLUGIN_VRPlugin:BOOL=FALSE
     -DPARAVIEW_BUILD_PLUGIN_VaporPlugin:BOOL=FALSE
+    -DPARAVIEW_BUILD_PLUGIN_RGBZView:BOOL=OFF
     -DPQWIDGETS_DISABLE_QTWEBKIT:BOOL=ON
     -DModule_vtkGUISupportQtWebkit:BOOL=OFF


Some variables are mark_as_advanced

Some variables are mark_as_advanced

mark_as_advanced STIR_TAG and STIR_URL, Gadgetron_TAG/URL and
ISMRMRD_TAG/URL

--- version_config.cmake
+++ version_config.cmake
@@ -101,4 +101,5 @@

 endif()
 option(GIT_TAG_SIRF "git tag for SIRF" ${SIRF_TAG})
+mark_as_advanced(STIR_URL STIR_TAG Gadgetron_URL Gadgetron_TAG ISMRMRD_URL ISMRMRD_TAG)


Fix finding SQLCipher

Fix finding SQLCipher

At least I hope so :-)

--- cmake/FindSQLCipher.cmake
+++ cmake/FindSQLCipher.cmake
@@ -43,8 +43,7 @@
   set(SQLCIPHER_DEFINITIONS ${PC_SQLCIPHER_CFLAGS_OTHER})
 endif( NOT WIN32 )

-find_path(SQLCIPHER_INCLUDE_DIRS NAMES sqlite3.h
-  PATH_SUFFIXES sqlcipher
+find_path(SQLCIPHER_INCLUDE_DIRS NAMES sqlcipher/sqlite3.h
   PATHS
   ${PC_SQLCIPHER_INCLUDEDIR}
   ${PC_SQLCIPHER_INCLUDE_DIRS}


Generate stripped PDB in Release mode.

Generate stripped PDB in Release mode.

--- cmake/HalleyProject.cmake
+++ cmake/HalleyProject.cmake
@@ -14,9 +14,9 @@
 # Compiler-specific flags
 if (MSVC)
 	set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP /fp:fast")
-	set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /GL /sdl /Oi /Ot /Oy /Ob2 /DEBUG:FULL")
+	set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /GL /sdl /Oi /Ot /Oy /Ob2 /DEBUG:FULL /Zi")
 	set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELWITHDEBINFO} /sdl /Oi /Ot /Ob2")
-	set(CMAKE_EXE_LINKER_FLAGS_RELEASE "${CMAKE_EXE_LINKER_FLAGS_RELEASE} /LTCG")
+	set(CMAKE_EXE_LINKER_FLAGS_RELEASE "${CMAKE_EXE_LINKER_FLAGS_RELEASE} /LTCG /DEBUG")
 	set(CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} /DEBUG:FASTLINK")
 	set(CMAKE_STATIC_LINKER_FLAGS_RELEASE "${CMAKE_STATIC_LINKER_FLAGS_RELEASE} /LTCG")
 	set(CMAKE_SHARED_LINKER_FLAGS_RELEASE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE} /LTCG")
@@ -167,30 +167,31 @@
 	link_directories(${HALLEY_PROJECT_LIB_DIRS})

 	if (HOTRELOAD)
+		set(HALLEY_RUNNER_PATH ${HALLEY_PATH}\\bin\\halley-runner.exe)
+		set(HALLEY_RUNNER_DEBUG_PATH ${HALLEY_PATH}\\bin\\halley-runner_d.exe)
+		configure_file(${HALLEY_PATH}/cmake/halley_game.vcxproj.user.in ${CMAKE_CURRENT_BINARY_DIR}/${name}.vcxproj.user @ONLY)
+	endif()
+
+	if (HOTRELOAD)
 		add_library(${name} SHARED ${proj_sources} ${proj_headers})
 		add_definitions(-DHALLEY_SHARED_LIBRARY)
 	else()
 		add_executable(${name} WIN32 ${proj_sources} ${proj_headers})
 		add_definitions(-DHALLEY_EXECUTABLE)
 	endif()
-
+
+	if (MSVC)
+		add_definitions(-D_WIN32_WINNT=0x0501 -DWINVER=0x0501)
+		add_precompiled_header(${name} prec.h FORCEINCLUDE SOURCE_CXX prec.cpp)
+		set_target_properties(${name} PROPERTIES LINK_FLAGS_RELEASE "/PDBSTRIPPED:\"${targetDir}/${name}_stripped.pdb\"")
+	endif()
+
+	if (EMSCRIPTEN)
+		set_target_properties(${name} PROPERTIES SUFFIX ".bc")
+	endif()
+
 	target_link_libraries(${name} ${HALLEY_PROJECT_LIBS})
 	set_target_properties(${name} PROPERTIES DEBUG_POSTFIX ${CMAKE_DEBUG_POSTFIX})
-
-	if (HOTRELOAD)
-		set(HALLEY_RUNNER_PATH ${HALLEY_PATH}\\bin\\halley-runner.exe)
-		set(HALLEY_RUNNER_DEBUG_PATH ${HALLEY_PATH}\\bin\\halley-runner_d.exe)
-		configure_file(${HALLEY_PATH}/cmake/halley_game.vcxproj.user.in ${CMAKE_CURRENT_BINARY_DIR}/${name}.vcxproj.user @ONLY)
-	endif()
-
-	if(MSVC)
-		add_precompiled_header(${name} prec.h FORCEINCLUDE SOURCE_CXX prec.cpp)
-		add_definitions(-D_WIN32_WINNT=0x0501 -DWINVER=0x0501)
-	endif()
-
-	if (EMSCRIPTEN)
-		set_target_properties(${name} PROPERTIES SUFFIX ".bc")
-	endif()
 endfunction(halleyProject)

 function(halleyProjectCodegen name sources headers genDefinitions targetDir)


Enabled /bigobj flag on visual studio

Enabled /bigobj flag on visual studio

--- cmake/HalleyProject.cmake
+++ cmake/HalleyProject.cmake
@@ -47,7 +47,7 @@
 # Compiler-specific flags
 if (MSVC)
 	if (${CMAKE_CXX_COMPILER_ID} STREQUAL MSVC)
-		set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP /fp:fast /WX /W3 -D_ENABLE_EXTENDED_ALIGNED_STORAGE /wd4275 /wd4251")
+		set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP /fp:fast /WX /W3 -D_ENABLE_EXTENDED_ALIGNED_STORAGE /wd4275 /wd4251 /bigobj")
 	else()
 		set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /fp:fast /WX -D_ENABLE_EXTENDED_ALIGNED_STORAGE -Wno-unused-private-field -Wno-unused-variable -Wno-deprecated-declarations -Wno-microsoft-cast -Wno-switch -Wno-missing-declarations -Wno-string-plus-int -Wno-unused-function -Wno-assume")
 	endif()


[cmake] Remove unused DLL_NAMES var

[cmake] Remove unused DLL_NAMES var

--- cmake/OpenSimMacros.cmake
+++ cmake/OpenSimMacros.cmake
@@ -354,7 +354,6 @@
                                 "${DEP_INSTALL_DIR}.")
         endif()
         set(DEST_DIR "${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}")
-        set(DLL_NAMES "")
         foreach(DLL IN LISTS DLLS)
             get_filename_component(DLL_NAME ${DLL} NAME)
             list(APPEND DLLS_DEST "${DEST_DIR}/${DLL_NAME}")


Remove underscore prefix from local cmake variables

--- cmake/SetupCoverage.cmake
+++ cmake/SetupCoverage.cmake
@@ -56,12 +56,12 @@
         CACHE STRING "List of supported configuration types" FORCE)
 else()
     # Modify CMAKE_BUILD_TYPE enum values for cmake-gui
-    get_property(_build_type_strings CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS)
-    list(LENGTH _build_type_strings _build_type_strings_length)
-    if(NOT _build_type_strings_length EQUAL 0)
-        list(APPEND _build_type_strings Coverage)
-        list(REMOVE_DUPLICATES _build_type_strings)
-        set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS ${_build_type_strings})
+    get_property(build_type_strings CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS)
+    list(LENGTH build_type_strings build_type_strings_length)
+    if(NOT build_type_strings_length EQUAL 0)
+        list(APPEND build_type_strings Coverage)
+        list(REMOVE_DUPLICATES build_type_strings)
+        set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS ${build_type_strings})
     endif()
 endif()

@@ -76,32 +76,32 @@
         message(FATAL_ERROR "lcov not found!")
     endif()

-    set(_options BRANCHES)
-    set(_one_value_args "")
-    set(_multi_value_args FILTERS ARGS)
-    cmake_parse_arguments(_options "${_options}" "${_one_value_args}" "${_multi_value_args}" ${ARGN})
-    if(_options_BRANCHES)
-        set(_branch_coverage --rc lcov_branch_coverage=1)
+    set(options BRANCHES)
+    set(one_value_args "")
+    set(multi_value_args FILTERS ARGS)
+    cmake_parse_arguments(options "${options}" "${one_value_args}" "${multi_value_args}" ${ARGN})
+    if(options_BRANCHES)
+        set(branch_coverage --rc lcov_branch_coverage=1)
     endif()
-    if(NOT _options_FILTERS)
-        set(_options_FILTERS '*')
+    if(NOT options_FILTERS)
+        set(options_FILTERS '*')
     endif()

-    set(_coverage_args)
-    list(APPEND _coverage_args COMMAND ${LCOV_EXECUTABLE}
+    set(coverage_args)
+    list(APPEND coverage_args COMMAND ${LCOV_EXECUTABLE}
          -q --zerocounters --directory .)
-    list(APPEND _coverage_args COMMAND ${_test_runner}
-         ${_options_ARGS})
-    list(APPEND _coverage_args COMMAND ${LCOV_EXECUTABLE}
-         -q --capture --directory . --output-file ${_output_name}.all.info ${_branch_coverage})
-    list(APPEND _coverage_args COMMAND ${LCOV_EXECUTABLE}
-         -q --extract ${_output_name}.all.info ${_options_FILTERS} --output-file ${_output_name}.info  ${_branch_coverage})
-    list(APPEND _coverage_args COMMAND ${GENHTML_EXECUTABLE}
-         -q --output-directory ${_output_name} ${_output_name}.info  ${_branch_coverage})
-    list(APPEND _coverage_args COMMAND ${CMAKE_COMMAND}
+    list(APPEND coverage_args COMMAND ${_test_runner}
+         ${options_ARGS})
+    list(APPEND coverage_args COMMAND ${LCOV_EXECUTABLE}
+         -q --capture --directory . --output-file ${_output_name}.all.info ${branch_coverage})
+    list(APPEND coverage_args COMMAND ${LCOV_EXECUTABLE}
+         -q --extract ${_output_name}.all.info ${options_FILTERS} --output-file ${_output_name}.info  ${branch_coverage})
+    list(APPEND coverage_args COMMAND ${GENHTML_EXECUTABLE}
+         -q --output-directory ${_output_name} ${_output_name}.info  ${branch_coverage})
+    list(APPEND coverage_args COMMAND ${CMAKE_COMMAND}
          -E remove ${_output_name}.all.info)

-    add_custom_target(${_target_name} ${_coverage_args}
+    add_custom_target(${_target_name} ${coverage_args}
                       WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
                       COMMENT "Gathering and processing code coverage counters to generate HTML report")
     add_custom_command(TARGET ${_target_name} POST_BUILD
@@ -117,43 +117,43 @@
         message(FATAL_ERROR "gcovr not found!")
     endif()

-    set(_options XML)
-    set(_one_value_args "")
-    set(_multi_value_args FILTERS EXCLUDE ARGS)
-    cmake_parse_arguments(_options "${_options}" "${_one_value_args}" "${_multi_value_args}" ${ARGN})
-    if(_options_FILTERS)
-        set(_tmp_list "")
-        foreach(_loop ${_options_FILTERS})
-            list(APPEND _tmp_list --filter=${_loop})
+    set(options XML)
+    set(one_value_args "")
+    set(multi_value_args FILTERS EXCLUDE ARGS)
+    cmake_parse_arguments(options "${options}" "${one_value_args}" "${multi_value_args}" ${ARGN})
+    if(options_FILTERS)
+        set(tmp_list "")
+        foreach(_loop ${options_FILTERS})
+            list(APPEND tmp_list --filter=${_loop})
         endforeach()
-        set(_options_FILTERS ${_tmp_list})
+        set(options_FILTERS ${tmp_list})
     endif()
-    if(_options_EXCLUDE)
-        set(_tmp_list "")
-        foreach(_loop ${_options_EXCLUDE})
-            list(APPEND _tmp_list --exclude=${_loop})
+    if(options_EXCLUDE)
+        set(tmp_list "")
+        foreach(_loop ${options_EXCLUDE})
+            list(APPEND tmp_list --exclude=${_loop})
         endforeach()
-        set(_options_EXCLUDE ${_tmp_list})
+        set(options_EXCLUDE ${tmp_list})
     endif()
-    if(_options_XML)
-        set(_output_mode --xml)
-        set(_output_file ${_output_name}.xml)
+    if(options_XML)
+        set(output_mode --xml)
+        set(output_file ${_output_name}.xml)
     else()
-        set(_output_mode --html --html-details)
-        set(_output_file ${_output_name}.html)
+        set(output_mode --html --html-details)
+        set(output_file ${_output_name}.html)
     endif()

-    set(_coverage_args)
-    list(APPEND _coverage_args COMMAND ${_test_runner}
-         ${_options_ARGS})
-    list(APPEND _coverage_args COMMAND ${GCOVR_EXECUTABLE}
-         --delete ${_output_mode} --root=${CMAKE_SOURCE_DIR}
-         ${_options_FILTERS} ${_options_EXCLUDE} --output=${_output_file})
+    set(coverage_args)
+    list(APPEND coverage_args COMMAND ${_test_runner}
+         ${options_ARGS})
+    list(APPEND coverage_args COMMAND ${GCOVR_EXECUTABLE}
+         --delete ${output_mode} --root=${CMAKE_SOURCE_DIR}
+         ${options_FILTERS} ${options_EXCLUDE} --output=${output_file})

-    add_custom_target(${_target_name} ${_coverage_args}
+    add_custom_target(${_target_name} ${coverage_args}
                       WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
                       COMMENT "Running gcovr to produce HTML report")
     add_custom_command(TARGET ${_target_name} POST_BUILD
                        COMMAND ;
-                       COMMENT "Open ./${_output_file} to see coverage report")
+                       COMMENT "Open ./${output_file} to see coverage report")
 endfunction()


hmm, it skipped building and testing. Seems that RETURN_VALUE is not consistent but depends on the step

--- VCTest.cmake
+++ VCTest.cmake
@@ -17,12 +17,12 @@
       CTEST_UPDATE (SOURCE "${CTEST_SOURCE_DIRECTORY}" RETURN_VALUE res)
       if(res)
          CTEST_CONFIGURE (BUILD "${CTEST_BINARY_DIRECTORY}" RETURN_VALUE res)
-         if(res)
+         if(res EQUAL 0)
             CTEST_BUILD (BUILD "${CTEST_BINARY_DIRECTORY}" RETURN_VALUE res)
-            if(res)
+            if(res EQUAL 0)
                CTEST_TEST (BUILD "${CTEST_BINARY_DIRECTORY}" RETURN_VALUE res)
-            endif(res)
-         endif(res)
+            endif(res EQUAL 0)
+         endif(res EQUAL 0)
          CTEST_SUBMIT (RETURN_VALUE res)
       endif(res)
       ctest_sleep(${START_TIME} 1200 ${CTEST_ELAPSED_TIME})


Update find-libusb-windows.cmake

Update find-libusb-windows.cmake

--- recipes/librealsense/find-libusb-windows.cmake
+++ recipes/librealsense/find-libusb-windows.cmake
@@ -1,3 +1,5 @@
+diff --git a/CMake/libusb_config.cmake b/CMake/libusb_config.cmake
+index ca221ca66d..cf48bc547f 100644
 --- a/CMake/libusb_config.cmake
 +++ b/CMake/libusb_config.cmake
 @@ -1,5 +1,5 @@


BUG: MANTIS-1180: Add OTBQtAdapters dependency to OTBMonteverdi.

--- Modules/Visualization/Monteverdi/otb-module.cmake
+++ Modules/Visualization/Monteverdi/otb-module.cmake
@@ -8,6 +8,7 @@
     OTBMonteverdiCore
     OTBMonteverdiGUI
     OTBQt4
+    OTBQtAdapters

   OPTIONAL_DEPENDS


ignore no inline in gcc

ignore no inline in gcc

--- utils.cmake
+++ utils.cmake
@@ -74,6 +74,7 @@
 			add_definitions(-Wno-long-long)
 			add_definitions(-Wno-shadow)
 			add_definitions(-Wno-strict-aliasing)
+			add_definitions(-Wno-error=inline)
 		else()
 			add_definitions(-Wstrict-aliasing=2)
 		endif()


Split off 7.4.x

Split off 7.4.x

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

--- version.cmake
+++ version.cmake
@@ -3,8 +3,8 @@
 ###
 set ( HPCC_PROJECT "community" )
 set ( HPCC_MAJOR 7 )
-set ( HPCC_MINOR 0 )
+set ( HPCC_MINOR 5 )
 set ( HPCC_POINT 0 )
-set ( HPCC_MATURITY "release" )
-set ( HPCC_SEQUENCE 1 )
+set ( HPCC_MATURITY "trunk" )
+set ( HPCC_SEQUENCE 0 )
 ###


Split off 8.6.20

Split off 8.6.20

Signed-off-by: Gavin Halliday <2edfa8aca9fb78974188e5b35be8b52d4e4967ae@lexisnexis.com>

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


Split off 7.6.44

Split off 7.6.44

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 6 )
-set ( HPCC_POINT 43 )
+set ( HPCC_POINT 45 )
 set ( HPCC_MATURITY "closedown" )
 set ( HPCC_SEQUENCE 0 )
 ###


CMake: Update version number

CMake: Update version number

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


Updated UrhoCommon.cmake to link against CoreFoundation & SystemConfiguration, which is needed by GetLoginName().

--- CMake/Modules/UrhoCommon.cmake
+++ CMake/Modules/UrhoCommon.cmake
@@ -857,7 +857,7 @@
             if (IOS OR TVOS)
                 list (APPEND LIBS "-framework AudioToolbox" "-framework AVFoundation" "-framework CoreAudio" "-framework CoreGraphics" "-framework CoreMotion" "-framework Foundation" "-framework GameController" "-framework OpenGLES" "-framework QuartzCore" "-framework UIKit")
             else ()
-                list (APPEND LIBS "-framework AudioToolbox" "-framework Carbon" "-framework Cocoa" "-framework CoreAudio" "-framework CoreServices" "-framework CoreVideo" "-framework ForceFeedback" "-framework IOKit" "-framework OpenGL")
+                list (APPEND LIBS "-framework AudioToolbox" "-framework Carbon" "-framework Cocoa" "-framework CoreFoundation" "-framework SystemConfiguration" "-framework CoreAudio" "-framework CoreServices" "-framework CoreVideo" "-framework ForceFeedback" "-framework IOKit" "-framework OpenGL")
             endif ()
         endif ()


ENH: Rename to not conflict

ENH: Rename to not conflict

--- CMake/vtkDependentOption.cmake
+++ CMake/vtkDependentOption.cmake
@@ -10,7 +10,7 @@
 # retains its old value.
 #
 MACRO(VTK_DEPENDENT_OPTION option doc default depends force)
-  IF(${option}_FORCE MATCHES "^${option}_FORCE")
+  IF(${option}_ISSET MATCHES "^${option}_ISSET")
     SET(${option}_AVAILABLE 1)
     FOREACH(d ${depends})
       IF(NOT ${d})
@@ -24,7 +24,7 @@
       SET(${option} "${${option}}" CACHE INTERNAL "${doc}")
       SET(${option} ${force})
     ENDIF(${option}_AVAILABLE)
-  ELSE(${option}_FORCE MATCHES "^${option}_FORCE")
-    SET(${option} "${${option}_FORCE}")
-  ENDIF(${option}_FORCE MATCHES "^${option}_FORCE")
+  ELSE(${option}_ISSET MATCHES "^${option}_ISSET")
+    SET(${option} "${${option}_ISSET}")
+  ENDIF(${option}_ISSET MATCHES "^${option}_ISSET")
 ENDMACRO(VTK_DEPENDENT_OPTION)


COMP: revert python from all configuration because of Qt Version conflict

--- CMake/BuildConfigurations/All.cmake
+++ CMake/BuildConfigurations/All.cmake
@@ -8,18 +8,10 @@
   )
 endif()

-set(_python_excludes )
-
-if(NOT (CMAKE_SIZEOF_VOID_P EQUAL 8) )
-  set(_python_excludes
-    Python
-    Numpy
-   )
-endif()
-
 set(_package_excludes
   ${_apple_package_excludes}
-  ${_python_excludes}
+  Python
+  Numpy
   OpenCL
   SYSTEM_Boost
   Boost_LIBRARIES


Revert precompiled headers part of recent MinGW patch (r9640). This broke the build in MSVC 2005 which complained of inconsistent build settings between precompiled headers and source files on the second and future builds. Really this patch should not have been touching MSVC if it was aimed at MinGW since clearly it wasn't tested there.

--- CMake/Utils/PrecompiledHeader.cmake
+++ CMake/Utils/PrecompiledHeader.cmake
@@ -15,22 +15,12 @@

 macro(use_precompiled_header TARGET HEADER_FILE SRC_FILE)
   get_filename_component(HEADER ${HEADER_FILE} NAME)
-  get_target_property(SOURCE_FILES ${TARGET} SOURCES)

   if (MSVC)
-    get_filename_component(BASENAME ${HEADER_FILE} NAME_WE)
-	set(PREC_HEADER "${CMAKE_CURRENT_BINARY_DIR}/${BASENAME}.pch")
-	foreach(SOURCE_FILE ${SOURCE_FILES})
-	  get_filename_component(FEXT ${SOURCE_FILE} EXT)
-	  if (FEXT STREQUAL ".cpp")
-	    set_source_files_properties(${SOURCE_FILE}
-	      PROPERTIES COMPILE_FLAGS "/Yu\"${HEADER}\" /Fp\"${PREC_HEADER}\""
-	      OBJECT_DEPENDS "${PREC_HEADER}")
-	  endif ()
-	endforeach()
+	add_definitions(/Yu"${HEADER}")
     set_source_files_properties(${SRC_FILE}
-      PROPERTIES COMPILE_FLAGS "/Yc\"${HEADER}\" /Fp\"${PREC_HEADER}\""
-	  OBJECT_OUTPUTS "${PREC_HEADER}" OBJECT_DEPENDS "")
+      PPROPERTIES COMPILE_FLAGS /Yc"${HEADER}"
+	)

   elseif (CMAKE_COMPILER_IS_GNUCXX)
     # disabled because it seems to increase compile time


Fix #17 add realpath_error_injection to CTestCustom.cmake

--- backup/CTestCustom.cmake
+++ backup/CTestCustom.cmake
@@ -33,6 +33,7 @@
  null_dest_dir_6317
  nondir_dest_dir_6317
  readdirfails_dest_dir
+ realpath_error_injection
  rename_injection
  range_locks
  read_and_seek


added option for changing valua of char at configure time with gcc

--- cmake_compiler_settings/cmake/gcc_flags.cmake
+++ cmake_compiler_settings/cmake/gcc_flags.cmake
@@ -170,3 +170,11 @@
 	# enable DEP
 	set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wl,nxcompat")
 endif()
+
+option(CHANGE_CHAR_SIGN "Change sign of char to test code for portability"  OFF)
+if(CHANGE_CHAR_SIGN)
+	set(sign_char_values "-funsigned-char,-fsigned-char" CACHE STRING "List of possible values for the sign of char cache variable")
+	set(sign_char "-fsigned-char" CACHE STRING "Value chosen by the user at configure time")
+	add_compile_options(${sign_char})
+endif()
+


install examples

install examples

--- config/cmake/modules/MfemCmakeUtilities.cmake
+++ config/cmake/modules/MfemCmakeUtilities.cmake
@@ -100,6 +100,8 @@

     string(REPLACE ".cpp" "" EXE_NAME "${EXE_PREFIX}${SRC_FILENAME}")
     mfem_add_executable(${EXE_NAME} ${SRC_FILE})
+    install(TARGETS ${EXE_NAME}
+            DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
     add_dependencies(${MFEM_ALL_EXAMPLES_TARGET_NAME} ${EXE_NAME})
     if (EXE_NEEDED_BY)
       add_dependencies(${EXE_NEEDED_BY} ${EXE_NAME})


FIX: Added BUILD_EXAMPLES to the exclude section

--- UseVTK.cmake
+++ UseVTK.cmake
@@ -8,6 +8,7 @@
       EXCLUDE
         BUILD_SHARED_LIBS
         BUILD_TESTING
+        BUILD_EXAMPLES
         LIBRARY_OUTPUT_PATH
         EXECUTABLE_OUTPUT_PATH
         MAKECOMMAND
@@ -24,6 +25,7 @@
       EXCLUDE
         BUILD_SHARED_LIBS
         BUILD_TESTING
+        BUILD_EXAMPLES
         LIBRARY_OUTPUT_PATH
         EXECUTABLE_OUTPUT_PATH
         MAKECOMMAND


vigra.cmake: Updated git tag.

vigra.cmake: Updated git tag.

--- vigra.cmake
+++ vigra.cmake
@@ -21,7 +21,7 @@
 include (numpy)

 external_git_repo (vigra
-    flyem-1.9.0.a
+    flyem-1.9.0.b
     http://github.com/janelia-flyem/vigra)

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


Update FW, bugfix for config_h2d handling after initial setup

--- cmake/Depthai/DepthaiDeviceSideConfig.cmake
+++ cmake/Depthai/DepthaiDeviceSideConfig.cmake
@@ -2,7 +2,7 @@
 set(DEPTHAI_DEVICE_SIDE_MATURITY "snapshot")

 # "full commit hash of device side binary"
-set(DEPTHAI_DEVICE_SIDE_COMMIT "d8813bc1b6cbfbcca742c3e718d3f592a63efcc3")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "642a7b7db68a6ec7c94797bea942f8f0df906397")

 # "version if applicable"
 set(DEPTHAI_DEVICE_SIDE_VERSION "")


Update FW with memory optimizations

Update FW with memory optimizations

--- cmake/Depthai/DepthaiDeviceSideConfig.cmake
+++ cmake/Depthai/DepthaiDeviceSideConfig.cmake
@@ -2,7 +2,7 @@
 set(DEPTHAI_DEVICE_SIDE_MATURITY "snapshot")

 # "full commit hash of device side binary"
-set(DEPTHAI_DEVICE_SIDE_COMMIT "d66b4da7255c5b436b48987d176b2552c3bd97fa")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "16efec0dcbe538570c7dd4e4f4fab40ed0549a6c")

 # "version if applicable"
 set(DEPTHAI_DEVICE_SIDE_VERSION "")


Disable support for Vc when using GCC and C++17

GCC 7.1.0 does not have complete support for C++17. In particular, Vc
uses std::for_each_n(), which is not yet available in GCC. Therefore,
we must turn off support for Vc when compiling in C++17 mode to avoid
breakage. This problem is not triggered in Clang because it sets
__cplusplus to its C++14 value even when option -std=c++1z is used.

--- cmake/modules/SearchInstalledSoftware.cmake
+++ cmake/modules/SearchInstalledSoftware.cmake
@@ -1248,6 +1248,11 @@
       set(vc OFF CACHE BOOL "" FORCE)
       set(builtin_vc OFF CACHE BOOL "" FORCE)
     endif()
+    if(cxx17 OR CMAKE_CXX_STANDARD EQUAL 17)
+      message(STATUS "Vc uses std::for_each_n(), which is not available in GCC; switching OFF 'vc' option")
+      set(vc OFF CACHE BOOL "" FORCE)
+      set(builtin_vc OFF CACHE BOOL "" FORCE)
+    endif()
   elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
     if ( APPLE AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 4)
       message(STATUS "Vc requires Apple Clang version >= 4.0; switching OFF 'vc' option")


Use the latest version of Davix. This solves a compilation error on 32bit

--- cmake/modules/SearchInstalledSoftware.cmake
+++ cmake/modules/SearchInstalledSoftware.cmake
@@ -759,7 +759,7 @@
     if(NOT davix)
       set(davix ON CACHE BOOL "" FORCE)
     endif()
-    set(DAVIX_VERSION 0.3.4)
+    set(DAVIX_VERSION 0.3.6)
     message(STATUS "Downloading and building Davix version ${DAVIX_VERSION}")
     string(REPLACE "-Wall " "" __cxxflags "${CMAKE_CXX_FLAGS}")                      # Otherwise it produces tones of warnings
     string(REPLACE "-W " "" __cxxflags "${__cxxflags} -Wno-unused-const-variable")


hunter_create_args_file: Variable with name '--*' is not allowed

--- cmake/modules/hunter_create_args_file.cmake
+++ cmake/modules/hunter_create_args_file.cmake
@@ -31,9 +31,22 @@
   file(WRITE "${filename_nolf}" "") # create empty file if no option
   set(var_name "")
   foreach(entry ${args})
-    string(FIND "${entry}" "=" update_var)
-    if(update_var EQUAL -1)
+    set(appending_mode FALSE)
+
+    string(FIND "${entry}" "=" equal_symbol_index)
+    if(equal_symbol_index EQUAL -1)
       # There is no '=' symbol - appending mode
+      set(appending_mode TRUE)
+    endif()
+
+    string(REGEX MATCH "^--.*" starts_with_double_dash "${entry}")
+    if(NOT "${starts_with_double_dash}" STREQUAL "")
+      # Assumed that variable name doesn't start with '--' and we are appending.
+      # Needed to pass options like `--foo=a,b,c,d`
+      set(appending_mode TRUE)
+    endif()
+
+    if(appending_mode)
       if(NOT var_name)
         hunter_user_error(
             "${bad_message} (expected '=' symbol): ${args}"


In case user specified an bad AWSSDK_ROOT_DIR, we should locate the correct one automatically if any

--- cmake/AWSSDKConfig.cmake
+++ cmake/AWSSDKConfig.cmake
@@ -65,7 +65,9 @@
 # currently AWSSDK_ROOT_DIR is either empty or user specified
 if (AWSSDK_ROOT_DIR)
     find_file(AWSSDK_CORE_HEADER_FILE Aws.h
-            "${AWSSDK_ROOT_DIR}/${AWSSDK_INSTALL_INCLUDEDIR}/aws/core")
+            "${AWSSDK_ROOT_DIR}/${AWSSDK_INSTALL_INCLUDEDIR}/aws/core"
+            "${AWSSDK_DEFAULT_ROOT_DIR}/${AWSSDK_INSTALL_INCLUDEDIR}/aws/core"
+            )
 else()
     find_file(AWSSDK_CORE_HEADER_FILE Aws.h
         "/usr/${AWSSDK_INSTALL_INCLUDEDIR}/aws/core"


Fix build with >=freetype-2.5.1 wrt #1007

--- cmake/FindFreetype.cmake
+++ cmake/FindFreetype.cmake
@@ -3,8 +3,12 @@
 ################################################################################
 include(FindPackageHandleStandardArgs)

-find_path(FREETYPE_H_PATH_ft2build NAMES ft2build.h)
+find_path(FREETYPE_H_PATH_ft2build NAMES ft2build.h PATH_SUFFIXES include/freetype2 include)
 find_path(FREETYPE_H_PATH_ftconfig NAMES freetype/config/ftconfig.h PATH_SUFFIXES freetype2)
+if (NOT FREETYPE_H_PATH_ftconfig)
+    find_path(FREETYPE_H_PATH_ftconfig NAMES config/ftconfig.h PATH_SUFFIXES include/freetype2 include)
+endif()
+
 find_library(FREETYPE_LIB NAMES freetype2 freetype libfreetype PATH_SUFFIXES dynamic)
 find_library(FREETYPE_LIB_DBG NAMES freetype_d libfreetype_d PATH_SUFFIXES dynamic)
 mark_as_advanced(FREETYPE_H_PATH_ft2build FREETYPE_H_PATH_ftconfig FREETYPE_LIB FREETYPE_LIB_DBG)


Fix CMake Jemalloc bug where lists incorrectly interpreted as strings not lists

Signed-off-by: Dan Bailey <39b6ae1dd30d9ab3cd77a2d084b277520f14c203@ilm.com>

--- cmake/FindJemalloc.cmake
+++ cmake/FindJemalloc.cmake
@@ -145,9 +145,9 @@
 endif()

 find_library(Jemalloc_LIBRARY jemalloc
-  "${_FIND_JEMALLOC_ADDITIONAL_OPTIONS}"
-  PATHS "${_JEMALLOC_LIBRARYDIR_SEARCH_DIRS}"
-  PATH_SUFFIXES "${JEMALLOC_PATH_SUFFIXES}"
+  ${_FIND_JEMALLOC_ADDITIONAL_OPTIONS}
+  PATHS ${_JEMALLOC_LIBRARYDIR_SEARCH_DIRS}
+  PATH_SUFFIXES ${JEMALLOC_PATH_SUFFIXES}
 )

 # Reset library suffix


To fully support multithreading, g++ compatible compilers need the -pthread flag (compiler and linker)

--- cmake/FindPthreads.cmake
+++ cmake/FindPthreads.cmake
@@ -68,6 +68,12 @@
   set(Pthreads_LIBRARIES ${Pthreads_LIBRARY})
 endif()

+# TODO:
+# Command line option -lpthread gets defined twice...
+if(CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang")
+  set(Pthreads_PACKAGE_CXX_FLAGS "-pthread")
+endif()
+
 find_package_handle_standard_args(Pthreads DEFAULT_MSG
   Pthreads_INCLUDE_DIR
   Pthreads_LIBRARY


man page absolute path

man page absolute path

--- cmake/MyPackageMan.cmake
+++ cmake/MyPackageMan.cmake
@@ -11,6 +11,7 @@
 MACRO(MyPackageMan PODFILE MANFILE SECTION VERSION)

   IF (EXISTS ${PODFILE})
+    GET_FILENAME_COMPONENT(PODFILE_ABSOLUTE ${PODFILE} ABSOLUTE)
     FIND_PROGRAM (POD2MAN pod2man)
     IF (POD2MAN)
       FIND_PROGRAM (GZIP gzip)
@@ -19,9 +20,9 @@
         IF (NOT TARGET ${MANPAGE_TARGET})
           ADD_CUSTOM_COMMAND(
 	    OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}"
-	    DEPENDS "${PODFILE}"
+	    DEPENDS "${PODFILE_ABSOLUTE}"
 	    COMMAND "${POD2MAN}"
-	    ARGS --section "${SECTION}" --center "${CMAKE_PROJECT_NAME}" -r "${VERSION}" --stderr --name "${MANFILE}" "${PODFILE}" > "${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}"
+	    ARGS --section "${SECTION}" --center "${CMAKE_PROJECT_NAME}" -r "${VERSION}" --stderr --name "${MANFILE}" "${PODFILE_ABSOLUTE}" > "${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}"
 	    )
           ADD_CUSTOM_COMMAND(
 	    OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}.gz"


cmake: fix order of headers

cmake: fix order of headers

- cmake uses filesystem's order which may vary
- unpredictable headers order may cause build failures (primary bindings)

--- cmake/OpenCVModule.cmake
+++ cmake/OpenCVModule.cmake
@@ -876,7 +876,9 @@
 macro(_ocv_create_module)

   ocv_compiler_optimization_process_sources(OPENCV_MODULE_${the_module}_SOURCES OPENCV_MODULE_${the_module}_DEPS_EXT ${the_module})
-  set(OPENCV_MODULE_${the_module}_HEADERS ${OPENCV_MODULE_${the_module}_HEADERS} CACHE INTERNAL "List of header files for ${the_module}")
+  set(__module_headers ${OPENCV_MODULE_${the_module}_HEADERS})
+  list(SORT __module_headers)  # fix headers order, useful for bindings
+  set(OPENCV_MODULE_${the_module}_HEADERS ${__module_headers} CACHE INTERNAL "List of header files for ${the_module}")
   set(OPENCV_MODULE_${the_module}_SOURCES ${OPENCV_MODULE_${the_module}_SOURCES} CACHE INTERNAL "List of source files for ${the_module}")

   # The condition we ought to be testing here is whether ocv_add_precompiled_headers will


refactor(cmake): Remove unused querybin

refactor(cmake): Remove unused querybin

--- cmake/common/utils.cmake
+++ cmake/common/utils.cmake
@@ -71,16 +71,6 @@
 endfunction()

 # }}}
-# querybin {{{
-
-function(querybin binary_name)
-  find_program(BIN_${binary_name} ${binary_name})
-  if(NOT BIN_${binary_name})
-    message_colored(FATAL_ERROR "Failed to locate ${binary_name} binary" 31)
-  endif()
-endfunction()
-
-# }}}
 # querylib {{{

 function(querylib flag type pkg out_library out_include_dirs)


Version update to 0.9.7

Version update to 0.9.7

--- cmake/globalconfig.cmake
+++ cmake/globalconfig.cmake
@@ -30,7 +30,7 @@
 set(IVW_VERSION 0.9.6)
 set(IVW_MAJOR_VERSION 0)
 set(IVW_MINOR_VERSION 9)
-set(IVW_PATCH_VERSION 6)
+set(IVW_PATCH_VERSION 7)

 #--------------------------------------------------------------------
 # Requirement checks


Added Boost and OpenRAVE DEPENDS

Added Boost and OpenRAVE DEPENDS

--- catkin.cmake
+++ catkin.cmake
@@ -10,7 +10,7 @@
 catkin_package(
     INCLUDE_DIRS include/
     LIBRARIES ${PROJECT_NAME}
-    DEPENDS OMPL Eigen
+    DEPENDS Boost Eigen OMPL OpenRAVE
 )

 include_directories(


allow lack of c++11 to be not fatal

allow lack of c++11 to be not fatal

--- common.cmake
+++ common.cmake
@@ -33,7 +33,7 @@
     execute_process(
 	COMMAND ${CMAKE_CXX_COMPILER} -dumpversion OUTPUT_VARIABLE GCC_VERSION)
     if (NOT (GCC_VERSION VERSION_GREATER 4.7 OR GCC_VERSION VERSION_EQUAL 4.7))
-	message(FATAL_ERROR "${PROJECT_NAME} requires g++ 4.7 or greater.")
+	message("${PROJECT_NAME} requires g++ 4.7 or greater for C++11.")
     endif ()
 elseif (${CMAKE_CXX_COMPILER_ID} MATCHES "Clang")


FIX: CMake Json libraries fix to build the extension in new Slicer release

--- SuperBuild/External_CIP.cmake
+++ SuperBuild/External_CIP.cmake
@@ -33,11 +33,11 @@

   ExternalProject_Add(${proj}
     ${${proj}_EP_ARGS}
-    GIT_REPOSITORY "${git_protocol}://github.com/acil-bwh/ChestImagingPlatform.git"
-    GIT_TAG develop
-    SOURCE_DIR ${CMAKE_BINARY_DIR}/${proj}
-    #DOWNLOAD_COMMAND ${CMAKE_COMMAND} -E echo "Remove this line and uncomment GIT_REPOSITORY and GIT_TAG"
-    #SOURCE_DIR ../CIP
+    #GIT_REPOSITORY "${git_protocol}://github.com/acil-bwh/ChestImagingPlatform.git"
+    #GIT_TAG develop
+    #SOURCE_DIR ${CMAKE_BINARY_DIR}/${proj}
+    DOWNLOAD_COMMAND ${CMAKE_COMMAND} -E echo "Remove this line and uncomment GIT_REPOSITORY and GIT_TAG"
+    SOURCE_DIR ../CIP
     BINARY_DIR ${proj}-build
     CMAKE_CACHE_ARGS
       -DCIP_SUPERBUILD:BOOL=OFF
@@ -48,6 +48,8 @@
       -DTeem_DIR:PATH=${Teem_DIR}
       -DLIBXML2_INCLUDE_DIR:PATH=${vtklibxml2_INCLUDE_DIRS}
       -DLIBXML2_LIBRARIES:PATH=${vtklibxml2_LIBRARIES}
+      -DJsonCpp_INCLUDE_DIR:PATH=${vtkjsoncpp_INCLUDE_DIRS}
+      -DJsonCpp_LIBRARY:PATH=${vtkjsoncpp_LIBRARIES}
       -DBUILD_GENERATEMODEL:BOOL=OFF
       -DBUILD_GENERATESIMPLELUNGMASK:BOOL=OFF # temporarily off due to lack of VtkGlue
       -DBUILD_ComputeAirwayWallFromParticles:BOOL=OFF # temporarily off due to lack of VtkGlue


Rookie mistake. Local debug cmake settings...

--- SuperBuild/External_CIP.cmake
+++ SuperBuild/External_CIP.cmake
@@ -33,11 +33,11 @@

   ExternalProject_Add(${proj}
     ${${proj}_EP_ARGS}
-    #GIT_REPOSITORY "${git_protocol}://github.com/acil-bwh/ChestImagingPlatform.git"
-    #GIT_TAG origin/develop
-    #SOURCE_DIR ${CMAKE_BINARY_DIR}/${proj}
-    DOWNLOAD_COMMAND ${CMAKE_COMMAND} -E echo "Remove this line and uncomment GIT_REPOSITORY and GIT_TAG"
-    SOURCE_DIR /Users/jonieva/Projects/CIP
+    GIT_REPOSITORY "${git_protocol}://github.com/acil-bwh/ChestImagingPlatform.git"
+    GIT_TAG origin/develop
+    SOURCE_DIR ${CMAKE_BINARY_DIR}/${proj}
+    #DOWNLOAD_COMMAND ${CMAKE_COMMAND} -E echo "Remove this line and uncomment GIT_REPOSITORY and GIT_TAG"
+    #SOURCE_DIR /Users/jonieva/Projects/CIP
     BINARY_DIR ${proj}-build
     CMAKE_CACHE_ARGS
       #-DBUILD_COMMANDLINETOOLS:BOOL=ON


COMP: Set superbuild ITK BUILD_SHARED_LIBS OFF.

The tests had a hard time finding the libraries on Windows.

--- Superbuild/External-ITK.cmake
+++ Superbuild/External-ITK.cmake
@@ -13,7 +13,7 @@
   CMAKE_GENERATOR ${gen}
   CMAKE_ARGS
     ${ep_common_args}
-    -DBUILD_SHARED_LIBS:BOOL=ON
+    -DBUILD_SHARED_LIBS:BOOL=OFF
     -DBUILD_EXAMPLES:BOOL=OFF
     -DBUILD_TESTING:BOOL=OFF
     -DITK_BUILD_ALL_MODULES:BOOL=ON


update PCL_SUFFIX in trunk's FindPCL.cmake

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

--- doc/tutorials/content/sources/FindPCL.cmake
+++ doc/tutorials/content/sources/FindPCL.cmake
@@ -37,7 +37,7 @@

 include(FindPackageHandleStandardArgs)
 #set a suffix based on project name and version
-set(PCL_SUFFIX pcl-1.0)
+set(PCL_SUFFIX pcl-1.2)
 #set a suffix for debug libraries
 set(PCL_DEBUG_SUFFIX "-gd")


Update boost to next release version 1.56.


Bugfix for OGRE-210 and message for atomic

--HG--
branch : v1-9

--- CMake/Dependencies.cmake
+++ CMake/Dependencies.cmake
@@ -170,7 +170,7 @@
     find_package(Boost COMPONENTS ${OGRE_BOOST_COMPONENTS} QUIET)
 endif()

-if(Boost_FOUND)
+if(Boost_FOUND AND NOT WIN32)
   list(REMOVE_DUPLICATES Boost_LIBRARIES)
 endif()

@@ -181,6 +181,9 @@
 if(Boost_VERSION GREATER 104900)
     macro_log_feature(Boost_SYSTEM_FOUND "boost-system" "Used for threading support" "http://boost.org" FALSE "" "")
     macro_log_feature(Boost_CHRONO_FOUND "boost-chrono" "Used for threading support" "http://boost.org" FALSE "" "")
+	if(Boost_VERSION GREATER 105300)
+		macro_log_feature(Boost_ATOMIC_FOUND "boost-atomic" "Used for threading support" "http://boost.org" FALSE "" "")
+	endif()
 endif()

 # POCO


cmake: fix git id generation

cmake: fix git id generation

--- CMakeModules/gitid.cmake
+++ CMakeModules/gitid.cmake
@@ -1,6 +1,11 @@
 set(CMAKE_MODULE_PATH ${TOP_SOURCE_DIR}/CMakeModules)

 if (GIT_EXECUTABLE)
+  # refresh git index
+  execute_process(COMMAND ${GIT_EXECUTABLE} update-index -q --refresh
+    WORKING_DIRECTORY ${TOP_SOURCE_DIR} TIMEOUT 5 OUTPUT_QUIET
+    ERROR_VARIABLE EXEC_ERR OUTPUT_STRIP_TRAILING_WHITESPACE
+  )
   #later use git describe here
   execute_process( COMMAND ${GIT_EXECUTABLE} rev-parse --short HEAD
     WORKING_DIRECTORY ${TOP_SOURCE_DIR}


Fixed the indentation of the cmake file

Fixed the indentation of the cmake file

--- cmake/EigenTesting.cmake
+++ cmake/EigenTesting.cmake
@@ -514,11 +514,11 @@
   # if the sitename is not yet set, try to set it
   if(NOT ${SITE} OR ${SITE} STREQUAL "")
     set(eigen_computername $ENV{COMPUTERNAME})
-  set(eigen_hostname $ENV{HOSTNAME})
+    set(eigen_hostname $ENV{HOSTNAME})
     if(eigen_hostname)
       set(SITE ${eigen_hostname})
-  elseif(eigen_computername)
-    set(SITE ${eigen_computername})
+    elseif(eigen_computername)
+      set(SITE ${eigen_computername})
     endif()
   endif()
   # in case it is already set, enforce lower case
@@ -638,18 +638,18 @@

   if(EIGEN_TEST_OPENMP)
     if (${VAR} STREQUAL "")
-    set(${VAR} OMP)
-  else()
-    set(${VAR} ${${VAR}}-OMP)
-  endif()
+      set(${VAR} OMP)
+    else()
+      set(${VAR} ${${VAR}}-OMP)
+    endif()
   endif()

   if(EIGEN_DEFAULT_TO_ROW_MAJOR)
     if (${VAR} STREQUAL "")
-    set(${VAR} ROW)
-  else()
-    set(${VAR} ${${VAR}}-ROWMAJ)
-  endif()
+      set(${VAR} ROW)
+    else()
+      set(${VAR} ${${VAR}}-ROWMAJ)
+    endif()
   endif()
 endmacro(ei_get_cxxflags)


Fix quoting of desktop source and install path in FindIntltool

--- cmake/FindIntltool.cmake
+++ cmake/FindIntltool.cmake
@@ -14,7 +14,8 @@
             ${INTLTOOL_MERGE_EXECUTABLE} --desktop-style ${CMAKE_SOURCE_DIR}/${po_dir}
                 ${CMAKE_CURRENT_SOURCE_DIR}/${desktop_id}.desktop.in ${desktop_id}.desktop
         )
-        install (FILES ${CMAKE_CURRENT_BINARY_DIR}/"${desktop_id}.desktop" DESTINATION ${CMAKE_INSTALL_PREFIX}/share/applications)
+        install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${desktop_id}.desktop"
+                 DESTINATION "${CMAKE_INSTALL_PREFIX}/share/applications")
     endmacro (INTLTOOL_MERGE_DESKTOP desktop_id po_dir)
 endif ()


set var

set var

--- cmake/FindOpenBLAS.cmake
+++ cmake/FindOpenBLAS.cmake
@@ -39,7 +39,7 @@
             ${MSYS_ROOT}/usr/include
             ${MSYS_ROOT}/usr/include/openblas
             ${MSYS_ROOT}/usr/include/openblas-base
-            ${MSYS_ROOT}${MSYS_ROOT}/usr/local/include
+            ${MSYS_ROOT}/usr/local/include
             ${MSYS_ROOT}/usr/local/include/openblas
             ${MSYS_ROOT}/usr/local/include/openblas-base
             ${MSYS_ROOT}/opt/OpenBLAS/include
@@ -91,33 +91,7 @@
             $ENV{OpenBLAS_HOME}/lib
             )
 endif()
-SET(Open_BLAS_INCLUDE_SEARCH_PATHS
-        /usr/include
-        /usr/include/openblas
-        /usr/include/openblas-base
-        /usr/local/include
-        /usr/local/include/openblas
-        /usr/local/include/openblas-base
-        /opt/OpenBLAS/include
-        $ENV{OpenBLAS_HOME}
-        $ENV{OpenBLAS_HOME}/include
-        )
-
-SET(Open_BLAS_LIB_SEARCH_PATHS
-        /lib/
-        /lib/openblas-base
-        /lib64/
-        /usr/lib
-        /usr/lib/openblas-base
-        /usr/lib64
-        /usr/local/lib
-        /usr/local/lib64
-        /opt/OpenBLAS/lib
-        $ENV{OpenBLAS}cd
-        $ENV{OpenBLAS}/lib
-        $ENV{OpenBLAS_HOME}
-        $ENV{OpenBLAS_HOME}/lib
-        )
+

 FIND_PATH(OpenBLAS_INCLUDE_DIR NAMES cblas.h PATHS ${Open_BLAS_INCLUDE_SEARCH_PATHS})
 FIND_LIBRARY(OpenBLAS_LIB NAMES openblas PATHS ${Open_BLAS_LIB_SEARCH_PATHS})


Added support for finding OpenSLES with CMake + Android.

--- cmake/FindOpenSLES.cmake
+++ cmake/FindOpenSLES.cmake
@@ -8,6 +8,10 @@
 if(OPENSLES_INCLUDE_DIR)
 	# Already in cache, be silent
 	set(OPENSLES_FIND_QUIETLY TRUE)
+elseif(ANDROID)
+	# Android has no pkgconfig - fallback to default paths
+	set(PC_OPENSLES_INCLUDE_DIR "${ANDROID_SYSROOT}/usr/include")
+	set(PC_OPENSLES_LIBDIR      "${ANDROID_SYSROOT}/usr/lib"    )
 else()
 	find_package(PkgConfig)
 	pkg_check_modules(PC_OPENSLES QUIET OpenSLES)
@@ -17,7 +21,7 @@
 	HINTS ${PC_OPENSLES_INCLUDE_DIR})

 find_library(OPENSLES_LIBRARY NAMES OpenSLES
-	HINTS ${PC_OPENSLES_LIBDIR} ${PC_OPENSLES_LIBARRY_DIRS})
+	HINTS ${PC_OPENSLES_LIBDIR} ${PC_OPENSLES_LIBRARY_DIRS})

 # Handle the QUIETLY and REQUIRED arguments and set OPENSL_FOUND to TRUE if
 # all listed variables are TRUE.


Remove old find tcmalloc script

Remove old find tcmalloc script

--- cmake/FindTcmalloc.cmake
+++ cmake/FindTcmalloc.cmake
@@ -1,35 +0,0 @@
-# - Find Tcmalloc
-# Find the native Tcmalloc includes and library
-#
-#  Tcmalloc_INCLUDE_DIR - where to find Tcmalloc.h, etc.
-#  Tcmalloc_LIBRARIES   - List of libraries when using Tcmalloc.
-#  Tcmalloc_FOUND       - True if Tcmalloc found.
-
-find_path(Tcmalloc_INCLUDE_DIR google/tcmalloc.h)
-
-set(Tcmalloc_NAMES tcmalloc_minimal)
-
-find_library(Tcmalloc_LIBRARY NAMES ${Tcmalloc_NAMES})
-
-if (Tcmalloc_INCLUDE_DIR AND Tcmalloc_LIBRARY)
-  set(Tcmalloc_FOUND TRUE)
-  set( Tcmalloc_LIBRARIES ${Tcmalloc_LIBRARY} )
-else ()
-  set(Tcmalloc_FOUND FALSE)
-  set( Tcmalloc_LIBRARIES )
-endif ()
-
-if (Tcmalloc_FOUND)
-  message(STATUS "Found Tcmalloc: ${Tcmalloc_LIBRARY}")
-else ()
-  message(STATUS "Not Found Tcmalloc")
-  if (Tcmalloc_FIND_REQUIRED)
-    message(STATUS "Looked for Tcmalloc libraries named ${Tcmalloc_NAMES}.")
-    message(FATAL_ERROR "Could NOT find Tcmalloc library")
-  endif ()
-endif ()
-
-mark_as_advanced(
-  Tcmalloc_LIBRARY
-  Tcmalloc_INCLUDE_DIR
-)


cmake: Use set_target_properties for include dirs

target_include_directories for INTERFACE IMPORTED targets is only
supported since cmake 3.11

Fixes #2387

Ref: https://gitlab.kitware.com/cmake/cmake/-/issues/15689

--- cmake/common/utils.cmake
+++ cmake/common/utils.cmake
@@ -117,8 +117,8 @@
   add_library(${library_name} INTERFACE IMPORTED)
   set_target_properties(${library_name} PROPERTIES
     INTERFACE_LINK_LIBRARIES "${libraries}"
+    INTERFACE_INCLUDE_DIRECTORIES "${includes}"
   )
-  target_include_directories(${library_name} SYSTEM INTERFACE ${includes})
 endfunction()
 # }}}
 # checklib {{{


VAD_cliini - fix fnmatch on win

VAD_cliini - fix fnmatch on win

--- external/vigra_cmake/VAD_cliini.cmake
+++ external/vigra_cmake/VAD_cliini.cmake
@@ -23,6 +23,10 @@

   git_clone(cliini)

+  if(WIN32)
+    vigra_add_dep(fnmatch REQUIRED LIVE)
+  endif()
+
   # TODO default seems to point to checkout out dir in source?!?
   add_subdirectory("${VAD_EXTERNAL_ROOT}/cliini" "${CMAKE_BINARY_DIR}/external/cliini")


Fix bad endif in doxygen.cmake

Fix bad endif in doxygen.cmake

--- build-aux/doxygen.cmake
+++ build-aux/doxygen.cmake
@@ -589,41 +589,27 @@
   if ("x${install_docs_from}" STREQUAL "x")
     set(install_from "${DOXYGEN_OUT_DIR}")
     set(rebuild TRUE)
-
-    if (DOXYGEN_CMAKE_VERBOSE)
-      message("Installing from the built docs '${install_from}' -- will be built.")
-    endif()
   else()
     set(install_from "${install_docs_from}")
     set(rebuild FALSE)
-
-    if (DOXYGEN_CMAKE_VERBOSE)
-      message("Installing from given path '${install_from}'")
-    endif()
   endif()

   if (DOXYGEN_CMAKE_VERBOSE)
-    message("* wants: '${wants}'")
-    message("* base target: '${doxygen_target}'")
-    message("* install from: '${install_from}'")
-    message("* install to: '${install_to}'")
+    message(STATUS "Details of doxygen install:")
+    message(STATUS "* wants: '${wants}'")
+    message(STATUS "* base target: '${doxygen_target}'")
+    message(STATUS "* install from: '${install_from}'")
+    message(STATUS "* install to: '${install_to}'")
+    message(STATUS "* rebuild: ${rebuild}")
   endif()

   foreach(iter ${wants})
     if (iter MATCHES "pdf")
       set(file "${install_from}/${DOXYGEN_REL_PDF_FILE}")
       set(inst "${install_to}/${DOXYGEN_REL_LATEX_DIR}")
-      if (DOXYGEN_CMAKE_VERBOSE)
-        message("pdf:\n  from: ${file}\n  to: ${inst}")
-      endif()

       if (rebuild)
         add_custom_target(depend_${doxygen_target}_pdf ALL DEPENDS "${DOXYGEN_PDF_FILE}")
-        if (DOXYGEN_CMAKE_VERBOSE)
-          message("  pdf depend target added (depend_${doxygen_target}_pdf)")
-        endif()
-      elseif(DOXYGEN_CMAKE_VERBOSE)
-        message("  no pdf depend target added")
       endif()

       install(
@@ -634,17 +620,8 @@
       set(file "${install_from}/${DOXYGEN_REL_HTML_DIR}")
       set(inst "${install_to}")

-      if (DOXYGEN_CMAKE_VERBOSE)
-        message("html:\n  from: ${file}\n  to: ${inst}")
-      endif()
-
       if (rebuild)
         add_custom_target(depend_${doxygen_target}_html ALL DEPENDS "${DOXYGEN_HTML_DIR}")
-        if (DOXYGEN_CMAKE_VERBOSE)
-          message("  html depend target added (depend_${doxygen_target}_html)")
-        endif()
-      elseif(DOXYGEN_CMAKE_VERBOSE)
-        message("  no html depend target added")
       endif()

       install(


NEW: Diffusion benchmark

NEW: Diffusion benchmark

--- examples/diffusion-benchmark/Makefile.cmake
+++ examples/diffusion-benchmark/Makefile.cmake
@@ -152,6 +152,7 @@
 $(PHYSIS_BUILD_DIR)/diffusion3d_physis.cuda.exe: $(PHYSIS_BUILD_DIR)/diffusion3d_physis.cuda.o \
 	main_physis.o baseline.o diffusion3d.o @CMAKE_INSTALL_PREFIX@/lib/libphysis_rt_cuda.a
 	$(CXX) -o $@ $^ $(LDFLAGS) $(CUDA_LDFLAGS)
+
 # mpi
 $(PHYSIS_BUILD_DIR)/diffusion3d_physis.mpi.c: diffusion3d_physis.c $(PHYSISC_CONFIG)
 	cd $(PHYSIS_BUILD_DIR) && $(PHYSISC_MPI) ../../$<


Removed 3rdParty deps from coverage report.

--- cmake/CodeCoverage.cmake
+++ cmake/CodeCoverage.cmake
@@ -37,7 +37,7 @@

         # Capture coverage data.
         COMMAND ${LCOV_PATH} --compat-libtool --directory . --capture --output-file ${_outputname}.info
-        COMMAND ${LCOV_PATH} --remove ${_outputname}.info 'tests/*' '/usr/*' 'foreign/*' --output-file ${_outputname}.info.cleaned
+        COMMAND ${LCOV_PATH} --remove ${_outputname}.info 'tests/*' '/usr/*' 'tools/*' '3rdParty/*' --output-file ${_outputname}.info.cleaned

         # Generating the report.
         COMMAND ${GENHTML_PATH} -o ${_outputname} ${_outputname}.info.cleaned


Removing windows ifdef (#268)

Removing windows ifdef (#268)

--- cmake/Dependencies.cmake
+++ cmake/Dependencies.cmake
@@ -178,58 +178,27 @@
   find_package(benchmark REQUIRED CONFIG PATHS ${GOOGLEBENCHMARK_ROOT})
 endif()

-# Find or download/install rocm-cmake project
-if (WIN32)
-  find_package(ROCM QUIET CONFIG PATHS /opt/rocm)
-  if(NOT ROCM_FOUND)
-    set(rocm_cmake_tag "master" CACHE STRING "rocm-cmake tag to download")
-    file(
-      DOWNLOAD https://github.com/RadeonOpenCompute/rocm-cmake/archive/${rocm_cmake_tag}.zip
-      ${CMAKE_CURRENT_BINARY_DIR}/rocm-cmake-${rocm_cmake_tag}.zip
-      STATUS rocm_cmake_download_status LOG rocm_cmake_download_log
-    )
-    list(GET rocm_cmake_download_status 0 rocm_cmake_download_error_code)
-    if(rocm_cmake_download_error_code)
-      message(FATAL_ERROR "Error: downloading "
-        "https://github.com/RadeonOpenCompute/rocm-cmake/archive/${rocm_cmake_tag}.zip failed "
-        "error_code: ${rocm_cmake_download_error_code} "
-        "log: ${rocm_cmake_download_log} "
-      )
-    endif()
-
-    execute_process(
-      COMMAND ${CMAKE_COMMAND} -E tar xzf ${CMAKE_CURRENT_BINARY_DIR}/rocm-cmake-${rocm_cmake_tag}.zip
-      WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
-      RESULT_VARIABLE rocm_cmake_unpack_error_code
-    )
-    if(rocm_cmake_unpack_error_code)
-      message(FATAL_ERROR "Error: unpacking  ${CMAKE_CURRENT_BINARY_DIR}/rocm-cmake-${rocm_cmake_tag}.zip failed")
-    endif()
-    find_package(ROCM REQUIRED CONFIG PATHS ${CMAKE_CURRENT_BINARY_DIR}/rocm-cmake-${rocm_cmake_tag})
-  endif()
-else()
-  find_package(ROCM 0.6 QUIET CONFIG PATHS /opt/rocm)
-  if(NOT ROCM_FOUND)
-    message(STATUS "rocm-cmake not found. Downloading and building rocm-cmake.")
-    if(CMAKE_CONFIGURATION_TYPES)
-      message(FATAL_ERROR "DownloadProject.cmake doesn't support multi-configuration generators.")
-    endif()
-    set(ROCM_CMAKE_ROOT ${CMAKE_CURRENT_BINARY_DIR}/deps/rocm-cmake CACHE PATH "")
-    download_project(
-        PROJ           rocm-cmake
-        GIT_REPOSITORY https://github.com/RadeonOpenCompute/rocm-cmake.git
-        GIT_TAG        master
-        INSTALL_DIR    ${ROCM_CMAKE_ROOT}
-        CMAKE_ARGS     -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
-        LOG_DOWNLOAD   TRUE
-        LOG_CONFIGURE  TRUE
-        LOG_BUILD      TRUE
-        LOG_INSTALL    TRUE
-        BUILD_PROJECT  TRUE
-        ${UPDATE_DISCONNECTED_IF_AVAILABLE}
-      )
-    find_package(ROCM 0.6 REQUIRED CONFIG PATHS ${ROCM_CMAKE_ROOT})
-  endif()
+find_package(ROCM 0.6 QUIET CONFIG PATHS /opt/rocm)
+if(NOT ROCM_FOUND)
+  message(STATUS "rocm-cmake not found. Downloading and building rocm-cmake.")
+  if(CMAKE_CONFIGURATION_TYPES)
+    message(FATAL_ERROR "DownloadProject.cmake doesn't support multi-configuration generators.")
+  endif()
+  set(ROCM_CMAKE_ROOT ${CMAKE_CURRENT_BINARY_DIR}/deps/rocm-cmake CACHE PATH "")
+  download_project(
+      PROJ           rocm-cmake
+      GIT_REPOSITORY https://github.com/RadeonOpenCompute/rocm-cmake.git
+      GIT_TAG        master
+      INSTALL_DIR    ${ROCM_CMAKE_ROOT}
+      CMAKE_ARGS     -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
+      LOG_DOWNLOAD   TRUE
+      LOG_CONFIGURE  TRUE
+      LOG_BUILD      TRUE
+      LOG_INSTALL    TRUE
+      BUILD_PROJECT  TRUE
+      ${UPDATE_DISCONNECTED_IF_AVAILABLE}
+    )
+  find_package(ROCM 0.6 REQUIRED CONFIG PATHS ${ROCM_CMAKE_ROOT})
 endif()
 include(ROCMSetupVersion)
 include(ROCMCreatePackage)


debug opencv libs detected

debug opencv libs detected

--- cmake/DetectOpenCV.cmake
+++ cmake/DetectOpenCV.cmake
@@ -34,6 +34,10 @@
 if(OpenCV_FOUND)

     list(APPEND ${ROOT_PROJECT}_INCLUDE_DIRS ${OpenCV_INCLUDE_DIRS})
+
+    list(LENGTH ${OpenCV_LIBS} OpenCV_NUM_LIBS)
+    message(STATUS "OpenCV_NUM_LIBS=${OpenCV_NUM_LIBS}")
+    message(STATUS "OpenCV_LIBS=${OpenCV_LIBS}")
     list(APPEND ${ROOT_PROJECT}_LIBS ${OpenCV_LIBS})

 else(OpenCV_FOUND)


resolver should be compiled in per default

--- cmake/ElektraCache.cmake
+++ cmake/ElektraCache.cmake
@@ -3,7 +3,7 @@
 #
 # Here the cache variables are set

-set (BACKENDS dump hosts fstab CACHE STRING "Which backends to use?")
+set (BACKENDS dump resolver CACHE STRING "Which backends to use?")
 set (BACKEND_DEFAULT dump CACHE STRING "Which should be the default backend?")

 set (KDB_DB_SYSTEM "/etc" CACHE PATH "Where should be the system configuration?")


Removing unneeded FindCherryPy.cmake file.

--- cmake/FindCherryPy.cmake
+++ cmake/FindCherryPy.cmake
@@ -1,7 +0,0 @@
-include(FindPackageHandleStandardArgs)
-
-if(NOT CherryPy_EXECUTABLE)
-    find_program(CherryPy_EXECUTABLE NAMES cherryd2 cherryd)
-endif()
-
-find_package_handle_standard_args(CherryPy DEFAULT_MSG CherryPy_EXECUTABLE)


IVGCVSW-2735 Fail build if TfLite parser or armnnSerializer can't be built

Change-Id: I39a2fee99218a0a31d8ce6c46d7cc1c0ca5b75d2
Signed-off-by: Matthew Bentham <286076deec2404ae356dd8bc92f2f71e81044bd4@arm.com>

--- cmake/GlobalConfig.cmake
+++ cmake/GlobalConfig.cmake
@@ -172,33 +172,15 @@
     find_path(FLATBUFFERS_INCLUDE_PATH flatbuffers/flatbuffers.h
               HINTS ${FLATBUFFERS_ROOT}/include /usr/local/include /usr/include)

-    if(NOT FLATBUFFERS_INCLUDE_PATH)
-        message(WARNING
-          "Couldn't find 'flatbuffers/flatbuffers.h' at ${FLATBUFFERS_ROOT}/include. \
-           Disabling Tf Lite and Armnn Serializer support")
-        set(BUILD_TF_LITE_PARSER Off)
-        set(BUILD_ARMNN_SERIALIZER Off)
-    else()
-        message(STATUS "Flatbuffers headers are located at: ${FLATBUFFERS_INCLUDE_PATH}")
-    endif()
+    message(STATUS "Flatbuffers headers are located at: ${FLATBUFFERS_INCLUDE_PATH}")

     find_library(FLATBUFFERS_LIBRARY
                  NAMES libflatbuffers.a flatbuffers
                  HINTS ${FLATBUFFERS_ROOT}/lib /usr/local/lib /usr/lib)

-    if(NOT FLATBUFFERS_LIBRARY)
-        message(WARNING
-          "Couldn't find flatbuffers library. Disabling Tf Lite and Armnn Serializer support")
-        set(BUILD_TF_LITE_PARSER Off)
-        set(BUILD_ARMNN_SERIALIZER Off)
-    else()
-        message(STATUS "Flatbuffers library located at: ${FLATBUFFERS_LIBRARY}")
-    endif()
-
-    # Setup includes and libs only if we still want Tf Lite or Armnn Serializer
-    if(BUILD_TF_LITE_PARSER OR BUILD_ARMNN_SERIALIZER)
-        include_directories(SYSTEM "${FLATBUFFERS_INCLUDE_PATH}")
-    endif()
+    message(STATUS "Flatbuffers library located at: ${FLATBUFFERS_LIBRARY}")
+
+    include_directories(SYSTEM "${FLATBUFFERS_INCLUDE_PATH}")
 endif()

 # Flatbuffers schema support for TF Lite
@@ -207,19 +189,10 @@
               schema_generated.h
               HINTS ${TF_LITE_GENERATED_PATH})

-    if(NOT TF_LITE_SCHEMA_INCLUDE_PATH)
-        message(WARNING
-                "Couldn't find 'schema_generated.h' at ${TF_LITE_GENERATED_PATH}. Disabling Tf Lite support")
-        set(BUILD_TF_LITE_PARSER Off)
-    else()
-        message(STATUS "Tf Lite generated header found at: ${TF_LITE_SCHEMA_INCLUDE_PATH}")
-    endif()
-
-    # Setup includes and libs only if we still want Tf Lite
-    if(BUILD_TF_LITE_PARSER)
-        add_definitions(-DARMNN_TF_LITE_PARSER)
-        add_definitions(-DARMNN_TF_LITE_SCHEMA_PATH="${TF_LITE_SCHEMA_INCLUDE_PATH}/schema.fbs")
-    endif()
+    message(STATUS "Tf Lite generated header found at: ${TF_LITE_SCHEMA_INCLUDE_PATH}")
+
+    add_definitions(-DARMNN_TF_LITE_PARSER)
+    add_definitions(-DARMNN_TF_LITE_SCHEMA_PATH="${TF_LITE_SCHEMA_INCLUDE_PATH}/schema.fbs")
 endif()

 if(BUILD_ARMNN_SERIALIZER)


remove hard code dependencies

remove hard code dependencies

--- cmake/InstallFolly.cmake
+++ cmake/InstallFolly.cmake
@@ -5,7 +5,6 @@
     endif()

     ExternalProject_Add(Folly
-        DEPENDS             GFlags GLog
         DOWNLOAD_NAME       Folly-${FOLLY_VERSION}.tar.gz
         URL                 https://github.com/facebook/folly/archive/v${FOLLY_VERSION}.tar.gz
         URL_MD5             ${FOLLY_URL_MD5}


fix a bug that cannot find the QGLViewer library path.

--- cmake/UseQGLViewer.cmake
+++ cmake/UseQGLViewer.cmake
@@ -11,6 +11,7 @@
 ENDIF()

 FIND_PATH(QGLVIEWER_INC "/QGLViewer/qglviewer.h" HINTS "${QGLVIEWER_ROOT}")
-FIND_LIBRARY(QGLVIEWER_LIBRARY QGLViewerd2 HINTS "${QGLVIEWER_ROOT}/QGLViewer/")
+FIND_PATH(QGLVIEWER_LIB "QGLViewer2.lib" HINTS "${QGLVIEWER_ROOT}/QGLViewer/")
+FIND_LIBRARY(QGLVIEWER_LIBRARY QGLViewer2 HINTS "${QGLVIEWER_ROOT}/QGLViewer/")

 INCLUDE_DIRECTORIES(${QGLVIEWER_INC})


Bug#11765489 CMAKE BUILD ON MAC OS X DOES NOT DETERMINE CPU TYPE

Don't use CMAKE_OSX_ARCHITECTURES to determine DEFAULT_MACHINE
if it is not defined.

If we're 64bit, then use "x86_64" rather than "x86"

--- cmake/package_name.cmake
+++ cmake/package_name.cmake
@@ -1,4 +1,4 @@
-# Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -83,12 +83,20 @@
         MATH(EXPR VER  "${VER} -4")
         SET(DEFAULT_PLATFORM "osx10.${VER}")
       ENDIF()
-      LIST(LENGTH CMAKE_OSX_ARCHITECTURES LEN)
-      IF(LEN GREATER 1)
-        SET(DEFAULT_MACHINE "universal")
+
+      IF(CMAKE_OSX_ARCHITECTURES)
+        LIST(LENGTH CMAKE_OSX_ARCHITECTURES LEN)
+        IF(LEN GREATER 1)
+          SET(DEFAULT_MACHINE "universal")
+        ELSE()
+          SET(DEFAULT_MACHINE "${CMAKE_OSX_ARCHITECTURES}")
+        ENDIF()
       ELSE()
-        SET(DEFAULT_MACHINE "${CMAKE_OSX_ARCHITECTURES}")
+        IF(64BIT)
+          SET(DEFAULT_MACHINE "x86_64")
+        ENDIF()
       ENDIF()
+
       IF(DEFAULT_MACHINE MATCHES "i386")
         SET(DEFAULT_MACHINE "x86")
       ENDIF()