workaround for configuration trouble in lsdalton

--- cmake/custom/xcfun.cmake
+++ cmake/custom/xcfun.cmake
@@ -1,8 +1,7 @@
 find_package(XCFun CONFIG QUIET)

 if(TARGET XCFun::xcfun)
-  get_property(_loc TARGET XCFun::xcfun PROPERTY LOCATION)
-  message(STATUS "Found XCFun: ${_loc} (found version ${XCFun_VERSION})")
+  message(STATUS "Found XCFun version ${XCFun_VERSION}")
 else()
   include(FetchContent)


update dl link for fifechan

update dl link for fifechan

--- cmake/get-fifechan.cmake
+++ cmake/get-fifechan.cmake
@@ -35,8 +35,8 @@
       PREFIX              ${DEPENDENCY_EXTRACT_DIR}
       DOWNLOAD_DIR        ${DEPENDENCY_DOWNLOAD_DIR}
       #URL                 https://github.com/fifengine/fifechan/releases/tag/${FIFECHAN_VERSION}/fifechan-v${FIFECHAN_VERSION}-VC14.zip
-      URL                 https://ci.appveyor.com/api/buildjobs/a0uhvgruutuwhqho/artifacts/fifechan-shared-dev-46778a3-VC14-x86.zip
-      URL_MD5             350a592d741211ec068e1c6f7792bc76
+      URL                 https://ci.appveyor.com/api/buildjobs/5rg5bi98ta05l6v0/artifacts/fifechan-shared-dev-cf9d15b-VC15-x86.zip
+      URL_MD5             2bd90a93059c7a969c2069adda81e9e5
       CONFIGURE_COMMAND   ""
       BUILD_COMMAND       ""
       INSTALL_COMMAND


new lcmtypes scripts are almost working...

git-svn-id: cf55bc44fb097054a32fc70455a459c940dbbffc@7785 c9849af7-e679-4ec6-a44e-fc146a885bd3

--- cmake/new_lcmtypes.cmake
+++ cmake/new_lcmtypes.cmake
@@ -13,6 +13,8 @@
 #             LCMTYPES_INCLUDE_DIR
 #             LCMTYPES_LIBS
 #             LCMTYPES_JAR
+#
+#     lcmtypes_build()  # this must be called to finish
 #
 #     add_lcmtype(lcmfile)
 #          which generates build rules for C,CPP, Java (if java is available), and
@@ -69,6 +71,9 @@
 # Distributed with pods version: 12.09.21

 cmake_minimum_required(VERSION 2.8.3) # for the CMakeParseArguments macro
+
+find_package(Java REQUIRED)
+include(UseJava)

 macro(lcmtypes_setup)
   find_package(PkgConfig REQUIRED)
@@ -90,21 +95,45 @@
   if (NOT LCMTYPES_C_AGGREGATE_HEADER)
     set(LCMTYPES_C_AGGREGATE_HEADER "${__sanitized_project_name}.h")
   endif()
+  if (NOT LCMTYPES_C_LIBNAME)
+    set(LCMTYPES_C_LIBNAME "${__sanitized_project_name}_lcmtypes")
+  endif()
   if (NOT LCMTYPES_CPP_AGGREGATE_HEADER)
     set(LCMTYPES_C_AGGREGATE_HEADER "${__sanitized_project_name}.hpp")
   endif()
   if (NOT LCMTYPES_JARNAME)
-    set(LCMTYPES_JARNAME "${__sanitized_project_name}.jar")
+    set(LCMTYPES_JARNAME "${__sanitized_project_name}")
   endif()

   set(LCMTYPES_DIR ${CMAKE_CURRENT_BINARY_DIR}/lcmtypes)
+  execute_process(COMMAND mkdir -p ${LCMTYPES_DIR})
+
+  set(LCMTYPES_C_SOURCEFILES)
+
+endmacro()
+
+macro(lcmtypes_build)

 #  add_custom_target(${LCMTYPES_DIR}/${LCMTYPES_C_AGGREGATE_HEADER})
-#  add_library(${LCMTYPES_DIR}/${LCMTYPES_C_LIBNAME})
-#  add_custom_target(${LCMTYPES_DIR}/${LCMTYPES_CPP_AGGREGATE_HEADER})
-#  add_jar(${LCMTYPES_DIR}/${LCMTYPES_JARNAME})
+
+  if (LCMTYPES_C_SOURCEFILES)
+    add_library(${LCMTYPES_C_LIBNAME} ${LCMTYPES_C_SOURCEFILES})
+
+    # todo: write aggregate header
+  endif()
+
+  if (LCMTYPES_CPP_HEADERFILES)
+    # todo: write aggregate header
+  endif()
+
+  if (LCMTYPES_JAVA_SOURCEFILES)
+    add_jar(${LCMTYPES_JARNAME} ${LCMTYPES_JAVA_SOURCEFILES})
+  endif()
+
+#  todo: handle python

 #  todo: add install rules
+
 endmacro()

 function(lcmgen)
@@ -114,375 +143,75 @@
   endif()
 endfunction()

+macro(get_package_name lcmtype)
+  # extract package name from lcm file.
+  # creates variable ${_package_name}
+  # todo: make this more robust
+
+  execute_process(COMMAND sed -n -e "s/^.*package *\\(.*\\); *$/\\1/p" ${CMAKE_CURRENT_SOURCE_DIR}/${lcmtype} OUTPUT_VARIABLE _package_name OUTPUT_STRIP_TRAILING_WHITESPACE)
+endmacro()
+
 function(add_c_lcmtype lcmtype)
   get_filename_component(lcmtype_we ${lcmtype} NAME_WE)
-
-  add_custom_command(TARGET "${LCMTYPES_DIR}/${lcmtype_we}.c" PRE_BUILD
-  		     COMMAND "${LCM_GEN_EXECUTABLE} --c --c-cpath ${LCMTYPES_DIR} -c-hpath ${LCMTYPES_DIR}"
-		     DEPENDS ${lcmtype})
+  get_package_name(${lcmtype})
+  if (_package_name)
+    string(REPLACE "." "_" package_prefix "${_package_name}")
+    set(package_prefix "${package_prefix}_")
+  endif()
+  set(lcmtype_w_package "${package_prefix}${lcmtype_we}")
+
+  add_custom_command(OUTPUT "${LCMTYPES_DIR}/${lcmtype_w_package}.c" PRE_LINK
+  		     COMMAND "${LCM_GEN_EXECUTABLE}" --c "${CMAKE_CURRENT_SOURCE_DIR}/${lcmtype}"
+		     DEPENDS ${lcmtype}
+		     WORKING_DIRECTORY ${LCMTYPES_DIR})
+  set(LCMTYPES_C_SOURCEFILES ${LCMTYPES_C_SOURCEFILES} "${LCMTYPES_DIR}/${lcmtype_w_package}.c" PARENT_SCOPE)
+
+endfunction()
+
+function(add_cpp_lcmtype lcmtype)
+  get_filename_component(lcmtype_we ${lcmtype} NAME_WE)
+  get_package_name(${lcmtype})
+  if (_package_name)
+    string(REPLACE "." "/" package_prefix "${_package_name}")
+    set(package_prefix "${package_prefix}/")
+  endif()
+  set(lcmtype_w_package "${package_prefix}${lcmtype_we}")
+
+  add_custom_command(OUTPUT "${LCMTYPES_DIR}/${lcmtype_w_package}.hpp" PRE_LINK
+  		     COMMAND "${LCM_GEN_EXECUTABLE}" --cpp "${CMAKE_CURRENT_SOURCE_DIR}/${lcmtype}"
+		     DEPENDS ${lcmtype}
+		     WORKING_DIRECTORY ${LCMTYPES_DIR})
+  set(LCMTYPES_CPP_HEADERFILES ${LCMTYPES_CPP_HEADERFILES} "${LCMTYPES_DIR}/${lcmtype_w_package}.hpp" PARENT_SCOPE)
+
+endfunction()
+
+function(add_java_lcmtype lcmtype)
+  get_filename_component(lcmtype_we ${lcmtype} NAME_WE)
+  get_package_name(${lcmtype})
+  if (_package_name)
+    string(REPLACE "." "/" package_prefix "${_package_name}")
+    set(package_prefix "${package_prefix}/")
+  endif()
+  set(lcmtype_w_package "${package_prefix}${lcmtype_we}")
+
+  add_custom_command(OUTPUT "${LCMTYPES_DIR}/${lcmtype_w_package}.java" PRE_LINK
+  		     COMMAND "${LCM_GEN_EXECUTABLE}" --java "${CMAKE_CURRENT_SOURCE_DIR}/${lcmtype}"
+		     DEPENDS ${lcmtype}
+		     WORKING_DIRECTORY ${LCMTYPES_DIR})
+  set(LCMTYPES_JAVA_SOURCEFILES ${LCMTYPES_JAVA_SOURCEFILES} "${LCMTYPES_DIR}/${lcmtype_w_package}.java" PARENT_SCOPE)
+
 endfunction()

 function(add_lcmtype)
   add_c_lcmtype(${ARGV})
-#  add_cpp_lcmtype(${ARGV})
-#  add_java_lcmtype(${ARGV})
+  set(LCMTYPES_C_SOURCEFILES ${LCMTYPES_C_SOURCEFILES} PARENT_SCOPE)
+
+  add_cpp_lcmtype(${ARGV})
+  set(LCMTYPES_CPP_HEADERFILES ${LCMTYPES_CPP_HEADERFILES} PARENT_SCOPE)
+
+  add_java_lcmtype(${ARGV})
+  set(LCMTYPES_JAVA_SOURCEFILES ${LCMTYPES_JAVA_SOURCEFILES} PARENT_SCOPE)
+
 #  add_python_lcmtype(${ARGV})
 endfunction()

-function(lcmtypes_build_c)
-    lcmtypes_get_types(_lcmtypes ${ARGV})
-    list(LENGTH _lcmtypes _num_lcmtypes)
-    if(_num_lcmtypes EQUAL 0)
-        return()
-    endif()
-
-    string(REGEX REPLACE "[^a-zA-Z0-9]" "_" __sanitized_project_name "${PROJECT_NAME}")
-
-    # set some defaults
-
-    # library name
-    set(libname "lcmtypes_${PROJECT_NAME}")
-
-    # header file that includes all other generated header files
-    set(agg_h_bname "${__sanitized_project_name}.h")
-
-    # allow defaults to be overriden by function parameters
-    set(modewords C_LIBNAME C_AGGREGATE_HEADER)
-    set(curmode "")
-    foreach(word ${ARGV})
-        list(FIND modewords ${word} mode_index)
-        if(${mode_index} GREATER -1)
-            set(curmode ${word})
-        elseif(curmode STREQUAL C_AGGREGATE_HEADER)
-            set(agg_h_bname "${word}")
-            set(curmode "")
-        elseif(curmode STREQUAL C_LIBNAME)
-            set(libname "${word}")
-            set(curmode "")
-        endif()
-    endforeach()
-
-    # generate C bindings for LCM types
-    set(_lcmtypes_c_dir ${PROJECT_SOURCE_DIR}/lcmtypes/c/lcmtypes)
-
-    # blow away any existing auto-generated files.
-    file(REMOVE_RECURSE ${_lcmtypes_c_dir})
-
-    # run lcm-gen now
-    execute_process(COMMAND mkdir -p ${_lcmtypes_c_dir})
-    lcmgen(--lazy -c --c-cpath ${_lcmtypes_c_dir} --c-hpath ${_lcmtypes_c_dir} --cinclude lcmtypes ${_lcmtypes})
-
-    # run lcm-gen at compile time
-    add_custom_target(lcmgen_c ALL
-        COMMAND sh -c '[ -d ${_lcmtypes_c_dir} ] || mkdir -p ${_lcmtypes_c_dir}'
-        COMMAND sh -c '${LCM_GEN_EXECUTABLE} --lazy -c --c-cpath ${_lcmtypes_c_dir} --c-hpath ${_lcmtypes_c_dir} --cinclude lcmtypes  ${_lcmtypes}')
-
-    # get a list of all generated .c and .h files
-    file(GLOB _lcmtypes_c_files ${_lcmtypes_c_dir}/*.c)
-    file(GLOB _lcmtypes_h_files ${_lcmtypes_c_dir}/*.h)
-
-    include_directories(BEFORE ${PROJECT_SOURCE_DIR}/lcmtypes/c) #TODO: don't think this is necessary
-    include_directories(${LCM_INCLUDE_DIRS})
-
-    # aggregate into a static library
-    add_library(${libname} STATIC ${_lcmtypes_c_files})
-    set_source_files_properties(${_lcmtypes_c_files} PROPERTIES COMPILE_FLAGS "-fPIC")
-    #    set_target_properties("${libname}-static" PROPERTIES OUTPUT_NAME "${libname}")
-    set_target_properties(${libname} PROPERTIES PREFIX "lib")
-    set_target_properties(${libname} PROPERTIES CLEAN_DIRECT_OUTPUT 1)
-    add_dependencies(${libname} lcmgen_c)
-
-    #    add_library("${libname}-static" STATIC ${_lcmtypes_c_files})
-    #    set_source_files_properties(${_lcmtypes_c_files} PROPERTIES COMPILE_FLAGS "-I${PROJECT_SOURCE_DIR}/lcmtypes/c")
-    #    set_target_properties("${libname}-static" PROPERTIES OUTPUT_NAME "${libname}")
-    #    set_target_properties("${libname}-static" PROPERTIES PREFIX "lib")
-    #    set_target_properties("${libname}-static" PROPERTIES CLEAN_DIRECT_OUTPUT 1)
-    #    add_dependencies("${libname}-static" lcmgen_c)
-
-    # XXX don't build a shared library, as it makes using 3rd-party/external
-    # LCM types awkward (linker will try to link external symbols at library link time,
-    # rather than executable link time)
-
-    #    # aggregate into a shared library
-    #    add_library(${libname} SHARED ${_lcmtypes_c_files})
-    #    set_target_properties("${libname}" PROPERTIES CLEAN_DIRECT_OUTPUT 1)
-    #    add_dependencies("${libname}" lcmgen_c)
-    #    target_link_libraries(${libname} ${LCM_LDFLAGS})
-
-    # create a header file aggregating all of the autogenerated .h files
-    set(__agg_h_fname "${_lcmtypes_c_dir}/${agg_h_bname}")
-    file(WRITE ${__agg_h_fname}
-        "#ifndef __lcmtypes_${__sanitized_project_name}_h__\n"
-        "#define __lcmtypes_${__sanitized_project_name}_h__\n\n")
-    foreach(h_file ${_lcmtypes_h_files})
-        file(RELATIVE_PATH __tmp_path ${_lcmtypes_c_dir} ${h_file})
-        file(APPEND ${__agg_h_fname} "#include \"${__tmp_path}\"\n")
-    endforeach()
-    file(APPEND ${__agg_h_fname} "\n#endif\n")
-    list(APPEND _lcmtypes_h_files ${__agg_h_fname})
-    unset(__sanitized_project_name)
-    unset(__agg_h_fname)
-
-    # make header files and libraries public
-    pods_install_libraries(${libname})
-    pods_install_headers(${_lcmtypes_h_files} DESTINATION lcmtypes)
-
-    # set some compilation variables
-    set(LCMTYPES_LIBS ${libname} PARENT_SCOPE)
-
-    # create a pkg-config file
-  	pods_install_pkg_config_file(${libname}
-    	CFLAGS
-    	DESCRIPTION "LCM types for ${PROJECT_NAME}"
-        LIBS -l${libname}
-    	REQUIRES lcm
-    	VERSION 0.0.0)
-
-    lcmtypes_add_clean_dir("${PROJECT_SOURCE_DIR}/lcmtypes/c")
-endfunction()
-
-function(lcmtypes_build_cpp)
-    lcmtypes_get_types(_lcmtypes ${ARGV})
-    list(LENGTH _lcmtypes _num_lcmtypes)
-    if(_num_lcmtypes EQUAL 0)
-        return()
-    endif()
-
-    string(REGEX REPLACE "[^a-zA-Z0-9]" "_" __sanitized_project_name "${PROJECT_NAME}")
-
-    # set some defaults
-
-    # header file that includes all other generated header files
-    set(agg_hpp_bname "${__sanitized_project_name}.hpp")
-
-    # allow defaults to be overriden by function parameters
-    set(modewords CPP_AGGREGATE_HEADER)
-    set(curmode "")
-    foreach(word ${ARGV})
-        list(FIND modewords ${word} mode_index)
-        if(${mode_index} GREATER -1)
-            set(curmode ${word})
-        elseif(curmode STREQUAL CPP_AGGREGATE_HEADER)
-            set(agg_hpp_bname "${word}")
-            set(curmode "")
-        endif()
-    endforeach()
-
-    # generate CPP bindings for LCM types
-    set(_lcmtypes_cpp_dir ${PROJECT_SOURCE_DIR}/lcmtypes/cpp/lcmtypes)
-
-    # blow away any existing auto-generated files.
-    file(REMOVE_RECURSE ${_lcmtypes_cpp_dir})
-
-    # run lcm-gen now
-    execute_process(COMMAND mkdir -p ${_lcmtypes_cpp_dir})
-    lcmgen(--lazy --cpp --cpp-hpath ${_lcmtypes_cpp_dir} --cpp-include lcmtypes ${_lcmtypes})
-
-    # run lcm-gen at compile time
-    add_custom_target(lcmgen_cpp ALL
-        COMMAND sh -c '[ -d ${_lcmtypes_cpp_dir} ] || mkdir -p ${_lcmtypes_cpp_dir}'
-        COMMAND sh -c '${LCM_GEN_EXECUTABLE} --lazy --cpp  --cpp-hpath ${_lcmtypes_cpp_dir} --cpp-include lcmtypes ${_lcmtypes}')
-
-    # get a list of all generated .hpp files
-    file(GLOB_RECURSE _lcmtypes_hpp_files  ${_lcmtypes_cpp_dir}/*.hpp)
-
-    include_directories(BEFORE ${PROJECT_SOURCE_DIR}/lcmtypes/cpp) #TODO: don't think this is necessary
-    include_directories(${LCM_INCLUDE_DIRS})
-
-    # create a header file aggregating all of the autogenerated .hpp files
-    set(__agg_hpp_fname "${_lcmtypes_cpp_dir}/${agg_hpp_bname}")
-    file(WRITE ${__agg_hpp_fname}
-        "#ifndef __lcmtypes_${__sanitized_project_name}_hpp__\n"
-        "#define __lcmtypes_${__sanitized_project_name}_hpp__\n\n")
-    foreach(hpp_file ${_lcmtypes_hpp_files})
-        file(RELATIVE_PATH __tmp_path ${_lcmtypes_cpp_dir} ${hpp_file})
-        file(APPEND ${__agg_hpp_fname} "#include \"${__tmp_path}\"\n")
-        get_filename_component(__tmp_dir ${__tmp_path} PATH)
-        pods_install_headers(${hpp_file} DESTINATION lcmtypes/${__tmp_dir})
-    endforeach()
-    file(APPEND ${__agg_hpp_fname} "\n#endif\n")
-    pods_install_headers(${__agg_hpp_fname} DESTINATION lcmtypes)
-    unset(__sanitized_project_name)
-    unset(__agg_hpp_fname)
-
-
-
-    lcmtypes_add_clean_dir("${PROJECT_SOURCE_DIR}/lcmtypes/cpp")
-endfunction()
-
-function(lcmtypes_build_java)
-    lcmtypes_get_types(_lcmtypes ${ARGV})
-    list(LENGTH _lcmtypes _num_lcmtypes)
-    if(_num_lcmtypes EQUAL 0)
-        return()
-    endif()
-
-    # do we have Java?
-    find_package(Java)
-    if(JAVA_COMPILE STREQUAL JAVA_COMPILE-NOTFOUND OR
-       JAVA_ARCHIVE STREQUAL JAVA_ARCHIVE-NOTFOUND)
-        message(STATUS "Not building Java LCM type bindings (Can't find Java)")
-        return()
-    endif()
-
-    # do we have LCM java bindings?  where is lcm.jar?
-    execute_process(COMMAND pkg-config --variable=classpath lcm-java OUTPUT_VARIABLE LCM_JAR_FILE)
-    if(NOT LCM_JAR_FILE)
-        message(STATUS "Not building Java LCM type bindings (Can't find lcm.jar)")
-        return()
-    endif()
-    string(STRIP ${LCM_JAR_FILE} LCM_JAR_FILE)
-    set(LCMTYPES_JAR ${CMAKE_CURRENT_BINARY_DIR}/lcmtypes_${PROJECT_NAME}.jar)
-
-    # generate Java bindings for LCM types
-    set(_lcmtypes_java_dir ${PROJECT_SOURCE_DIR}/lcmtypes/java)
-    set(auto_manage_files YES)
-
-    set(modewords JAVA_DEST_DIR)
-    set(curmode "")
-    foreach(word ${ARGV})
-        list(FIND modewords ${word} mode_index)
-        if(${mode_index} GREATER -1)
-            set(curmode ${word})
-        elseif(curmode STREQUAL JAVA_DEST_DIR)
-            set(_lcmtypes_java_dir "${word}")
-            set(auto_manage_files NO)
-            set(curmode "")
-        endif()
-    endforeach()
-
-    # blow away any existing auto-generated files?
-    if(auto_manage_files)
-        file(REMOVE_RECURSE ${_lcmtypes_java_dir})
-    endif()
-
-    # run lcm-gen now
-    execute_process(COMMAND mkdir -p ${_lcmtypes_java_dir})
-    lcmgen(--lazy -j ${_lcmtypes} --jpath ${_lcmtypes_java_dir})
-
-    # run lcm-gen at compile time
-    add_custom_target(lcmgen_java ALL
-        COMMAND sh -c '[ -d ${_lcmtypes_java_dir} ] || mkdir -p ${_lcmtypes_java_dir}'
-        COMMAND sh -c '${LCM_GEN_EXECUTABLE} --lazy -j ${_lcmtypes} --jpath ${_lcmtypes_java_dir}')
-
-    if(NOT auto_manage_files)
-        return()
-    endif()
-
-    # get a list of all generated .java files
-    file(GLOB_RECURSE _lcmtypes_java_files ${_lcmtypes_java_dir}/*.java)
-
-    set(java_classpath ${_lcmtypes_java_dir}:${LCM_JAR_FILE})
-
-    # search for lcmtypes_*.jar files in well-known places and add them to the
-    # classpath
-    foreach(pfx ${CMAKE_INSTALL_PREFIX} /usr /usr/local)
-        file(GLOB_RECURSE jarfiles ${pfx}/share/java/lcmtypes_*.jar)
-        foreach(jarfile ${jarfiles})
-            set(java_classpath ${java_classpath}:${jarfile})
-            #            message("found ${jarfile}")
-        endforeach()
-    endforeach()
-
-    # convert the list of .java filenames to a list of .class filenames
-    foreach(javafile ${_lcmtypes_java_files})
-        string(REPLACE .java .class __tmp_class_fname ${javafile})
-        #        add_custom_command(OUTPUT ${__tmp_class_fname} COMMAND
-        #            ${JAVA_COMPILE} -source 6 -target 6 -cp ${_lcmtypes_java_dir}:${lcm_jar} ${javafile} VERBATIM DEPENDS ${javafile})
-        list(APPEND _lcmtypes_class_files ${__tmp_class_fname})
-        unset(__tmp_class_fname)
-    endforeach()
-
-    # add a rule to build the .class files from from the .java files
-    add_custom_command(OUTPUT ${_lcmtypes_class_files} COMMAND
-        ${JAVA_COMPILE} -source 6 -target 6 -cp ${java_classpath} ${_lcmtypes_java_files}
-        DEPENDS ${_lcmtypes_java_files} VERBATIM)
-
-    # add a rule to build a .jar file from the .class files
-    add_custom_command(OUTPUT lcmtypes_${PROJECT_NAME}.jar COMMAND
-        ${JAVA_ARCHIVE} cf ${LCMTYPES_JAR} -C ${_lcmtypes_java_dir} . DEPENDS ${_lcmtypes_class_files} VERBATIM)
-    add_custom_target(lcmtypes_${PROJECT_NAME}_jar ALL DEPENDS ${LCMTYPES_JAR})
-
-    add_dependencies(lcmtypes_${PROJECT_NAME}_jar lcmgen_java)
-
-    install(FILES ${LCMTYPES_JAR} DESTINATION share/java)
-    set(LCMTYPES_JAR ${LCMTYPES_JAR} PARENT_SCOPE)
-
-    pods_install_pkg_config_file(lcmtypes_${PROJECT_NAME}-java
-    	CLASSPATH lcmtypes_${PROJECT_NAME}
-    	DESCRIPTION "LCM type java bindings for ${PROJECT_NAME}"
-    	REQUIRES lcm-java
-    	VERSION 0.0.0)
-
-    lcmtypes_add_clean_dir(${_lcmtypes_java_dir})
-endfunction()
-
-function(lcmtypes_build_python)
-    lcmtypes_get_types(_lcmtypes ${ARGV})
-    list(LENGTH _lcmtypes _num_lcmtypes)
-    if(_num_lcmtypes EQUAL 0)
-        return()
-    endif()
-
-    find_package(PythonInterp)
-    if(NOT PYTHONINTERP_FOUND)
-        message(STATUS "Not building Python LCM type bindings (Can't find Python)")
-        return()
-    endif()
-
-    set(_lcmtypes_python_dir ${PROJECT_SOURCE_DIR}/lcmtypes/python)
-    set(auto_manage_files YES)
-
-    set(modewords PY_DEST_DIR)
-    set(curmode "")
-    foreach(word ${ARGV})
-        list(FIND modewords ${word} mode_index)
-        if(${mode_index} GREATER -1)
-            set(curmode ${word})
-        elseif(curmode STREQUAL PY_DEST_DIR)
-            set(_lcmtypes_python_dir "${word}")
-            set(auto_manage_files NO)
-            set(curmode "")
-        endif()
-    endforeach()
-
-    # purge existing files?
-    if(auto_manage_files)
-        file(REMOVE_RECURSE ${_lcmtypes_python_dir})
-    endif()
-
-    # generate Python bindings for LCM types
-    execute_process(COMMAND mkdir -p ${_lcmtypes_python_dir})
-    execute_process(COMMAND ${LCM_GEN_EXECUTABLE} --lazy -p ${_lcmtypes} --ppath ${_lcmtypes_python_dir})
-
-    # run lcm-gen at compile time
-    add_custom_target(lcmgen_python ALL
-        COMMAND sh -c '${LCM_GEN_EXECUTABLE} --lazy -p ${_lcmtypes} --ppath ${_lcmtypes_python_dir}')
-
-    if(NOT auto_manage_files)
-        return()
-    endif()
-
-    pods_install_python_packages(${_lcmtypes_python_dir})
-
-    lcmtypes_add_clean_dir(${_lcmtypes_python_dir})
-endfunction()
-
-function(lcmtypes_install_types)
-    lcmtypes_get_types(_lcmtypes ${ARGV})
-    list(LENGTH _lcmtypes _num_lcmtypes)
-    if(_num_lcmtypes EQUAL 0)
-        return()
-    endif()
-
-    install(FILES ${_lcmtypes} DESTINATION share/lcmtypes)
-endfunction()
-
-macro(lcmtypes_build)
-    lcmtypes_build_c(${ARGV})
-    lcmtypes_build_cpp(${ARGV})
-
-    lcmtypes_build_java(${ARGV})
-    lcmtypes_build_python(${ARGV})
-    lcmtypes_install_types(${ARGV})
-endmacro()


Fix Windows build to not force enable /MT, it is not need for BUILDSTATIC. (#1702)

--- src/cmake/compiler.cmake
+++ src/cmake/compiler.cmake
@@ -307,10 +307,6 @@
         set (USE_PYTHON OFF)
         set (USE_PYTHON3 OFF)
     endif ()
-    if (WIN32)
-        set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /MT")
-        set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /MTd")
-    endif ()
 else ()
     set (LIBRARY_BUILD_TYPE SHARED)
 endif()
@@ -335,4 +331,8 @@

 if (DEFINED ENV{TRAVIS} OR DEFINED ENV{APPVEYOR} OR DEFINED ENV{CI})
     add_definitions ("-D${PROJ_NAME}_CI=1" "-DBUILD_CI=1")
-endif ()
+    if (WIN32)
+        set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /MT")
+        set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /MTd")
+    endif ()
+endif ()


Allow some tests to be skipped

Allow some tests to be skipped

--- tests/system_tests/run_system_tests.sh.cmake
+++ tests/system_tests/run_system_tests.sh.cmake
@@ -42,12 +42,16 @@
 NUM_ALL_TESTS=0
 NUM_SUCCESS_TRANS=0
 NUM_FAIL_TRANS=0
+NUM_SKIPPED_TRANS=0
 NUM_SUCCESS_COMPILE=0
 NUM_FAIL_COMPILE=0
+NUM_SKIPPED_COMPILE=0
 NUM_SUCCESS_EXECUTE=0
 NUM_FAIL_EXECUTE=0
+NUM_SKIPPED_EXECUTE=0
 NUM_WARNING=0
 FAILED_TESTS=""
+SKIPPED_TESTS=""

 PHYSISC=@CMAKE_BINARY_DIR@/translator/physisc
 MPIRUN=mpirun
@@ -102,9 +106,9 @@

 function print_results_short()
 {
-    echo  -n "[TRANSLATE] $NUM_SUCCESS_TRANS/$NUM_FAIL_TRANS/$NUM_ALL_TESTS"
-    echo  -n ", [COMPILE] $NUM_SUCCESS_COMPILE/$NUM_FAIL_COMPILE/$NUM_ALL_TESTS"
-    echo  ", [EXECUTE] $NUM_SUCCESS_EXECUTE/$NUM_FAIL_EXECUTE/$NUM_ALL_TESTS."
+    echo  -n "[TRANSLATE] $NUM_SUCCESS_TRANS/$NUM_FAIL_TRANS/$NUM_SKIPPED_TRANS/$NUM_ALL_TESTS"
+    echo  -n ", [COMPILE] $NUM_SUCCESS_COMPILE/$NUM_FAIL_COMPILE/$NUM_SKIPPED_COMPILE/$NUM_ALL_TESTS"
+    echo  ", [EXECUTE] $NUM_SUCCESS_EXECUTE/$NUM_FAIL_EXECUTE/$NUM_SKIPPED_EXECUTE/$NUM_ALL_TESTS."
 }

 function email_results()
@@ -125,13 +129,17 @@
 function print_results()
 {
 	local msg=""
-	msg+="[TRANSLATE] $NUM_SUCCESS_TRANS/$NUM_FAIL_TRANS/$NUM_ALL_TESTS."
-	msg+="\n[COMPILE]   $NUM_SUCCESS_COMPILE/$NUM_FAIL_COMPILE/$NUM_ALL_TESTS."
-	msg+="\n[EXECUTE]   $NUM_SUCCESS_EXECUTE/$NUM_FAIL_EXECUTE/$NUM_ALL_TESTS."
+	msg+="[TRANSLATE] $NUM_SUCCESS_TRANS/$NUM_FAIL_TRANS/$NUM_SKIPPED_TRANS/$NUM_ALL_TESTS."
+	msg+="\n[COMPILE]   $NUM_SUCCESS_COMPILE/$NUM_FAIL_COMPILE/$NUM_SKIPPED_COMPILE/$NUM_ALL_TESTS."
+	msg+="\n[EXECUTE]   $NUM_SUCCESS_EXECUTE/$NUM_FAIL_EXECUTE/$NUM_SKIPPED_EXECUTE/$NUM_ALL_TESTS."
 	msg+="\n"
 	if [ "x" != "x$FAILED_TESTS" ]; then
 		msg+="\n!!! $(echo "$FAILED_TESTS" | wc -w) failure(s)!!!"
 		msg+="\nFailed tests: $FAILED_TESTS"
+	elif [ $NUM_SKIPPED_TRANS -gt 0 -o $NUM_SKIPPED_COMPILE -gt 0 \
+							  -o $NUM_SKIPPED_EXECUTE -gt 0 ]; then
+		msg+="\nCompleted successfully with some tests skipped."
+		msg+="\nSkipped tests: $SKIPPED_TESTS"
 	else
 		msg+="\nAll tests completed successfully."
 	fi
@@ -1363,7 +1371,16 @@
 			SHORTNAME=$(basename $TEST)
 			if is_skipped_module_test $TEST $TARGET; then
 				echo "Skipping $SHORTNAME for $TARGET target"
+				inc NUM_SKIPPED_TRANS
+				SKIPPED_TESTS="$SKIPPED_TESTS $SHORTNAME"
 				continue;
+			fi
+			echo $SHORTNAME
+			if [ $TARGET = mpi -a $SHORTNAME = test_cplusplus.cc ] ; then
+				echo "Translation of C++ not supported in MPI"
+				inc NUM_SKIPPED_TRANS
+				SKIPPED_TESTS="$SKIPPED_TESTS $SHORTNAME"
+				continue
 			fi
 			DIM=$(grep -o '\WDIM: .*$' $TEST | sed 's/\WDIM: \(.*\)$/\1/')
 			if [ "$CONFIG_ARG" != "" ]; then


updated sl-ext-libs.cmake

updated sl-ext-libs.cmake

--- cmake-modules/sl-ext-libs.cmake
+++ cmake-modules/sl-ext-libs.cmake
@@ -1,4 +1,4 @@
-
+4
         ##########    Copyright (C) 2015 Vincenzo Pacella
         ##      ##    Distributed under MIT license, see file LICENSE
         ##      ##    or <http://opensource.org/licenses/MIT>
@@ -14,7 +14,7 @@
   if(DEFINED RTMIDI_INCLUDE_DIRS)
     message(STATUS "RtMidi is already available")
   else()
-    checkout_external_project(rtmidi https://github.com/thestk/rtmidi.git master)
+    checkout_external_project(rtmidi https://github.com/thestk/rtmidi.git a8d1414acb968d06d975a9b17c8d97a476f1e5c0)
     set(RTMIDI_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/rtmidi/src/rtmidi PARENT_SCOPE)
     set(RTMIDI_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/rtmidi/src/rtmidi)
     message(STATUS "RtMidi path: ${RTMIDI_INCLUDE_DIRS}")
@@ -29,18 +29,6 @@
     if(APPLE)
       target_link_libraries(rtmidi PUBLIC "-framework CoreFoundation" "-framework IOKit")
       target_link_libraries(rtmidi PUBLIC "-framework CoreAudio" "-framework CoreMidi" objc)
-      set_target_properties(
-        rtmidi
-        PROPERTIES
-          COMPILE_DEFINITIONS __MACOSX_CORE__
-      )
-    elseif(WIN32)
-      target_link_libraries(rtmidi PUBLIC winmm.lib)
-      set_target_properties(
-        rtmidi
-        PROPERTIES
-          COMPILE_DEFINITIONS __WINDOWS_MM__
-      )
     endif()

     set_target_properties(
@@ -49,6 +37,14 @@
         OUTPUT_NAME         "rtmidi"
         OUTPUT_NAME_DEBUG   "rtmidi${DEBUG_SUFFIX}"
     )
+
+    if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
+    set_target_properties(
+      rtmidi
+      PROPERTIES
+        COMPILE_DEFINITIONS __MACOSX_CORE__
+    )
+    endif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
   endif()
 endfunction()

@@ -60,7 +56,7 @@
   if(DEFINED CATCH_INCLUDE_DIRS)
     message(STATUS "Catch is already available")
   else()
-    checkout_external_project(catch https://github.com/philsquared/Catch.git master)
+    checkout_external_project(catch https://github.com/philsquared/Catch.git 35f510545d55a831372d3113747bf1314ff4f2ef)
     set(CATCH_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/catch/src/catch/include PARENT_SCOPE)
     set(CATCH_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/catch/src/catch/include)
     message(STATUS "Catch path: ${CATCH_INCLUDE_DIRS}")
@@ -105,7 +101,7 @@
   if(DEFINED LIBUSB_INCLUDE_DIRS)
     message(STATUS "libUSB is already available")
   else()
-    checkout_external_project(libusb https://github.com/libusb/libusb.git master)
+    checkout_external_project(libusb https://github.com/libusb/libusb.git v1.0.21-rc2)
     set(LIBUSB_BASE_DIR ${CMAKE_BINARY_DIR}/libusb/src/libusb/)
     set(LIBUSB_INCLUDE_DIRS ${LIBUSB_BASE_DIR}/libusb ${LIBUSB_BASE_DIR}/libusb/os PARENT_SCOPE)
     set(LIBUSB_INCLUDE_DIRS ${LIBUSB_BASE_DIR}/libusb ${LIBUSB_BASE_DIR}/libusb/os)
@@ -165,11 +161,10 @@
         OUTPUT_NAME_DEBUG   "libusb${DEBUG_SUFFIX}"
     )

-    target_include_directories(libusb PUBLIC ${LIBUSB_INCLUDE_DIRS})
     if(${CMAKE_SYSTEM_NAME} MATCHES "Windows")
-      target_include_directories(libusb PRIVATE ${LIBUSB_BASE_DIR}/msvc)
+      target_include_directories(libusb PUBLIC ${LIBUSB_INCLUDE_DIRS} ${LIBUSB_BASE_DIR}/msvc)
     elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
-      target_include_directories(libusb PRIVATE ${LIBUSB_BASE_DIR}/Xcode)
+      target_include_directories(libusb PUBLIC ${LIBUSB_INCLUDE_DIRS} ${LIBUSB_BASE_DIR}/Xcode)
     endif()

   endif()
@@ -182,7 +177,7 @@
   if(DEFINED HIDAPI_INCLUDE_DIRS)
     message(STATUS "HIDAPI is already available: ${HIDAPI_INCLUDE_DIRS}")
   else()
-    checkout_external_project(hidapi https://github.com/signal11/hidapi.git master)
+    checkout_external_project(hidapi https://github.com/signal11/hidapi.git b5b2e1779b6cd2edda3066bbbf0921a2d6b1c3c0)
     set(HIDAPI_BASE_DIR ${CMAKE_BINARY_DIR}/hidapi/src/hidapi/)
     set(HIDAPI_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/hidapi/src/hidapi/hidapi PARENT_SCOPE)
     set(HIDAPI_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/hidapi/src/hidapi/hidapi)


cmake: fix static_crt flags for vs2017

cmake: fix static_crt flags for vs2017

--- cmake/MbedcryptoPlatforms.cmake
+++ cmake/MbedcryptoPlatforms.cmake
@@ -46,10 +46,6 @@
             string(REGEX REPLACE ${_src_opt} ${_dst_opt} ${flag} "${${flag}}")
             set(${flag} "${${flag}}" CACHE STRING "msvc flags" FORCE)
         endforeach()
-        target_compile_options(${tgt} PUBLIC
-            "$<$<CONFIG:Release>:${_src_opt}>"
-            "$<$<CONFIG:Debug>:${_dst_opt}d>"
-            )
     endif()
 endmacro()


Fixed sidefx namespaced libs not being picked up in houdini builds

Signed-off-by: Nick Avramoussis <4c6772d20f21e1f087b814400acc0120202ec49e@dneg.com>

--- cmake/OpenVDBHoudiniSetup.cmake
+++ cmake/OpenVDBHoudiniSetup.cmake
@@ -311,6 +311,15 @@
 UNSET ( _HOUDINI_INCLUDE_DIR )
 UNSET ( _HOUDINI_LIB_DIR )

+# Versions of Houdini >= 17.5 have some namespaced libraries (IlmBase/OpenEXR).
+# Add the required suffix as part of the cmake lib suffix searches
+
+IF ( APPLE )
+  LIST ( APPEND CMAKE_FIND_LIBRARY_SUFFIXES "_sidefx.dylib" )
+ELSEIF ( UNIX )
+  LIST ( APPEND CMAKE_FIND_LIBRARY_SUFFIXES "_sidefx.so" )
+ENDIF ()
+
 # ------------------------------------------------------------------------
 #  Configure OpenVDB ABI
 # ------------------------------------------------------------------------


Rename variables

Rename variables

--- cmake/modules/hunter_wiki.cmake
+++ cmake/modules/hunter_wiki.cmake
@@ -2,12 +2,12 @@
 # All rights reserved.

 # Do not move to master - build schemes use this module but they not use master
-set(HUNTER_WIKI "https://docs.hunter.sh/en/latest/reference/errors")
+set(HUNTER_ERROR_PAGE "https://docs.hunter.sh/en/latest/reference/errors")

-function(hunter_wiki wiki_page)
-  message("------------------------------ WIKI -------------------------------")
-  message("    ${HUNTER_WIKI}/${wiki_page}.html")
-  message("-------------------------------------------------------------------")
+function(hunter_wiki error_page)
+  message("------------------------------ ERROR -----------------------------")
+  message("    ${HUNTER_ERROR_PAGE}/${error_page}.html")
+  message("------------------------------------------------------------------")
   message("")
   message(FATAL_ERROR "")
 endfunction()


print cmake variables

print cmake variables

--- cmake/DetectOpenCV.cmake
+++ cmake/DetectOpenCV.cmake
@@ -69,6 +69,7 @@
     message(STATUS "OpenCV_NUM_LIBS=${OpenCV_NUM_LIBS}")
     message(STATUS "OpenCV_LIBS=${OpenCV_LIBS}")
     message(STATUS "OpenCV_Libs=${OpenCV_Libs}")
+    message(STATUS "OpenCV_LIBRARIES=${OpenCV_LIBRARIES}")
     list(APPEND ${ROOT_PROJECT}_LIBS ${OpenCV_LIBS} ${OpenCV_LIBRARIES})

     # Define OpenCV_LIBRARY_DIR if missing


Use format_code script in cmake 'format' target

--- cmake/clang-format.cmake
+++ cmake/clang-format.cmake
@@ -1,7 +1,9 @@
 include_guard()
+
+set(FORMAT_SCRIPT ${CMAKE_SOURCE_DIR}/scripts/format_code)

 add_custom_target(
     format
-    COMMAND find src tests -type f '\(' -iname *.h -o -iname *.hpp -o -iname *.c -o -iname *.cpp '\)' | xargs clang-format -style=file -i
-    WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
+    COMMAND ${FORMAT_SCRIPT} "${CMAKE_SOURCE_DIR}/src" "${CMAKE_SOURCE_DIR}/tests"
+    VERBATIM
 )


CMake: Define project EXPORTS for all systems

--- cmake/globalmacros.cmake
+++ cmake/globalmacros.cmake
@@ -670,28 +670,29 @@
 macro(ivw_define_standard_definitions project_name)
     #--------------------------------------------------------------------
     # Set the compiler flags
-   string(TOUPPER ${project_name} u_project_name)
-    if(WIN32)
-      add_definitions(-D${u_project_name}_EXPORTS)
-	  add_definitions(-DGLM_EXPORTS)
-
-    #--------------------------------------------------------------------
-    # Large memory support
-    if(CMAKE_SIZEOF_VOID_P MATCHES 4)
-        if(NOT CMAKE_EXE_LINKER_FLAGS MATCHES "/LARGEADDRESSAWARE")
-          set( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /LARGEADDRESSAWARE ")
-        endif()
-        if(NOT CMAKE_SHARED_LINKER_FLAGS MATCHES "/LARGEADDRESSAWARE")
-          set( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /LARGEADDRESSAWARE")
-        endif()
-        if(NOT CMAKE_MODULE_LINKER_FLAGS MATCHES "/LARGEADDRESSAWARE")
-          set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} /LARGEADDRESSAWARE")
-        endif()
-    endif()
+    string(TOUPPER ${project_name} u_project_name)
+    add_definitions(-D${u_project_name}_EXPORTS)
+    add_definitions(-DGLM_EXPORTS)
+
+    if(WIN32)
+	    #--------------------------------------------------------------------
+	    # Large memory support
+	    if(CMAKE_SIZEOF_VOID_P MATCHES 4)
+	        if(NOT CMAKE_EXE_LINKER_FLAGS MATCHES "/LARGEADDRESSAWARE")
+	          set( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /LARGEADDRESSAWARE ")
+	        endif()
+	        if(NOT CMAKE_SHARED_LINKER_FLAGS MATCHES "/LARGEADDRESSAWARE")
+	          set( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /LARGEADDRESSAWARE")
+	        endif()
+	        if(NOT CMAKE_MODULE_LINKER_FLAGS MATCHES "/LARGEADDRESSAWARE")
+	          set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} /LARGEADDRESSAWARE")
+	        endif()
+	    endif()

     else(WIN32)
-      add_definitions(-DHAVE_CONFIG_H)
+    	add_definitions(-DHAVE_CONFIG_H)
     endif(WIN32)
+
     add_definitions(-DUNICODE)
     add_definitions(-D_CRT_SECURE_NO_WARNINGS -D_CRT_SECURE_NO_DEPRECATE)

@@ -702,7 +703,7 @@
 # Define QT defintions
 macro(ivw_define_qt_definitions)
 	add_definitions(-DQT_CORE_LIB
-                      -DQT_GUI_LIB)
+                    -DQT_GUI_LIB)
 endmacro()

 #--------------------------------------------------------------------


Added documentation to sot-core

Added documentation to sot-core


updated FindHIDAPI.cmake

updated FindHIDAPI.cmake

--- cmake-modules/FindHIDAPI.cmake
+++ cmake-modules/FindHIDAPI.cmake
@@ -2,6 +2,7 @@
 find_path(
   HIDAPI_INCLUDE_DIRS hidapi.h
   PATH_SUFFIXES hidapi
+  HINTS /tmp/hidapi-master/hidapi # for travis-ci linux build
 )

 if(NOT WIN32)


Hide new API from older versions of CMake.

--- cmake/FindPython/Support.cmake
+++ cmake/FindPython/Support.cmake
@@ -2965,12 +2965,19 @@
 endforeach()

 include (FindPackageHandleStandardArgs)
-find_package_handle_standard_args (${_PYTHON_PREFIX}
-                                   REQUIRED_VARS ${_${_PYTHON_PREFIX}_REQUIRED_VARS}
-                                   VERSION_VAR ${_PYTHON_PREFIX}_VERSION
-                                   HANDLE_COMPONENTS
-                                   REASON_FAILURE_MESSAGE "${_${_PYTHON_PREFIX}_REASON_FAILURE}")
-
+if (CMAKE_VERSION LESS 3.16)
+  find_package_handle_standard_args (${_PYTHON_PREFIX}
+                                     REQUIRED_VARS ${_${_PYTHON_PREFIX}_REQUIRED_VARS}
+                                     VERSION_VAR ${_PYTHON_PREFIX}_VERSION
+                                     HANDLE_COMPONENTS
+                                     FAIL_MESSAGE "${_${_PYTHON_PREFIX}_REASON_FAILURE}")
+else()
+  find_package_handle_standard_args (${_PYTHON_PREFIX}
+                                     REQUIRED_VARS ${_${_PYTHON_PREFIX}_REQUIRED_VARS}
+                                     VERSION_VAR ${_PYTHON_PREFIX}_VERSION
+                                     HANDLE_COMPONENTS
+                                     REASON_FAILURE_MESSAGE "${_${_PYTHON_PREFIX}_REASON_FAILURE}")
+endif()
 # Create imported targets and helper functions
 if(_${_PYTHON_PREFIX}_CMAKE_ROLE STREQUAL "PROJECT")
   if ("Interpreter" IN_LIST ${_PYTHON_PREFIX}_FIND_COMPONENTS


revert changes

revert changes

--- cmake/get-version-config.cmake
+++ cmake/get-version-config.cmake
@@ -13,9 +13,9 @@
 		OUTPUT_VARIABLE VERSION
 		OUTPUT_STRIP_TRAILING_WHITESPACE
 	)
-
+
 	string(REGEX REPLACE "^([0-9]+)\\.[0-9]+\\.[0-9]+" "\\1" VERSION_MAJOR "${VERSION}")
 	string(REGEX REPLACE "^[0-9]+\\.([0-9])+\\.[0-9]+" "\\1" VERSION_MINOR "${VERSION}")
 	string(REGEX REPLACE "^[0-9]+\\.[0-9]+\\.([0-9]+)" "\\1" VERSION_PATCH "${VERSION}")
-
+
 endmacro(get_version)


Fail on missing system configuration variables

Design the Python commands to check for the needed system configuration
variables such that they error out if a variable is not available. This
differs from the previous behavior where they returned `None` instead.
Making this change guarantees we are able to detect missing system
configuration variables.

--- cmake/modules/FindPYTHON.cmake
+++ cmake/modules/FindPYTHON.cmake
@@ -37,7 +37,7 @@
     ENDIF()
     IF(NOT PYTHON_LIBRARY_DIR)
         execute_process ( COMMAND ${PYTHON_EXECUTABLE} -c
-                            "from distutils import sysconfig; print(sysconfig.get_config_var(\"LIBDIR\"))"
+                            "from distutils import sysconfig; print(sysconfig.get_config_vars()[\"LIBDIR\"])"
                             RESULT_VARIABLE PYTHON_LIBRARY_DIR_NOT_FOUND
                             OUTPUT_VARIABLE PYTHON_LIBRARY_DIR
                             OUTPUT_STRIP_TRAILING_WHITESPACE)
@@ -73,7 +73,7 @@
     ENDIF()
     IF(NOT PYTHON_LIBRARY_DIR_NOT_FOUND AND NOT PYTHON_VERSION_NOT_FOUND)
         execute_process ( COMMAND ${PYTHON_EXECUTABLE} -c
-		            "from distutils import sysconfig; print(sysconfig.get_config_var(\"LDLIBRARY\"))"
+                            "from distutils import sysconfig; print(sysconfig.get_config_vars()[\"LDLIBRARY\"])"
                             RESULT_VARIABLE PYTHON_LIBRARY_NAME_NOT_FOUND
                             OUTPUT_VARIABLE PYTHON_LIBRARY_NAME
                             OUTPUT_STRIP_TRAILING_WHITESPACE)


Add include directory for libxml on macOS

Summary:
Builds fail because libxml/xmlreader.h isn't found. Adding the include
directory to the include list fixes the issue. This is what we already do on
non-macOS platforms in the same file.

Reviewers: clayborg, xiaobai, lanza

Reviewed By: clayborg, lanza

Subscribers: mgorny

Differential Revision: https://reviews.llvm.org/D50918

git-svn-id: 4c4cc70b1ef44ba2b7963015e681894188cea27e@340460 91177308-0d34-0410-b5e6-96231b3b80d8

--- cmake/modules/LLDBConfig.cmake
+++ cmake/modules/LLDBConfig.cmake
@@ -336,14 +336,13 @@
        ${CORE_SERVICES_LIBRARY}
        ${SECURITY_LIBRARY}
        ${DEBUG_SYMBOLS_LIBRARY})
-
+  include_directories(${LIBXML2_INCLUDE_DIR})
 else()
   if (LIBXML2_FOUND)
     add_definitions( -DLIBXML2_DEFINED )
     list(APPEND system_libs ${LIBXML2_LIBRARIES})
     include_directories(${LIBXML2_INCLUDE_DIR})
   endif()
-
 endif()

 if( WIN32 AND NOT CYGWIN )


Import upstream change to fix build with cmake 3.9

Summary:
This imports d9354dfe "CMake/TpQtMacros: Added missing dependencies."
from https://github.com/TelepathyIM/telepathy-qt. It fixes a build error
with cmake 3.9. Otherwise it fails with "IOError: [Errno 2] No such
file or directory: '<buildir>/TelepathyLoggerQt/_gen/spec-logger.xml'".

Test Plan: Builds fine with cmake 3.9

Reviewers: #kde_telepathy

Differential Revision: https://phabricator.kde.org/D7352

--- cmake/modules/TpQtMacros.cmake
+++ cmake/modules/TpQtMacros.cmake
@@ -223,7 +223,9 @@
         WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}

         DEPENDS ${CMAKE_SOURCE_DIR}/tools/libqtcodegen.py
-                ${CMAKE_SOURCE_DIR}/tools/qt-client-gen.py)
+                ${CMAKE_SOURCE_DIR}/tools/qt-client-gen.py
+                ${CMAKE_CURRENT_BINARY_DIR}/_gen/stable-spec.xml
+                ${CMAKE_CURRENT_BINARY_DIR}/_gen/spec-${spec}.xml)
     add_custom_target(generate_cli-${spec}-body DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/_gen/cli-${spec}-body.hpp)
     add_dependencies(all-generated-sources generate_cli-${spec}-body)

@@ -259,7 +261,9 @@
         WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}

         DEPENDS ${CMAKE_SOURCE_DIR}/tools/libqtcodegen.py
-                ${CMAKE_SOURCE_DIR}/tools/qt-client-gen.py)
+                ${CMAKE_SOURCE_DIR}/tools/qt-client-gen.py
+                ${CMAKE_CURRENT_BINARY_DIR}/_gen/future-spec.xml
+                ${CMAKE_CURRENT_BINARY_DIR}/_gen/future-${spec}.xml)
     add_custom_target(generate_future-${spec}-body DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/_gen/future-${spec}-body.hpp)
     add_dependencies(all-generated-sources generate_future-${spec}-body)

@@ -294,7 +298,9 @@
         WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}

         DEPENDS ${CMAKE_SOURCE_DIR}/tools/libqtcodegen.py
-                ${CMAKE_SOURCE_DIR}/tools/qt-svc-gen.py)
+                ${CMAKE_SOURCE_DIR}/tools/qt-svc-gen.py
+                ${CMAKE_CURRENT_BINARY_DIR}/_gen/stable-spec.xml
+                ${CMAKE_CURRENT_BINARY_DIR}/_gen/spec-svc-${spec}.xml)
     add_custom_target(generate_service-${spec}-body DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/_gen/svc-${spec}.cpp)
     add_dependencies(all-generated-service-sources generate_service-${spec}-body)


Mac builds pulled libexception_handler.dylib even when building without crash reporting.

--- indra/cmake/Copy3rdPartyLibs.cmake
+++ indra/cmake/Copy3rdPartyLibs.cmake
@@ -221,10 +221,15 @@
         libminizip.a
         libndofdev.dylib
         libhunspell-1.3.0.dylib
-        libexception_handler.dylib
+        # libexception_handler.dylib
         libcollada14dom.dylib
         #libgrowl.dylib # *TODO - test/fix/get mac growl working
        )
+
+    # <FS:ND> We only ever need google breakpad when crash reporting is used
+    if(RELEASE_CRASH_REPORTING OR NON_RELEASE_CRASH_REPORTING)
+      set(release_files ${release_files} "libexception_handler.dylib")
+    endif(RELEASE_CRASH_REPORTING OR NON_RELEASE_CRASH_REPORTING)

     # fmod is statically linked on darwin
     set(fmod_files "")


Setting ios deployment target to 11.0

Setting ios deployment target to 11.0

--- core/cmake/toolchains/ios.cmake
+++ core/cmake/toolchains/ios.cmake
@@ -5,7 +5,7 @@
   CACHE STRING "ios_archs"
 )

-set(IOS_DEPLOYMENT_TARGET 10.0
+set(IOS_DEPLOYMENT_TARGET 11.0
   CACHE STRING "ios_deployment_target"
 )


 - fixed style error in cmake module add_boost_test

git-svn-id: 41bd7e47c31e4d43f97241d7529f6785d233c6d8@5502 23f926e6-80f1-49ca-85a0-60d4a27bb3ac

--- rdo/rdo_studio/branches/dev_linux/cmake/add_boost_test.cmake
+++ rdo/rdo_studio/branches/dev_linux/cmake/add_boost_test.cmake
@@ -4,7 +4,6 @@

 # create BOOST TEST
 MACRO(ADD_BOOST_TEST args)
-

 MESSAGE(STATUS "CREATE  ${ARGV0}")

@@ -26,4 +25,4 @@
 SOURCE_GROUP(".test" FILES
 	${ARGN})

-ENDMACRO(ADD_BOOST_TEST)+ENDMACRO(ADD_BOOST_TEST)


Updated MKL find module

Updated MKL find module

Former-commit-id: eb320eb56d5d082f84428e969517e9fb90de349d

--- cmake-modules/FindMKL.cmake
+++ cmake-modules/FindMKL.cmake
@@ -30,284 +30,369 @@
 # SGI - SGI MPT Library

 # linux
-if(UNIX AND NOT APPLE)
-    if(${CMAKE_HOST_SYSTEM_PROCESSOR} STREQUAL "x86_64")
+
+
+
+function(register_found_components)
+    foreach(cmp ${MKL_FIND_COMPONENTS})
+        if(MKL_${cmp}_FOUND)
+            set(MKL_${cmp}_FOUND TRUE PARENT_SCOPE)
+        endif()
+    endforeach()
+endfunction()
+
+
+function(find_mkl_libraries)
+
+    if(UNIX AND NOT APPLE)
+        if(${CMAKE_HOST_SYSTEM_PROCESSOR} STREQUAL "x86_64")
+            set(MKL_ARCH_DIR "intel64")
+        else()
+            set(MKL_ARCH_DIR "ia32")
+        endif()
+    endif()
+
+    # macos
+    if(APPLE)
         set(MKL_ARCH_DIR "intel64")
+    endif()
+
+    if(FORCE_BUILD_32BITS)
+        set(MKL_ARCH_DIR "ia32")
+    endif()
+
+    if (WIN32)
+        if(${CMAKE_SIZEOF_VOID_P} EQUAL 8)
+            set(MKL_ARCH_DIR "intel64")
+        else()
+            set(MKL_ARCH_DIR "ia32")
+        endif()
+    endif()
+
+
+    set(MKL_ROOT_SEARCH_PATHS
+            $ENV{MKL_DIR}  ${MKL_DIR}
+            $ENV{MKLDIR}   ${MKLDIR}
+            $ENV{MKLROOT}  ${MKLROOT}
+            $ENV{MKL_ROOT} ${MKL_ROOT}
+            $ENV{mkl_root} ${mkl_root}
+            $ENV{HOME}/intel/mkl
+            /opt/intel/mkl
+            /opt/intel
+            /opt
+            /usr/lib/x86_64-linux-gnu
+            /usr
+            /Library/Frameworks/Intel_MKL.framework/Versions/Current/lib/universal
+            "Program Files (x86)/Intel/ComposerXE-2011/mkl"
+            )
+
+    set(MKL_PATH_SUFFIXES
+            mkl
+            intel/mkl
+            intel
+            )
+
+    if(BUILD_SHARED_LIBS)
+        set(LINK_TYPE SHARED)
+        set(MKL_LIB_SUFFIX ${CMAKE_SHARED_LIBRARY_SUFFIX})
     else()
-        set(MKL_ARCH_DIR "32")
-    endif()
-endif()
-
-# macos
-if(APPLE)
-    set(MKL_ARCH_DIR "intel64")
-endif()
-
-IF(FORCE_BUILD_32BITS)
-    set(MKL_ARCH_DIR "32")
-ENDIF()
-
-if (WIN32)
-    if(${CMAKE_SIZEOF_VOID_P} EQUAL 8)
-        set(MKL_ARCH_DIR "intel64")
-    else()
-        set(MKL_ARCH_DIR "ia32")
-    endif()
-endif()
-
-
-set(MKL_ROOT_SEARCH_PATHS
-        $ENV{MKL_DIR}  ${MKL_DIR}
-        $ENV{MKLDIR}   ${MKLDIR}
-        $ENV{MKLROOT}  ${MKLROOT}
-        $ENV{MKL_ROOT} ${MKL_ROOT}
-        $ENV{mkl_root} ${mkl_root}
-        $ENV{HOME}/intel/mkl
-        /opt/intel/mkl
-        /opt/intel
-        /opt
-        /usr/lib/x86_64-linux-gnu
-        /usr
-        /Library/Frameworks/Intel_MKL.framework/Versions/Current/lib/universal
-        "Program Files (x86)/Intel/ComposerXE-2011/mkl"
-        )
-
-set(MKL_PATH_SUFFIXES
-        mkl
-        intel/mkl
-        intel
-        )
-if(BUILD_SHARED_LIBS)
-    set(MKL_LIB_SUFFIX ${CMAKE_SHARED_LIBRARY_SUFFIX})
-else()
-    set(MKL_LIB_SUFFIX ${CMAKE_STATIC_LIBRARY_SUFFIX})
-endif()
-
-
-find_path(MKL_ROOT_DIR
-        include/mkl.h
-        PATHS ${MKL_ROOT_SEARCH_PATHS}
-        PATH_SUFFIXES
-        ${MKL_PATH_SUFFIXES}
-        )
-if(MKL_ROOT_DIR)
-    message(STATUS "Found MKL ROOT: ${MKL_ROOT_DIR}")
-    find_path(MKL_INCLUDE_DIR
-            mkl.h
-            HINTS ${MKL_ROOT_DIR}/include
+        set(LINK_TYPE STATIC)
+        set(MKL_LIB_SUFFIX ${CMAKE_STATIC_LIBRARY_SUFFIX})
+    endif()
+
+
+    find_path(MKL_ROOT_DIR
+            include/mkl.h
+            PATHS ${MKL_ROOT_SEARCH_PATHS}
+            PATH_SUFFIXES
+            ${MKL_PATH_SUFFIXES}
             )
-
-    find_path(MKL_FFTW_INCLUDE_DIR
-            fftw3.h
-            HINTS ${MKL_ROOT_DIR}/include
-            PATH_SUFFIXES fftw
-            NO_DEFAULT_PATH
-            )
-
-    find_library(MKL_CORE_LIBRARY
-            libmkl_core${MKL_LIB_SUFFIX}
-            HINTS ${MKL_ROOT_DIR}
-            PATH_SUFFIXES
-            lib lib/${MKL_ARCH_DIR}
-            )
-
-    # Threading libraries
-    find_library(MKL_SEQUENTIAL_LIBRARY
-            libmkl_sequential${MKL_LIB_SUFFIX}
-            HINTS ${MKL_ROOT_DIR}
-            PATH_SUFFIXES
-            lib lib/${MKL_ARCH_DIR}
-            )
-
-    find_library(MKL_INTELTHREAD_LIBRARY
-            libmkl_intel_thread${MKL_LIB_SUFFIX}
-            HINTS ${MKL_ROOT_DIR}
-            PATH_SUFFIXES
-            lib lib/${MKL_ARCH_DIR}
-            )
-
-    find_library(MKL_GNUTHREAD_LIBRARY
-            libmkl_gnu_thread${MKL_LIB_SUFFIX}
-            HINTS ${MKL_ROOT_DIR}
-            PATH_SUFFIXES
-            lib lib/${MKL_ARCH_DIR}
-            )
-
-    # Intel Fortran Libraries
-    if("${MKL_ARCH_DIR}" STREQUAL "32")
-        find_library(MKL_INTEL_LP_LIBRARY
-                libmkl_intel${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-
-        find_library(MKL_INTEL_ILP_LIBRARY
-                libmkl_intel${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-    else()
-        find_library(MKL_INTEL_LP_LIBRARY
-                libmkl_intel_lp64${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-
-        find_library(MKL_INTEL_ILP_LIBRARY
-                libmkl_intel_ilp64${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-    endif()
-
-    # GNU Fortran Libraries
-    find_library(MKL_GF_LP_LIBRARY
-            libmkl_gf_lp64${MKL_LIB_SUFFIX}
-            HINTS ${MKL_ROOT_DIR}
-            PATH_SUFFIXES
-            lib lib/${MKL_ARCH_DIR}
-            )
-
-    find_library(MKL_GF_ILP_LIBRARY
-            libmkl_gf_ilp64${MKL_LIB_SUFFIX}
-            HINTS ${MKL_ROOT_DIR}
-            PATH_SUFFIXES
-            lib lib/${MKL_ARCH_DIR}
-            )
-
-
-
-    # Blas
-    if("${MKL_ARCH_DIR}" STREQUAL "32")
-        find_library(MKL_BLAS_LP_LIBRARY
-                libmkl_blas${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-        find_library(MKL_BLAS_ILP_LIBRARY
-                libmkl_blas${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-    else()
-        find_library(MKL_BLAS_LP_LIBRARY
-                libmkl_blas95_lp64${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-        find_library(MKL_BLAS_ILP_LIBRARY
-                libmkl_blas95_ilp64${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-
-    endif()
-
-
-
-    # Lapack
-    if("${MKL_ARCH_DIR}" STREQUAL "32")
-        find_library(MKL_LAPACK_LP_LIBRARY
-                libmkl_lapack${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-        find_library(MKL_LAPACK_ILP_LIBRARY
-                libmkl_lapack${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-    else()
-        find_library(MKL_LAPACK_LP_LIBRARY
-                libmkl_lapack95_lp64${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-        find_library(MKL_LAPACK_ILP_LIBRARY
-                libmkl_lapack95_ilp64${MKL_LIB_SUFFIX}
-                HINTS ${MKL_ROOT_DIR}
-                PATH_SUFFIXES
-                lib lib/${MKL_ARCH_DIR}
-                )
-
-    endif()
-
-
-    # Single shared library
-    find_library(MKL_RT_LIBRARY
-            mkl_rt
-            HINTS ${MKL_ROOT_DIR}
-            PATH_SUFFIXES
-            lib lib/${MKL_ARCH_DIR}
-            )
-
-
-    # iomp5
-    IF("${MKL_ARCH_DIR}" STREQUAL "32")
-        IF(UNIX AND NOT APPLE)
+    if(MKL_ROOT_DIR)
+        message(STATUS "Found MKL ROOT: ${MKL_ROOT_DIR}")
+        find_path(MKL_INCLUDE_DIR
+                mkl.h
+                HINTS ${MKL_ROOT_DIR}/include
+                )
+
+        find_path(MKL_FFTW_INCLUDE_DIR
+                fftw3.h
+                HINTS ${MKL_ROOT_DIR}/include
+                PATH_SUFFIXES fftw
+                NO_DEFAULT_PATH
+                )
+
+        find_library(MKL_CORE_LIBRARY
+                mkl_core
+                HINTS ${MKL_ROOT_DIR}
+                PATH_SUFFIXES
+                lib lib/${MKL_ARCH_DIR}
+                )
+        add_library(mkl::mkl_core ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_core PROPERTIES IMPORTED_LOCATION "${MKL_CORE_LIBRARY}")
+        target_include_directories(mkl::mkl_core SYSTEM INTERFACE ${MKL_INCLUDE_DIR})
+
+        # Threading libraries
+        find_library(MKL_SEQUENTIAL_LIBRARY
+                mkl_sequential
+                HINTS ${MKL_ROOT_DIR}
+                PATH_SUFFIXES
+                lib lib/${MKL_ARCH_DIR}
+                )
+        add_library(mkl::mkl_sequential ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_sequential PROPERTIES IMPORTED_LOCATION "${MKL_SEQUENTIAL_LIBRARY}")
+
+        find_library(MKL_INTELTHREAD_LIBRARY
+                mkl_intel_thread
+                HINTS ${MKL_ROOT_DIR}
+                PATH_SUFFIXES
+                lib lib/${MKL_ARCH_DIR}
+                )
+        add_library(mkl::mkl_intel_thread ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_intel_thread PROPERTIES IMPORTED_LOCATION "${MKL_INTELTHREAD_LIBRARY}")
+
+        find_library(MKL_GNUTHREAD_LIBRARY
+                mkl_gnu_thread
+                HINTS ${MKL_ROOT_DIR}
+                PATH_SUFFIXES
+                lib lib/${MKL_ARCH_DIR}
+                )
+        add_library(mkl::mkl_gnu_thread ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_gnu_thread PROPERTIES IMPORTED_LOCATION "${MKL_GNUTHREAD_LIBRARY}")
+
+
+        # Intel Fortran Libraries
+        if(MKL_ARCH_DIR MATCHES "32")
+            find_library(MKL_INTEL_LP_LIBRARY
+                    mkl_intel
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+
+            # Dummy... it's actually the same library as above
+            find_library(MKL_INTEL_ILP_LIBRARY
+                    mkl_intel${MKL_LIB_SUFFIX}
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+
+        else()
+            find_library(MKL_INTEL_LP_LIBRARY
+                    mkl_intel_lp64
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+
+            find_library(MKL_INTEL_ILP_LIBRARY
+                    mkl_intel_ilp64${MKL_LIB_SUFFIX}
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+
+        endif()
+        add_library(mkl::mkl_intel_lp ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_intel_lp PROPERTIES IMPORTED_LOCATION "${MKL_INTEL_LP_LIBRARY}")
+
+        add_library(mkl::mkl_intel_ilp ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_intel_ilp PROPERTIES IMPORTED_LOCATION "${MKL_INTEL_ILP_LIBRARY}")
+
+
+
+
+        # GNU Fortran Libraries
+        if(MKL_ARCH_DIR MATCHES "32")
+            find_library(MKL_GF_LP_LIBRARY
+                    mkl_gf
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+            find_library(MKL_GF_ILP_LIBRARY
+                    mkl_gf
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+        else()
+            find_library(MKL_GF_LP_LIBRARY
+                mkl_gf_lp64
+                HINTS ${MKL_ROOT_DIR}
+                PATH_SUFFIXES
+                lib lib/${MKL_ARCH_DIR}
+                )
+            find_library(MKL_GF_ILP_LIBRARY
+                mkl_gf_ilp64
+                HINTS ${MKL_ROOT_DIR}
+                PATH_SUFFIXES
+                lib lib/${MKL_ARCH_DIR}
+                )
+        endif()
+        add_library(mkl::mkl_gf_lp ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_gf_lp PROPERTIES IMPORTED_LOCATION "${MKL_GF_LP_LIBRARY}")
+
+
+        add_library(mkl::mkl_gf_ilp ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_gf_ilp PROPERTIES IMPORTED_LOCATION "${MKL_GF_ILP_LIBRARY}")
+
+
+        # Blas
+        if("${MKL_ARCH_DIR}" STREQUAL "32")
+            find_library(MKL_BLAS_LP_LIBRARY
+                    mkl_blas
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+
+            find_library(MKL_BLAS_ILP_LIBRARY
+                    mkl_blas
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+
+        else()
+            find_library(MKL_BLAS_LP_LIBRARY
+                    mkl_blas95_lp64
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+
+            find_library(MKL_BLAS_ILP_LIBRARY
+                    mkl_blas95_ilp64
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+
+        endif()
+
+        add_library(mkl::mkl_blas_lp ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_blas_lp PROPERTIES IMPORTED_LOCATION "${MKL_BLAS_LP_LIBRARY}")
+
+        add_library(mkl::mkl_blas_ilp ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_blas_ilp PROPERTIES IMPORTED_LOCATION "${MKL_BLAS_ILP_LIBRARY}")
+
+
+
+        # Lapack
+        if(MKL_ARCH_DIR MATCHES "32")
+            find_library(MKL_LAPACK_LP_LIBRARY
+                    mkl_lapack
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+            find_library(MKL_LAPACK_ILP_LIBRARY
+                    mkl_lapack
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+        else()
+            find_library(MKL_LAPACK_LP_LIBRARY
+                    mkl_lapack95_lp64
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+            find_library(MKL_LAPACK_ILP_LIBRARY
+                    mkl_lapack95_ilp64
+                    HINTS ${MKL_ROOT_DIR}
+                    PATH_SUFFIXES
+                    lib lib/${MKL_ARCH_DIR}
+                    )
+
+        endif()
+        add_library(mkl::mkl_lapack_lp ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_lapack_lp PROPERTIES IMPORTED_LOCATION "${MKL_LAPACK_LP_LIBRARY}")
+
+        add_library(mkl::mkl_lapack_ilp ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_lapack_ilp PROPERTIES IMPORTED_LOCATION "${MKL_LAPACK_ILP_LIBRARY}")
+
+
+
+        # Single shared library
+        find_library(MKL_RT_LIBRARY
+                mkl_rt
+                HINTS ${MKL_ROOT_DIR}
+                PATH_SUFFIXES
+                lib lib/${MKL_ARCH_DIR}
+                )
+        add_library(mkl::mkl_rt ${LINK_TYPE} IMPORTED)
+        set_target_properties(mkl::mkl_rt PROPERTIES IMPORTED_LOCATION "${MKL_RT_LIBRARY}")
+        target_compile_options(mkl::mkl_rt INTERFACE -fPIC)
+        set_target_properties(mkl::mkl_rt PROPERTIES INTERFACE_LINK_DIRECTORIES  ${MKL_ROOT_DIR}/lib/${MKL_ARCH_DIR})
+        target_include_directories(mkl::mkl_rt SYSTEM INTERFACE ${MKL_INCLUDE_DIR})
+
+
+        # iomp5
+        if(UNIX AND NOT APPLE)
             find_library(MKL_IOMP5_LIBRARY
-                    libiomp5${MKL_LIB_SUFFIX}
+                    iomp5
                     HINTS
-                    ${MKL_ROOT_DIR}/../lib/ia32
-                    )
-        ELSE()
+                    ${MKL_ROOT_DIR}/../lib/${MKL_ARCH_DIR}
+                    )
+            add_library(mkl::iomp5 ${LINK_TYPE} IMPORTED)
+            set_target_properties(mkl::iomp5 PROPERTIES IMPORTED_LOCATION "${MKL_IOMP5_LIBRARY}")
+        else()
             SET(MKL_IOMP5_LIBRARY "") # no need for mac
-        ENDIF()
-    else()
-        IF(UNIX AND NOT APPLE)
-            find_library(MKL_IOMP5_LIBRARY
-                    libiomp5${MKL_LIB_SUFFIX}
-                    HINTS
-                    ${MKL_ROOT_DIR}/../lib/intel64
-                    )
-        ELSE()
-            SET(MKL_IOMP5_LIBRARY "") # no need for mac
-        ENDIF()
-    ENDIF()
-
-
-    set (MKL_FORTRAN_VARIANTS INTEL GF)
-    set (MKL_MODE_VARIANTS ILP LP)
-    set (MKL_THREAD_VARIANTS SEQUENTIAL GNUTHREAD INTELTHREAD)
-    set (MKL_MPI_VARIANTS NOMPI INTELMPI OPENMPI SGIMPT)
-
-
-
-    foreach (FORTRANVAR ${MKL_FORTRAN_VARIANTS})
-        foreach (MODEVAR ${MKL_MODE_VARIANTS})
-            foreach (THREADVAR ${MKL_THREAD_VARIANTS})
-                if (MKL_CORE_LIBRARY AND MKL_${FORTRANVAR}_${MODEVAR}_LIBRARY AND MKL_${THREADVAR}_LIBRARY)
-                    set(MKL_${FORTRANVAR}_${MODEVAR}_${THREADVAR}_LIBRARIES
-                            ${MKL_${FORTRANVAR}_${MODEVAR}_LIBRARY}
-    #                        ${MKL_${MODEVAR}_LIBRARY}
-                            ${MKL_${THREADVAR}_LIBRARY}
-                            ${MKL_CORE_LIBRARY}
-                            ${MKL_LAPACK_LIBRARY}
-                            ${MKL_IOMP5_LIBRARY})
-                    #message("${FORTRANVAR} ${MODEVAR} ${THREADVAR} ${MKL_${FORTRANVAR}_${MODEVAR}_${THREADVAR}_LIBRARIES}") # for debug
-                endif()
+            add_library(mkl::iomp5 INTERFACE IMPORTED)
+        endif()
+
+
+        # Define usable targets
+        set (MKL_FORTRAN_VARIANTS intel gf)
+        set (MKL_MODE_VARIANTS ilp lp)
+        set (MKL_THREAD_VARIANTS sequential intel_thread gnu_thread )
+
+        foreach (FORTRANVAR ${MKL_FORTRAN_VARIANTS})
+            foreach (MODEVAR ${MKL_MODE_VARIANTS})
+                foreach (THREADVAR ${MKL_THREAD_VARIANTS})
+                    if(THREADVAR MATCHES "sequential")
+                        set(threadv seq)
+                    endif()
+                    if(THREADVAR MATCHES "intel_thread")
+                        set(threadv ithread)
+                    endif()
+                    if(THREADVAR MATCHES "gnu_thread")
+                        set(threadv gthread)
+                    endif()
+                    add_library(mkl::mkl_${FORTRANVAR}_${MODEVAR}_${threadv} INTERFACE IMPORTED)
+                    target_link_libraries(mkl::mkl_${FORTRANVAR}_${MODEVAR}_${threadv} INTERFACE
+                            -Wl,--no-as-needed
+                            mkl::mkl_blas_${MODEVAR}
+                            mkl::mkl_lapack_${MODEVAR}
+                            -Wl,--start-group
+                            mkl::mkl_${FORTRANVAR}_${MODEVAR}
+                            mkl::mkl_${THREADVAR}
+                            mkl::mkl_core
+                            -Wl,--end-group
+                            -Wl,--as-needed
+                            )
+                    target_include_directories(mkl::mkl_${FORTRANVAR}_${MODEVAR}_${threadv} SYSTEM INTERFACE ${MKL_INCLUDE_DIR})
+                    set_target_properties(mkl::mkl_${FORTRANVAR}_${MODEVAR}_${threadv} PROPERTIES INTERFACE_LINK_DIRECTORIES  ${MKL_ROOT_DIR}/lib/${MKL_ARCH_DIR})
+                    if(BUILD_SHARED_LIBS)
+                        target_compile_options(mkl::mkl_${FORTRANVAR}_${MODEVAR}_${threadv} INTERFACE -fPIC)
+                    endif()
+                    if(MKL_ARCH_DIR MATCHES "intel64")
+                        target_compile_options(mkl::mkl_${FORTRANVAR}_${MODEVAR}_${threadv} INTERFACE -m64)
+                    endif()
+                    list(APPEND MKL_TARGETS mkl::mkl_${FORTRANVAR}_${MODEVAR}_${threadv})
+                endforeach()
             endforeach()
         endforeach()
-    endforeach()
-    set(MKL_LIBRARIES ${MKL_GF_LP_GNUTHREAD_LIBRARIES})
-    include(FindPackageHandleStandardArgs)
-    find_package_handle_standard_args(MKL DEFAULT_MSG MKL_INCLUDE_DIR MKL_LIBRARIES)
-
-    mark_as_advanced(MKL_INCLUDE_DIR MKL_LIBRARIES
-            MKL_CORE_LIBRARY MKL_INTEL_LP_LIBRARY MKL_INTEL_ILP_LIBRARY MKL_GF_LP_LIBRARY MKL_GF_ILP_LIBRARY
-            MKL_SEQUENTIAL_LIBRARY MKL_INTELTHREAD_LIBRARY MKL_GNUTHREAD_LIBRARY
-            )
-else()
-    message(WARNING "Could not find MKL root dir")
-endif()+        set(MKL_TARGETS ${MKL_TARGETS} PARENT_SCOPE)
+        set(MKL_INCLUDE_DIR ${MKL_INCLUDE_DIR} PARENT_SCOPE)
+    endif()
+endfunction()
+
+find_mkl_libraries()
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(MKL DEFAULT_MSG MKL_INCLUDE_DIR MKL_TARGETS)
+


added guard against linking qt5 and VTK together

--- cmake/OpenCVDetectVTK.cmake
+++ cmake/OpenCVDetectVTK.cmake
@@ -1,4 +1,9 @@
 if(NOT WITH_VTK OR ANDROID OR IOS)
+  return()
+endif()
+
+if (HAVE_QT5)
+  message(STATUS "VTK is disabled because OpenCV is linked with Q5. Some VTK disributives are compiled with Q4 and therefore can't be linked together Qt5.")
   return()
 endif()


cmake: remove deprecated `set_conf_file()` support

The `set_conf_file()` was deprecated in
6d4ba3490fee518da9136ce54d45d82200e800c6

which is before Zephyr v1.14 LTS.
Let's remove the support now, before releasing a new LTS.

Signed-off-by: Torsten Rasmussen <a7c5b1d5a1f41fce6edfa3f7c2392ae0c59deafe@nordicsemi.no>

--- cmake/app/boilerplate.cmake
+++ cmake/app/boilerplate.cmake
@@ -463,10 +463,6 @@
   set(CONF_FILE ${CACHED_CONF_FILE})
 elseif(DEFINED ENV{CONF_FILE})
   set(CONF_FILE $ENV{CONF_FILE})
-
-elseif(COMMAND set_conf_file)
-  message(WARNING "'set_conf_file' is deprecated, it will be removed in a future release.")
-  set_conf_file()

 elseif(EXISTS   ${APPLICATION_SOURCE_DIR}/prj_${BOARD}.conf)
   set(CONF_FILE ${APPLICATION_SOURCE_DIR}/prj_${BOARD}.conf)


Convert to ${pcl_proj} for USE_SYSTEM_PCL

--- software/externals/cmake/externals.cmake
+++ software/externals/cmake/externals.cmake
@@ -45,14 +45,17 @@
     -DBUILD_EXAMPLES:BOOL=OFF
   )

-set(pcl_url http://github.com/pointcloudlibrary/pcl.git)
-#set(pcl_revision pcl-1.7.2) # this version introduces some missing openni pkg-config file bug
-set(pcl_revision pcl-1.7.1)
-set(pcl_depends flann Eigen_pod)
-set(pcl_external_args
-  CMAKE_CACHE_ARGS
-    ${default_cmake_args}
-  )
+if(NOT USE_SYSTEM_PCL)
+  set(pcl_proj pcl)
+  set(pcl_url http://github.com/pointcloudlibrary/pcl.git)
+  #set(pcl_revision pcl-1.7.2) # this version introduces some missing openni pkg-config file bug
+  set(pcl_revision pcl-1.7.1)
+  set(pcl_depends flann Eigen_pod)
+  set(pcl_external_args
+    CMAKE_CACHE_ARGS
+      ${default_cmake_args}
+    )
+endif()

 set(octomap_url https://github.com/OctoMap/octomap.git)
 set(octomap_revision 5ba840e58a35e2d14c40d0af807da879a1a2fd83)
@@ -239,7 +242,7 @@

 set(PointCloudLibraryPlugin_url https://github.com/patmarion/PointCloudLibraryPlugin.git)
 set(PointCloudLibraryPlugin_revision cb119b0)
-set(PointCloudLibraryPlugin_depends pcl)
+set(PointCloudLibraryPlugin_depends ${pcl_proj})
 set(PointCloudLibraryPlugin_external_args
   CMAKE_CACHE_ARGS
     ${default_cmake_args}
@@ -255,7 +258,7 @@
   libbot
   ${opencv_proj}
   flann
-  pcl
+  ${pcl_proj}
   octomap
   occ-map
   common_utils
@@ -310,15 +313,6 @@
 endif()

-if(USE_SYSTEM_PCL)
-  list(REMOVE_ITEM externals
-    pcl
-  )
-  list(REMOVE_ITEM PointCloudLibraryPlugin_depends
-    pcl
-  )
-endif()
-
 # Checks whether Matlab is installed, else remove dependent packages
 find_program(matlab matlab)
 if (NOT matlab)


test=develop

test=develop

--- cmake/cblas.cmake
+++ cmake/cblas.cmake
@@ -40,7 +40,7 @@
         /usr/local/opt/openblas/lib)

 find_path(OPENBLAS_INC_DIR NAMES cblas.h
-  PATHS ${OPENBLAS_INCLUDE_SEARCH_PATHS})
+  PATHS ${OPENBLAS_INCLUDE_SEARCH_PATHS} NO_DEFAULT_PATH)
 find_path(OPENBLAS_LAPACKE_INC_DIR NAMES lapacke.h
   PATHS ${OPENBLAS_INCLUDE_SEARCH_PATHS})
 find_library(OPENBLAS_LIB NAMES openblas


create data directory

create data directory

--- cmake/paths.cmake
+++ cmake/paths.cmake
@@ -13,3 +13,4 @@
 # Create log folder
 file( MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin/log )
 file( MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin/navi )
+file( MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin/data )


Update WSREP_PATCH_REVNO.

Update WSREP_PATCH_REVNO.

--- cmake/wsrep.cmake
+++ cmake/wsrep.cmake
@@ -23,7 +23,7 @@
 # MariaDB addition: Revision number of the last revision merged from
 # codership branch visible in @@visible_comment.
 # Branch : https://github.com/codership/mysql-wsrep/tree/5.5
-SET(WSREP_PATCH_REVNO "4f81026") # Should be updated on every merge.
+SET(WSREP_PATCH_REVNO "9949137") # Should be updated on every merge.

 # MariaDB: Obtain patch revision number:
 # Update WSREP_PATCH_REVNO if WSREP_REV environment variable is set.


COMP: Remove Numpy from All build configuration.

--- CMake/BuildConfigurations/All.cmake
+++ CMake/BuildConfigurations/All.cmake
@@ -11,6 +11,7 @@
 set(_package_excludes
   ${_apple_package_excludes}
   Python
+  Numpy
   OpenCL
   SYSTEM_Boost
   Boost_LIBRARIES


Recently the CEGUI renderer was configured on OS X to use an executable path from within the Plugins area, but this wasn't getting symlinked in.

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

--- CMake/Utils/OgreConfigTargets.cmake
+++ CMake/Utils/OgreConfigTargets.cmake
@@ -299,6 +299,12 @@
           ${OGRE_SAMPLE_CONTENTS_PATH}/Plugins/
         )
       endif()
+      if (OGRE_BUILD_CEGUIRENDERER)
+        add_custom_command(TARGET ${SAMPLENAME} POST_BUILD
+        COMMAND ln ARGS -s -f ${CMAKE_BINARY_DIR}/lib/$(CONFIGURATION)/libCEGUIOgreRenderer.dylib
+          ${OGRE_SAMPLE_CONTENTS_PATH}/Plugins/
+        )
+      endif()
     endif()
   endif (APPLE)


Added clang as a valid compiler.

Added clang as a valid compiler.

--- resources/Compiler.cmake
+++ resources/Compiler.cmake
@@ -29,6 +29,12 @@
     execute_process(COMMAND ${CMAKE_CXX_COMPILER} -dumpversion OUTPUT_VARIABLE COMPILER_VERSION)
     string(REPLACE "\n" "" COMPILER_VERSION ${COMPILER_VERSION})
     set(COMPILER_SUFFIX "-${COMPILER_NAME_SIMPLE}${COMPILER_VERSION}")
+elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+    set(COMPILER_NAME "LLVM Clang")
+    set(COMPILER_NAME_SIMPLE "clang")
+    execute_process(COMMAND ${CMAKE_CXX_COMPILER} -dumpversion OUTPUT_VARIABLE COMPILER_VERSION)
+    string(REPLACE "\n" "" COMPILER_VERSION ${COMPILER_VERSION})
+    set(COMPILER_SUFFIX "-${COMPILER_NAME_SIMPLE}${COMPILER_VERSION}")
 endif()

 if("${COMPILER_NAME}" STREQUAL "Unknown" AND ${FIRST})


nxphlite-v3:Add mpl3115a2 (stubed out)

nxphlite-v3:Add mpl3115a2 (stubed out)

--- cmake/configs/nuttx_nxphlite-v3_default.cmake
+++ cmake/configs/nuttx_nxphlite-v3_default.cmake
@@ -22,6 +22,7 @@
 	drivers/mpu9250
 	drivers/hmc5883
 	drivers/ms5611
+	drivers/mpl3115a2
 	drivers/mb12xx
 	drivers/srf02
 	drivers/sf0x


ENH: Bump ITK version to SHA on github

ENH: Bump ITK version to SHA on github

--- CMake/Superbuild/ExternalProjectsConfig.cmake
+++ CMake/Superbuild/ExternalProjectsConfig.cmake
@@ -40,7 +40,7 @@
 # Insight Segmentation and Registration Toolkit
 # v4.5
 set( ITK_URL ${github_protocol}://github.com/Kitware/ITK.git )
-set( ITK_HASH_OR_TAG fed99458dde66655c892174522a1ec5194f1c352 )
+set( ITK_HASH_OR_TAG 1b62d2bb5bedcf7fa80e96e79064a2043811d616 )

 # JsonCpp snapshot 2013-08-08 23:08:28
 set( JsonCpp_URL


added simpleITK library dir into search path

--- CMake/mitkFunctionGetLibrarySearchPaths.cmake
+++ CMake/mitkFunctionGetLibrarySearchPaths.cmake
@@ -107,6 +107,9 @@
   if(MITK_USE_TOF_PMDO3 OR MITK_USE_TOF_PMDCAMCUBE OR MITK_USE_TOF_PMDCAMBOARD)
     list(APPEND _dir_candidates "${MITK_PMD_SDK_DIR}/plugins")
   endif()
+  if(SimpleITK_DIR)
+    list(APPEND _dir_candidates "${SimpleITK_DIR}/lib")
+  endif()

   if(MITK_USE_CTK)
     list(APPEND _dir_candidates "${CTK_LIBRARY_DIRS}")


Make Boost libraries use RPATH

Make Boost libraries use RPATH

--- CMakeExternals/Boost-post_install-APPLE.cmake
+++ CMakeExternals/Boost-post_install-APPLE.cmake
@@ -1,11 +1,8 @@
-message(STATUS "Fixing relative dependencies")
+message(STATUS "Make Boost libraries use RPATH")

 file(GLOB boost_dylibs ./libboost*.dylib)

-foreach(in ${boost_dylibs})
-  foreach(other_boost_dylib ${boost_dylibs})
-    get_filename_component(from ${other_boost_dylib} NAME)
-    set(to "@rpath/${from}")
-    execute_process(COMMAND install_name_tool -change ${from} ${to} ${in})
-  endforeach()
+foreach(boost_dylib ${boost_dylibs})
+  get_filename_component(boost_dylib ${boost_dylib} NAME)
+  execute_process(COMMAND install_name_tool -id @rpath/${boost_dylib} ${boost_dylib})
 endforeach()


Minor iOS tweak.

Minor iOS tweak.

--- toolchains/ios.cmake
+++ toolchains/ios.cmake
@@ -154,7 +154,7 @@
 set (CMAKE_IOS_SDK_ROOT ${CMAKE_IOS_SDK_ROOT} CACHE PATH "Location of the selected iOS SDK")

 # Set the sysroot default to the most recent SDK
-set (CMAKE_OSX_SYSROOT ${CMAKE_IOS_SDK_ROOT} CACHE PATH "Sysroot used for iOS support")
+#set (CMAKE_OSX_SYSROOT ${CMAKE_IOS_SDK_ROOT} CACHE PATH "Sysroot used for iOS support")

 # set the architecture for iOS
 if (${IOS_PLATFORM} STREQUAL "OS")


SVN_SILENT made messages (.desktop file) - always resolve ours

In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"

--- gstreamer/gstreamer.desktop.cmake
+++ gstreamer/gstreamer.desktop.cmake
@@ -87,7 +87,7 @@
 Comment[gl]=Infraestrutura de GStreamer para Phonon
 Comment[hsb]=Phonon GStreamer backend
 Comment[hu]=Phonon GStreamer-modul
-Comment[id]=Phonon GStreamer backend
+Comment[id]=Backend phonon GStreamer
 Comment[is]=Phonon GStreamer bakendi
 Comment[it]=Motore Gstreamer di Phonon
 Comment[ja]=Phonon GStreamer バックエンド


Update FW: add OV9282 Strobe output

Update FW: add OV9282 Strobe output

--- 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 "58798a142f85ba55d549444d1d27563532acafb1")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "7abb047817f58f66395bde1036a56852cc0f8b78")

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


Add openvino 2021.4.2 support

Add openvino 2021.4.2 support

--- 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 "0d1ac745f62382b87f5b259f1de3c0b6c16a3775")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "b424ee78dc390ead4e1d94a1a5b3ba67f6306c1a")

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


Update FW with subpixel fix

Update FW with subpixel fix

--- 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 "71bfc84bfc06df57a826b0924b2ec0d388565b09")
+set(DEPTHAI_DEVICE_SIDE_COMMIT "f1e86083efeaf88f9dc6342e51b88cc3eb41a14b")

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


fix a version check preventing non-Apple clang compilation with vc=ON

--- cmake/modules/SearchInstalledSoftware.cmake
+++ cmake/modules/SearchInstalledSoftware.cmake
@@ -1041,8 +1041,11 @@
       set(vc OFF CACHE BOOL "" FORCE)
     endif()
   elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
-    if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS 4.0)
-      message(STATUS "VC requires Clang version >= 4.0; switching OFF 'vc' option")
+    if ( APPLE AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 4)
+      message(STATUS "VC requires Apple Clang version >= 4.0; switching OFF 'vc' option")
+      set(vc OFF CACHE BOOL "" FORCE)
+    elseif (CMAKE_CXX_COMPILER_VERSION VERSION_LESS 3.1)
+      message(STATUS "VC requires Clang version >= 3.1; switching OFF 'vc' option")
       set(vc OFF CACHE BOOL "" FORCE)
     endif()
   elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC")


Some minor cleaning up [ci skip].

Some minor cleaning up [ci skip].

--- cmake/common.cmake
+++ cmake/common.cmake
@@ -93,9 +93,6 @@
     SET(QT_VERSION_PATCH ${Qt5Widgets_VERSION_PATCH})

     # On OS X, keep track of the Qt libraries against which we need to link
-    # Note: this is needed, among other things, to make sure that any Qt-based
-    #       file can properly refer to our embedded copy of the Qt libraries
-    #       (see OS_X_CLEAN_UP_FILE_WITH_QT_LIBRARIES())...

     IF(APPLE)
         IF(ENABLE_TESTS)


Fix compile error.

Fix compile error.

--- cmake/dtrace.cmake
+++ cmake/dtrace.cmake
@@ -42,7 +42,7 @@
  # On FreeBSD, dtrace does not handle userland tracing yet
  IF(DTRACE AND NOT CMAKE_SYSTEM_NAME MATCHES "FreeBSD"
      AND NOT BUGGY_GCC_NO_DTRACE_MODULES
-     AND NOT BUGGY_LINUX_DTRACE)
+     AND NOT BUGGY_LINUX_DTRACE
      AND NOT SYSTEM_NAME MATCHES "SunOS")
    SET(ENABLE_DTRACE ON CACHE BOOL "Enable dtrace")
  ENDIF()


handle AppleClang in Cooperlake support condition

--- cmake/system.cmake
+++ cmake/system.cmake
@@ -4,6 +4,13 @@
 ##
 set(NETLIB_LAPACK_DIR "${PROJECT_SOURCE_DIR}/lapack-netlib")

+1
+
+##
+
+2
+
+## Author: Hank Anderson <hank@statease.com>
 # System detection, via CMake.
 include("${PROJECT_SOURCE_DIR}/cmake/system_check.cmake")

@@ -150,12 +157,12 @@
   if (${TARGET} STREQUAL COOPERLAKE AND NOT NO_AVX512)
     if (${CMAKE_C_COMPILER_ID} STREQUAL "GNU")
       execute_process(COMMAND ${CMAKE_C_COMPILER} -dumpversion OUTPUT_VARIABLE GCC_VERSION)
-        if (${CMAKE_C_COMPILER_VERSION} VERSION_GREATER 10.1 OR ${CMAKE_C_COMPILER_VERSION} VERSION_EQUAL 10.1)
+        if (${CMAKE_C_COMPILER_VERSION} VERSION_GREATER 10.09)
           set (KERNEL_DEFINITIONS "${KERNEL_DEFINITIONS} -march=cooperlake")
         else()
           set (KERNEL_DEFINITIONS "${KERNEL_DEFINITIONS} -march=skylake-avx512")
         endif()
-    elseif (${CMAKE_C_COMPILER_ID} STREQUAL "CLANG")
+    elseif (${CMAKE_C_COMPILER_ID} STREQUAL "CLANG" OR ${CMAKE_C_COMPILER_ID} STREQUAL "AppleClang")
          if (${CMAKE_C_COMPILER_VERSION} VERSION_GREATER 8.99)
           set (KERNEL_DEFINITIONS "${KERNEL_DEFINITIONS} -march=cooperlake")
         else()


COMP: propogate compiler selection & flags to FFTW build

FFTW gets built via a CMake ExternalProject. The actual
build is done via an autoconf configure/make recipe. The
compiler and compiler flags weren't being propagated down into
the FFTW configuration pass; consequently FFTW could get built
with a different compiler and compiler flags than the rest
of ITK.

Change-Id: I81f3b42daf25d95742e5e2ef3a2fcf7e895a6d20

--- CMake/itkExternal_FFTW.cmake
+++ CMake/itkExternal_FFTW.cmake
@@ -39,6 +39,12 @@
   find_package( FFTW )
   link_directories(${FFTW_LIBDIR})
 else(USE_SYSTEM_FFTW)
+  set(FFTW_COMPILER_FLAGS
+    CC=${CMAKE_C_COMPILER}
+    CXX=${CMAKE_CXX_COMPILER}
+    CFLAGS=${CMAKE_C_FLAGS}
+    CXXFLAGS=${CMAKE_CXX_FLAGS})
+
   if(WIN32 AND NOT MINGW)
     message("Can't build fftw as external project on Windows")
     message(ERROR "install fftw and use USE_SYSTEM_FFTW")
@@ -67,6 +73,7 @@
         --disable-fortran
         --enable-float
         --prefix=${ITK_BINARY_DIR}/fftw
+        ${FFTW_COMPILER_FLAGS}
         )
     endif(USE_FFTWF)

@@ -82,6 +89,7 @@
         --disable-fortran
         --disable-float
         --prefix=${ITK_BINARY_DIR}/fftw
+        ${FFTW_COMPILER_FLAGS}
         )
     endif(USE_FFTWD)
     set(FFTW_INCLUDE_PATH ${ITK_BINARY_DIR}/fftw/include)


Make _install_DESTINATION also work for Linux and Windows

--- CMake/mitkMacroInstall.cmake
+++ CMake/mitkMacroInstall.cmake
@@ -21,7 +21,7 @@
     #string(REGEX REPLACE ^bin "" _install_DESTINATION ${_install_DESTINATION})
   else()
     if(NOT MACOSX_BUNDLE_NAMES)
-      install(${ARGS} DESTINATION bin)
+      install(${ARGS} DESTINATION bin/${_install_DESTINATION})
     else()
       foreach(bundle_name ${MACOSX_BUNDLE_NAMES})
         install(${ARGS} DESTINATION ${bundle_name}.app/Contents/MacOS/${_install_DESTINATION})


[cmake] disable iconv in ffmpeg config:

[cmake] disable iconv in ffmpeg config:

--- cmake/GenerateFFMPEG.cmake
+++ cmake/GenerateFFMPEG.cmake
@@ -149,6 +149,7 @@
             --enable-gpl
             --enable-pic
             --disable-symver
+            --disable-iconv
             --enable-shared
             --enable-hardcoded-tables
             --enable-runtime-cpudetect


display cluster option marked as advanced.

--- cmake/displaycluster.cmake
+++ cmake/displaycluster.cmake
@@ -15,6 +15,7 @@
 ## ======================================================================== ##

 OPTION(OSPRAY_DISPLAYCLUSTER "Build DisplayCluster tiled display support")
+MARK_AS_ADVANCED(OSPRAY_DISPLAYCLUSTER)

 IF (OSPRAY_DISPLAYCLUSTER)


Reset install destination for MITK_INSTALL macro

--- CMake/mitkInstallRules.cmake
+++ CMake/mitkInstallRules.cmake
@@ -73,3 +73,5 @@
     MITK_INSTALL(DIRECTORY "${_qmake_path}/../translations/qtwebengine_locales")
   endif()
 endif()
+
+set(_install_DESTINATION "") # IMPORTANT: Restore default install destination!


build: add Boost 1.41

build: add Boost 1.41


[CI] fix (one more ...)  Docker/ctest default components list

--- CI/machinery/CTestDriver.cmake
+++ CI/machinery/CTestDriver.cmake
@@ -120,9 +120,13 @@
   set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} -DWITH_TESTS_COVERAGE:BOOL=ON")
 endif()

+
 set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} ${CTEST_SOURCE_DIRECTORY}")
 set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} ${CI_CONFIGURE_OPTIONS}")
-set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} -DCOMPONENTS=${SICONOS_COMPONENTS}")
+if(SICONOS_COMPONENTS)
+  message("ooi ${SICONOS_COMPONENTS}")
+  set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} -DCOMPONENTS=${SICONOS_COMPONENTS}")
+endif()

 set( dashboard_cache "
      BUILD_TESTING:BOOL=ON


Update go check

Update go check

--- CMakeDetermineGoCompiler.cmake
+++ CMakeDetermineGoCompiler.cmake
@@ -17,7 +17,7 @@

 if(NOT CMAKE_Go_COMPILER)

-  if ($ENV{GOPATH} STREQUAL "")
+  if (NOT $ENV{GOPATH} OR $ENV{GOPATH} STREQUAL "")
     message(SEND_ERROR "Please set GOPATH before running make")
   endif()


cmake: added new gmx-52 defines

cmake: added new gmx-52 defines

--- CMakeModules/FindGROMACS.cmake
+++ CMakeModules/FindGROMACS.cmake
@@ -73,15 +73,20 @@
   #check is above
   if(FOUND_GROMACS_VERSION_CXX)
     set(GMX_VERSION 52)
+    if ("${GROMACS_LIBRARY}" MATCHES "lib[^/]*_d\\.[^.]*$")
+      list(APPEND GMX_DEFS "-DGMX_DOUBLE=1")
+    else()
+      list(APPEND GMX_DEFS "-DGMX_DOUBLE=0")
+    endif()
   endif(FOUND_GROMACS_VERSION_CXX)
   set(GROMACS_VERSION ${GMX_VERSION})
   check_cxx_library_exists("${GROMACS_LIBRARY}" gmx_is_single_precision "" FOUND_GMX_IS_SINGLE_PRECISION)
   check_cxx_library_exists("${GROMACS_LIBRARY}" gmx_is_double_precision "" FOUND_GMX_IS_DOUBLE_PRECISION)

   #Only set GROMACS_DEFINITIONS if GROMACS_LIBRARY was found
-  if ("${GROMACS_LIBRARY}" MATCHES "lib[^/]*_d\\.[^.]*$")
+  if ("${GROMACS_LIBRARY}" MATCHES "lib[^/]*_d\\.[^.]*$" AND NOT GMX_VERSION EQUAL 52)
     list(APPEND GMX_DEFS "-DGMX_DOUBLE")
-  endif ("${GROMACS_LIBRARY}" MATCHES "lib[^/]*_d\\.[^.]*$")
+  endif ()
   if (PC_GROMACS_CFLAGS_OTHER)
     foreach(DEF ${PC_GROMACS_CFLAGS_OTHER})
       if (${DEF} MATCHES "^-D")


Exlude files generated by moc and uic from the coverage analysis and
ignore icecream errors.

svn path=/trunk/KDE/kdepim/; revision=1050789

--- CTestConfig.cmake
+++ CTestConfig.cmake
@@ -14,3 +14,6 @@

 set(CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS 2000)
 set(CTEST_CUSTOM_WARNING_EXCEPTION "groupwise/soap" "mk4storage")
+set(CTEST_CUSTOM_ERROR_EXCEPTION "ICECC")
+set(CTEST_CUSTOM_COVERAGE_EXCLUDE ".moc$" "moc_" "ui_" "ontologies")
+


Add old packages as conflicting (deb) & obsoleting (rpm) packages

--- CommonCPack.cmake
+++ CommonCPack.cmake
@@ -6,6 +6,7 @@
   set(CPACK_PROJECT_NAME ${CMAKE_PROJECT_NAME})
 endif()
 string(TOUPPER ${CPACK_PROJECT_NAME} UPPER_PROJECT_NAME)
+string(TOLOWER ${CPACK_PROJECT_NAME} LOWER_PROJECT_NAME)

 set(CMAKE_PACKAGE_VERSION "" CACHE
   STRING "Additional build version for packages")
@@ -13,6 +14,11 @@

 if(CMAKE_SYSTEM_NAME MATCHES "Linux")
   set(CPACK_PACKAGE_NAME "${CPACK_PROJECT_NAME}${VERSION_ABI}")
+  set(OLD_PACKAGES)
+  foreach(i RANGE ${VERSION_ABI})
+    list(APPEND OLD_PACKAGES "${LOWER_PROJECT_NAME}${i},")
+  endforeach()
+  string(REGEX REPLACE ";" " " OLD_PACKAGES ${OLD_PACKAGES})
 else()
   set(CPACK_PACKAGE_NAME "${CPACK_PROJECT_NAME}")
 endif()
@@ -97,6 +103,7 @@
   if(NOT CPACK_RPM_POST_INSTALL_SCRIPT_FILE)
     set(CPACK_RPM_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_LIST_DIR}/rpmPostInstall.sh")
   endif()
+  set(CPACK_RPM_PACKAGE_OBSOLETES ${OLD_PACKAGES})
 else()
   if(CMAKE_PACKAGE_VERSION)
     set(CPACK_PACKAGE_VERSION
@@ -105,7 +112,7 @@

   if(CPACK_GENERATOR STREQUAL "DEB")
     # dpkg requires lowercase package names
-    string(TOLOWER "${CPACK_PACKAGE_NAME}" CPACK_DEBIAN_PACKAGE_NAME)
+    set(CPACK_DEBIAN_PACKAGE_NAME ${LOWER_PROJECT_NAME})

     if(CPACK_PACKAGE_NAME_EXTRA)
       set(CPACK_DEBIAN_PACKAGE_VERSION
@@ -126,6 +133,8 @@
     if(NOT CPACK_DEBIAN_PACKAGE_MAINTAINER)
       set(CPACK_DEBIAN_PACKAGE_MAINTAINER "${CPACK_PACKAGE_CONTACT}")
     endif()
+
+    set(CPACK_DEBIAN_PACKAGE_CONFLICTS ${OLD_PACKAGES})
   endif()
 endif()


Fixed corner case in FindOpenSSL

Fixed corner case in FindOpenSSL

--- FindOpenSSL.cmake
+++ FindOpenSSL.cmake
@@ -26,13 +26,17 @@
     ELSE()
         find_library(LIB_${THELIB} NAMES ${THELIB} PATHS ${CONAN_LIB_DIRS_OPENSSL} NO_DEFAULT_PATH)
     ENDIF()
+
     IF(${THELIB} MATCHES "ssl")
         set(OPENSSL_SSL_LIBRARY ${LIB_${THELIB}})
     ENDIF()
     IF(${THELIB} MATCHES "crypto")
         set(OPENSSL_CRYPTO_LIBRARY ${LIB_${THELIB}})
     ENDIF()
-    set(OPENSSL_LIBRARIES ${OPENSSL_LIBRARIES} ${LIB_${THELIB}})
+    IF(NOT ${LIB_${THELIB}} MATCHES "NOTFOUND")
+        set(OPENSSL_LIBRARIES ${OPENSSL_LIBRARIES} ${LIB_${THELIB}})
+    ENDIF()
+    MESSAGE(${OPENSSL_LIBRARIES})
 ENDFOREACH()


COMP: Replaced APPEND file command by REPLACE string command.

ACVD files in build directory still need to be deleted manually once.

--- CMakeExternals/PatchACVD.cmake
+++ CMakeExternals/PatchACVD.cmake
@@ -1,10 +1,11 @@
+set(path "CMakeLists.txt")
+file(STRINGS ${path} contents NEWLINE_CONSUME)
 if(DESIRED_QT_VERSION MATCHES "5")
-  set(path "CMakeLists.txt")
-  file(STRINGS ${path} contents NEWLINE_CONSUME)
   string(REPLACE "find_package(VTK" "find_package(Qt5Widgets REQUIRED)\nfind_package(VTK" contents ${contents})
-  set(CONTENTS ${contents})
-  configure_file(${TEMPLATE_FILE} ${path} @ONLY)
 endif()
+string(REPLACE "ENDIF(BUILD_VOLUMEPROCESSING)" "ENDIF(BUILD_VOLUMEPROCESSING)\n\nCONFIGURE_FILE(ACVDConfig.cmake.in ACVDConfig.cmake @ONLY)" contents ${contents})
+set(CONTENTS ${contents})
+configure_file(${TEMPLATE_FILE} ${path} @ONLY)

 # Create <name>Config.cmake file to make ACVD findable through config mode of find_package()

@@ -13,8 +14,6 @@
 set(ACVD_LIBRARY_DIRS \"@PROJECT_BINARY_DIR@/bin\")
 set(ACVD_LIBRARIES vtkSurface vtkDiscreteRemeshing vtkVolumeProcessing)
 add_definitions(-DDOmultithread)")
-
-file(APPEND "CMakeLists.txt" "CONFIGURE_FILE(ACVDConfig.cmake.in ACVDConfig.cmake @ONLY)")

 # Add vtkVersionMacros.h header file


Check if OIS / Cg bins exists before trying to copy them

--HG--
branch : v2-0

--- CMake/InstallDependencies.cmake
+++ CMake/InstallDependencies.cmake
@@ -242,13 +242,13 @@

   if (WIN32)
     # copy the required DLLs to the build directory (configure_file is the only copy-like op I found in CMake)
-	if( OGRE_BUILD_SAMPLES OR OGRE_BUILD_TESTS )
-		if(NOT OGRE_BUILD_PLATFORM_WINRT)
+	if( (OGRE_BUILD_SAMPLES OR OGRE_BUILD_TESTS) AND (NOT OGRE_BUILD_PLATFORM_WINRT) )
+		if(EXISTS ${OIS_BINARY_DBG} AND EXISTS ${OIS_BINARY_REL})
 		  file(COPY ${OIS_BINARY_DBG} DESTINATION ${OGRE_BINARY_DIR}/bin/debug)
-			file(COPY ${OIS_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/release)
-			file(COPY ${OIS_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/relwithdebinfo)
-			file(COPY ${OIS_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/minsizerel)
-		endif ()
+		  file(COPY ${OIS_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/release)
+		  file(COPY ${OIS_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/relwithdebinfo)
+		  file(COPY ${OIS_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/minsizerel)
+		endif()
 	endif()

     if (OGRE_BUILD_PLUGIN_CG)
@@ -262,10 +262,12 @@
     			file(COPY ${Cg_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/minsizerel)
         endif ()
       else ()
-        file(COPY ${Cg_BINARY_DBG} DESTINATION ${OGRE_BINARY_DIR}/bin/debug)
+	    if(EXISTS ${Cg_BINARY_DBG} AND EXISTS ${Cg_BINARY_REL})
+            file(COPY ${Cg_BINARY_DBG} DESTINATION ${OGRE_BINARY_DIR}/bin/debug)
     		file(COPY ${Cg_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/release)
     		file(COPY ${Cg_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/relwithdebinfo)
     		file(COPY ${Cg_BINARY_REL} DESTINATION ${OGRE_BINARY_DIR}/bin/minsizerel)
+		endif()
       endif ()
     endif()


Fixed a bug when creating more than one AndroidJNI project and a couple of warnings.

--HG--
branch : android-cmake-project-creation-refactor

--- CMake/Utils/AndroidMacros.cmake
+++ CMake/Utils/AndroidMacros.cmake
@@ -41,6 +41,7 @@

 	SET(DEPENDENCIES ${DEPENDENCIES} OgreTerrain OgreRTShaderSystem OgreOverlay OgrePaging OgreVolume Plugin_ParticleFX Plugin_OctreeSceneManager)
 	add_dependencies(${ANDROID_PROJECT_TARGET} ${DEPENDENCIES})
+	set(DEPEND_STATIC_LIBS "")
 	foreach(DEPENDENCY ${DEPENDENCIES})
 	    set(DEPEND_STATIC_LIBS "${DEPENDENCY}Static" ${DEPEND_STATIC_LIBS})
 	endforeach(DEPENDENCY ${DEPENDENCIES})
@@ -49,7 +50,7 @@
         add_static_libs("${OGRE_DEPENDENCIES_DIR}/lib/@ANDROID_ABI@"  "glsl_optimizer" "glcpp-library" "mesa")
 	endif()

-	add_static_libs("${OGRE_DEPENDENCIES_DIR}/lib/@ANDROID_ABI@" "OIS" "freetype" "FreeImage" "zlib""zzip")
+	add_static_libs("${OGRE_DEPENDENCIES_DIR}/lib/@ANDROID_ABI@" "OIS" "freetype" "FreeImage" "zlib" "zzip")

     if(APPLE OR WIN32)
       SET(ANDROID_EXECUTABLE "android")


Write out used path in NitroConfig.cmake

--- NitroConfig.cmake
+++ NitroConfig.cmake
@@ -1 +1,10 @@
-include("${CMAKE_CURRENT_LIST_DIR}/NitroTargets.cmake")+include("${CMAKE_CURRENT_LIST_DIR}/NitroTargets.cmake")
+
+get_filename_component(_IMPORT_PREFIX "${CMAKE_CURRENT_LIST_FILE}" PATH)
+get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
+get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
+get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
+
+message(STATUS "Using Nitro: ${_IMPORT_PREFIX}")
+
+set(_IMPORT_PREFIX)


temp del

temp del

--- Jackal/Source/CMake/setup.cmake
+++ Jackal/Source/CMake/setup.cmake
@@ -1,6 +0,0 @@
-# Copyright (c) Jackal Engine. MIT License.
-# Setup file.
-
-set(JACKAL_ENGINE_DIRECTORY "JackalEngineDirectory")
-
-add_subdirectory(core)


ManageDependency: Fix variable name  typo

--- Modules/ManageDependency.cmake
+++ Modules/ManageDependency.cmake
@@ -204,7 +204,7 @@

 	## Get all variables
 	EXECUTE_PROCESS(COMMAND ${PKG_CONFIG_EXECUTABLE}
-	    --print-variables "${pkgCong}"
+	    --print-variables "${pkgConf}"
 	    OUTPUT_VARIABLE _variables
 	    OUTPUT_STRIP_TRAILING_WHITESPACE
 	    RESULT_VARIABLE pkgconfigFailed
@@ -214,7 +214,7 @@
 	    FOREACH(_v ${${var}_VARIABLES})
 		STRING(TOUPPER "${_v}" _u)
 		EXECUTE_PROCESS(COMMAND ${PKG_CONFIG_EXECUTABLE}
-		    --variable "${_v}" "${pkgCong}"
+		    --variable "${_v}" "${pkgConf}"
 		    OUTPUT_VARIABLE ${var}_${_u}
 		    OUTPUT_STRIP_TRAILING_WHITESPACE
 		    )


bad fedora / debian update ?

bad fedora / debian update ?

git-svn-id: de9bbed4c30e0eb58fe8e7d66f5c80b71699a07c@1378 bf01a9d7-0df3-0310-8ad4-b1c94d9ae2d5

--- Numerics/cmake/DartConfig.cmake
+++ Numerics/cmake/DartConfig.cmake
@@ -1,5 +1,5 @@
 SET(CTEST_PROJECT_NAME "Siconos")
-SET(NIGHTLY_START_TIME "20:00:00")
+SET(NIGHTLY_START_TIME "18:00:00")
 SET(DROP_METHOD "http")
 SET(DROP_SITE "cdash.inria.fr")
 SET(DROP_LOCATION "/CDash/submit.php?project=Siconos")


Remove extraneous CMake message statement

--- SuperBuild/External_PCRE.cmake
+++ SuperBuild/External_PCRE.cmake
@@ -30,7 +30,6 @@
   set(pcre_install_dir ${CMAKE_CURRENT_BINARY_DIR}/PCRE)

   if ( APPLE AND CMAKE_OSX_SYSROOT )
-    message( "CMAKE_OSX_SYSROOT: ${CMAKE_OSX_SYSROOT}")
     set(REQUIRED_C_FLAGS "-isysroot ${CMAKE_OSX_SYSROOT}")
     set(REQUIRED_CXX_FLAGS "-isysroot ${CMAKE_OSX_SYSROOT}")
   endif()


don't expose rmw_implementation for now

don't expose rmw_implementation for now

--- rmw_implementation_cmake/cmake/get_available_rmw_implementations.cmake
+++ rmw_implementation_cmake/cmake/get_available_rmw_implementations.cmake
@@ -21,6 +21,7 @@
 function(get_available_rmw_implementations var)
   ament_index_get_resources(middleware_implementations "rmw_typesupport")
   if(DEFINED middleware_implementations)
+    list(REMOVE_ITEM middleware_implementations "rmw_implementation")
     list(SORT middleware_implementations)
   endif()
   set(${var} ${middleware_implementations} PARENT_SCOPE)


bugfix of target_config call

bugfix of target_config call

--- Plugins/PluginTemplate.cmake
+++ Plugins/PluginTemplate.cmake
@@ -23,7 +23,7 @@
     )
     set_target_properties(${tgt} PROPERTIES LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}/bin/Plugins)
     INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/src)
-
+    RCC_TARGET_CONFIG(${tgt} plugin_libraries_debug plugin_libraries_release)
     ocv_add_precompiled_header_to_target(${tgt} src/precompiled.hpp)

     if(EXISTS "${CMAKE_CURRENT_BINARY_DIR}/${tgt}_config.txt")
@@ -51,7 +51,7 @@
     )

     set(PLUGIN_NAME ${tgt})
-    string(TIMESTAMP BUILD_DATE "%Y-%m-%d:%H:%M")
+    string(TIMESTAMP BUILD_DATE "%Y-%m-%d %H:%M")
     execute_process(
 	  COMMAND ${GITCOMMAND} rev-parse --abbrev-ref HEAD
 	  WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/../../Aquila
@@ -130,7 +130,7 @@
 				RESULT_VARIABLE IS_SVN_REPO
 				ERROR_QUIET
 			)
-			IF(NOT ${IS_SVN_REPO})
+			IF(NOT ${IS_SVN_REPO}) # return code is 0 if success
                 set(REPO_TYPE "svn")
 				execute_process(
 					COMMAND ${SVNCOMMAND} info --show-item revision
@@ -138,7 +138,7 @@
 					OUTPUT_VARIABLE GIT_COMMIT_HASH
 					ERROR_QUIET
 				)
-                string(REGEX REPLACE "\n" "" GIT_COMMIT_HASH ${GIT_COMMIT_HASH})
+                string(REGEX REPLACE "\n" "" GIT_COMMIT_HASH "${GIT_COMMIT_HASH}")
                 execute_process(
                   COMMAND ${SVNCOMMAND} info --show-item relative-url
                   WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR}
@@ -146,6 +146,11 @@
                   OUTPUT_STRIP_TRAILING_WHITESPACE
                   ERROR_QUIET
                 )
+                if(WIN32)
+                    set(GIT_USERNAME "$ENV{USERNAME}")
+                else()
+                    set(GIT_USERNAME "$ENV{USER}")
+                endif()
 			endif(NOT ${IS_SVN_REPO})
 		endif()
     ENDIF(NOT ${IS_GIT_REPO} AND NOT ${aquila_declare_plugin_SVN})
@@ -223,7 +228,7 @@
     else()
       FILE(WRITE ${link_file_path} "${external_include_file}")
     endif()
-    RCC_TARGET_CONFIG(${tgt} plugin_libraries_debug plugin_libraries_release)
+
     INSTALL(TARGETS ${tgt}
             LIBRARY DESTINATION bin/Plugins
             RUNTIME DESTINATION bin


[build] Pull in thirdparty repos with --depth 50 (#675)

Uses a fairly conservative value of 50 for now. Also implements a fallback to pull in the entire repo if that's not enough.

This will mainly help to speed up the nightly builds and the CI builds, but it will also reduce the space and time investment for potential hackers.

Submodules of thirdparty repos unfortunately won't be pulled in shallow yet.

--- thirdparty/cmake_modules/koreader_thirdparty_git.cmake
+++ thirdparty/cmake_modules/koreader_thirdparty_git.cmake
@@ -5,6 +5,9 @@
 "if(\"${git_tag}\" STREQUAL \"\")
   message(FATAL_ERROR \"Tag for git checkout should not be empty.\")
 endif()
+
+# Default depth
+set(git_clone_depth 50)

 set(run 0)

@@ -53,7 +56,7 @@
   set(number_of_tries 0)
   while(error_code AND number_of_tries LESS 3)
     execute_process(
-      COMMAND \"${git_EXECUTABLE}\" clone \"${git_repository}\" \"${src_name}\"
+      COMMAND \"${git_EXECUTABLE}\" clone --depth \${git_clone_depth} \"${git_repository}\" \"${src_name}\"
       WORKING_DIRECTORY \"${work_dir}\"
       RESULT_VARIABLE error_code
     )
@@ -97,7 +100,19 @@
       RESULT_VARIABLE error_code
     )
     if(error_code)
-      message(FATAL_ERROR \"Failed to checkout tag: '${git_tag}'\")
+      message(STATUS \"Fetching full repo\")
+      execute_process(
+        COMMAND \"${git_EXECUTABLE}\" fetch --unshallow --tags
+        WORKING_DIRECTORY \"${work_dir}/${src_name}\"
+      )
+      execute_process(
+        COMMAND \"${git_EXECUTABLE}\" checkout -f ${git_tag}
+        WORKING_DIRECTORY \"${work_dir}/${src_name}\"
+        RESULT_VARIABLE error_code
+      )
+      if(error_code)
+        message(FATAL_ERROR \"Failed to checkout tag: '${git_tag}'\")
+      endif()
     endif()
   endif()
 endif()


rename

rename

git-svn-id: 59f82343654cec32357d3b049d399063e4e4cfc7@30801 0785d39b-7218-0410-832d-ea1e28bc413d

--- deal.II/run_testsuite.cmake
+++ deal.II/run_testsuite.cmake
@@ -27,8 +27,8 @@
 #
 # TRACK
 #
-# DEAL_II_NO_JOBS
-# DEAL_II_CONFIG_FILE
+# NO_JOBS
+# CONFIG_FILE
 #

 CMAKE_MINIMUM_REQUIRED(VERSION 2.8.8)
@@ -105,14 +105,14 @@
 ENDIF()

 #
-# DEAL_II_NO_JOBS:
+# NO_JOBS:
 #

-IF("${DEAL_II_NO_JOBS}" STREQUAL "")
-  SET(DEAL_II_NO_JOBS "1")
+IF("${NO_JOBS}" STREQUAL "")
+  SET(NO_JOBS "1")
 ENDIF()

-MESSAGE("-- DEAL_II_NO_JOBS: ${DEAL_II_NO_JOBS}")
+MESSAGE("-- NO_JOBS: ${NO_JOBS}")

 #
 # Finalize:
@@ -145,8 +145,8 @@

   CTEST_START(Experimental TRACK Experimental)

-  IF(NOT "${DEAL_II_CONFIG_FILE}" STREQUAL "")
-    CTEST_CONFIGURE(OPTIONS -C"${DEAL_II_CONFIG_FILE}")
+  IF(NOT "${CONFIG_FILE}" STREQUAL "")
+    CTEST_CONFIGURE(OPTIONS -C"${CONFIG_FILE}")
   ELSE()
     CTEST_CONFIGURE()
   ENDIF()


fixes in case FindROOT does not find ROOT.

This can happen when FindROOT.cmake is copied into a third party project
and cmake is run on a machine where ROOT is not installed.

--- etc/cmake/FindROOT.cmake
+++ etc/cmake/FindROOT.cmake
@@ -46,10 +46,14 @@
   if(ROOT_${_cpt}_LIBRARY)
     mark_as_advanced(ROOT_${_cpt}_LIBRARY)
     list(APPEND ROOT_LIBRARIES ${ROOT_${_cpt}_LIBRARY})
-    list(REMOVE_ITEM ROOT_FIND_COMPONENTS ${_cpt})
+    if(ROOT_FIND_COMPONENTS)
+      list(REMOVE_ITEM ROOT_FIND_COMPONENTS ${_cpt})
+    endif()
   endif()
 endforeach()
-list(REMOVE_DUPLICATES ROOT_LIBRARIES)
+if(ROOT_LIBRARIES)
+  list(REMOVE_DUPLICATES ROOT_LIBRARIES)
+endif()

 execute_process(
     COMMAND ${ROOT_CONFIG_EXECUTABLE} --cflags


Update tensorflow to v1.2.1

Update tensorflow to v1.2.1

--- 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.2.0
+  GIT_TAG v1.2.1
   TMP_DIR "/tmp"
   STAMP_DIR "tensorflow-stamp"
   DOWNLOAD_DIR "tensorflow"


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

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

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


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

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

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


KWSys Nightly Date Stamp

KWSys Nightly Date Stamp

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

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