diff --git a/CMakeLists.txt b/CMakeLists.txt index 701dc966e4..1278d11c38 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -277,6 +277,8 @@ file(TO_CMAKE_PATH "${CMAKE_PREFIX_PATH}" CMAKE_PREFIX_PATH) message(STATUS "Module Path: ${CMAKE_MODULE_PATH}") message(STATUS "Prefix Path: ${CMAKE_PREFIX_PATH}") +include(cmake/cmake_functions.cmake) + # -------------------------------------------------------- # detect qt library # -------------------------------------------------------- @@ -284,7 +286,6 @@ if(MSVC) if (ECAL_USE_QT) find_package(QT NAMES Qt6 Qt5 COMPONENTS Core QUIET) if (NOT "${QT_FOUND}") - include("cmake/qt_msvc_path.cmake") autodetect_qt_msvc_dir() endif() endif() @@ -640,7 +641,6 @@ message(STATUS "ECAL_INSTALL_SAMPLE_SOURCES : ${ECAL_INS message(STATUS "ECAL_USE_NPCAP : ${ECAL_USE_NPCAP}") message(STATUS "ECAL_THIRDPARTY_BUILD_ASIO : ${ECAL_THIRDPARTY_BUILD_ASIO}") message(STATUS "ECAL_THIRDPARTY_BUILD_BENCHMARK : ${ECAL_THIRDPARTY_BUILD_BENCHMARK}") -message(STATUS "ECAL_THIRDPARTY_BUILD_CMAKE_FUNCTIONS : ${ECAL_THIRDPARTY_BUILD_CMAKE_FUNCTIONS}") message(STATUS "ECAL_THIRDPARTY_BUILD_CURL : ${ECAL_THIRDPARTY_BUILD_CURL}") message(STATUS "ECAL_THIRDPARTY_BUILD_FINEFTP : ${ECAL_THIRDPARTY_BUILD_FINEFTP}") message(STATUS "ECAL_THIRDPARTY_BUILD_FTXUI : ${ECAL_THIRDPARTY_BUILD_FTXUI}") diff --git a/thirdparty/cmakefunctions/cmake_functions/cmake_functions.cmake b/cmake/cmake_functions.cmake similarity index 96% rename from thirdparty/cmakefunctions/cmake_functions/cmake_functions.cmake rename to cmake/cmake_functions.cmake index 2c9ff2822c..e82754f327 100644 --- a/thirdparty/cmakefunctions/cmake_functions/cmake_functions.cmake +++ b/cmake/cmake_functions.cmake @@ -9,6 +9,7 @@ if(WIN32) list(APPEND file_list_include qt/qt_windeployqt.cmake qt/exclusive_command.cmake + qt/qt_msvc_path.cmake ) endif() diff --git a/thirdparty/cmakefunctions/cmake_functions/git/git_revision_information.cmake b/cmake/git/git_revision_information.cmake similarity index 82% rename from thirdparty/cmakefunctions/cmake_functions/git/git_revision_information.cmake rename to cmake/git/git_revision_information.cmake index 7aa22881b6..588760ffdc 100644 --- a/thirdparty/cmakefunctions/cmake_functions/git/git_revision_information.cmake +++ b/cmake/git/git_revision_information.cmake @@ -1,3 +1,21 @@ +# ========================= eCAL LICENSE ================================= +# +# Copyright (C) 2016 - 2019 Continental Corporation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ========================= eCAL LICENSE ================================= + function(deprecate_git_mayor_version _variable _access) if (_access STREQUAL "READ_ACCESS") message(WARNING "The variable ${_variable} is deprecated. Please use the variable GIT_REVISION_MAJOR instead. The old variable may be removed in future versions of cmake_functions.") diff --git a/thirdparty/cmakefunctions/cmake_functions/msvc_helper/msvc_macros.cmake b/cmake/msvc_helper/msvc_macros.cmake similarity index 59% rename from thirdparty/cmakefunctions/cmake_functions/msvc_helper/msvc_macros.cmake rename to cmake/msvc_helper/msvc_macros.cmake index 9a2c7d16b0..847b7acca1 100644 --- a/thirdparty/cmakefunctions/cmake_functions/msvc_helper/msvc_macros.cmake +++ b/cmake/msvc_helper/msvc_macros.cmake @@ -1,3 +1,21 @@ +# ========================= eCAL LICENSE ================================= +# +# Copyright (C) 2016 - 2019 Continental Corporation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ========================= eCAL LICENSE ================================= + # returns 64 or 32 macro(bit_build out) if(CMAKE_SIZEOF_VOID_P EQUAL 8) diff --git a/thirdparty/cmakefunctions/cmake_functions/protoc_functions/protoc_generate_cpp.cmake b/cmake/protoc_functions/protoc_generate_cpp.cmake similarity index 100% rename from thirdparty/cmakefunctions/cmake_functions/protoc_functions/protoc_generate_cpp.cmake rename to cmake/protoc_functions/protoc_generate_cpp.cmake diff --git a/thirdparty/cmakefunctions/cmake_functions/protoc_functions/protoc_generate_files.cmake b/cmake/protoc_functions/protoc_generate_files.cmake similarity index 100% rename from thirdparty/cmakefunctions/cmake_functions/protoc_functions/protoc_generate_files.cmake rename to cmake/protoc_functions/protoc_generate_files.cmake diff --git a/thirdparty/cmakefunctions/cmake_functions/protoc_functions/protoc_generate_python.cmake b/cmake/protoc_functions/protoc_generate_python.cmake similarity index 100% rename from thirdparty/cmakefunctions/cmake_functions/protoc_functions/protoc_generate_python.cmake rename to cmake/protoc_functions/protoc_generate_python.cmake diff --git a/thirdparty/cmakefunctions/cmake_functions/qt/exclusive_command.cmake b/cmake/qt/exclusive_command.cmake similarity index 50% rename from thirdparty/cmakefunctions/cmake_functions/qt/exclusive_command.cmake rename to cmake/qt/exclusive_command.cmake index 673f4087b5..e55481b740 100644 --- a/thirdparty/cmakefunctions/cmake_functions/qt/exclusive_command.cmake +++ b/cmake/qt/exclusive_command.cmake @@ -1,3 +1,21 @@ +# ========================= eCAL LICENSE ================================= +# +# Copyright (C) 2016 - 2019 Continental Corporation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ========================= eCAL LICENSE ================================= + cmake_minimum_required(VERSION 3.17) #CMAKE_CURRENT_FUNCTION_LIST_DIR has been added in 3.17 # Define the function to add the PowerShell script as a post-build command diff --git a/thirdparty/cmakefunctions/cmake_functions/qt/exclusive_command.ps1 b/cmake/qt/exclusive_command.ps1 similarity index 100% rename from thirdparty/cmakefunctions/cmake_functions/qt/exclusive_command.ps1 rename to cmake/qt/exclusive_command.ps1 diff --git a/cmake/qt_msvc_path.cmake b/cmake/qt/qt_msvc_path.cmake similarity index 100% rename from cmake/qt_msvc_path.cmake rename to cmake/qt/qt_msvc_path.cmake diff --git a/thirdparty/cmakefunctions/cmake_functions/qt/qt_windeployqt.cmake b/cmake/qt/qt_windeployqt.cmake similarity index 100% rename from thirdparty/cmakefunctions/cmake_functions/qt/qt_windeployqt.cmake rename to cmake/qt/qt_windeployqt.cmake diff --git a/thirdparty/cmakefunctions/cmake_functions/qt/qt_windeployqt_threadsafe_cmake.bat.in b/cmake/qt/qt_windeployqt_threadsafe_cmake.bat.in similarity index 100% rename from thirdparty/cmakefunctions/cmake_functions/qt/qt_windeployqt_threadsafe_cmake.bat.in rename to cmake/qt/qt_windeployqt_threadsafe_cmake.bat.in diff --git a/cmake/submodule_dependencies.cmake b/cmake/submodule_dependencies.cmake index a232c35dcc..546f0aad8d 100644 --- a/cmake/submodule_dependencies.cmake +++ b/cmake/submodule_dependencies.cmake @@ -5,7 +5,6 @@ set(ecal_submodule_dependency_provider_root_dir ${CMAKE_CURRENT_LIST_DIR}) set(ecal_submodule_dependencies asio - CMakeFunctions CURL ecaludp fineftp diff --git a/thirdparty/cmakefunctions/cmake_functions/target_definitions/targets_protobuf.cmake b/cmake/target_definitions/targets_protobuf.cmake similarity index 100% rename from thirdparty/cmakefunctions/cmake_functions/target_definitions/targets_protobuf.cmake rename to cmake/target_definitions/targets_protobuf.cmake diff --git a/thirdparty/cmakefunctions/build-cmakefunctions.cmake b/thirdparty/cmakefunctions/build-cmakefunctions.cmake deleted file mode 100644 index 5cf9f8ff1c..0000000000 --- a/thirdparty/cmakefunctions/build-cmakefunctions.cmake +++ /dev/null @@ -1,3 +0,0 @@ -include_guard(GLOBAL) - -add_subdirectory("${CMAKE_CURRENT_LIST_DIR}/cmake_functions" "${eCAL_BINARY_DIR}/thirdparty/cmake_functions") diff --git a/thirdparty/cmakefunctions/cmake_functions/.gitignore b/thirdparty/cmakefunctions/cmake_functions/.gitignore deleted file mode 100644 index 6caf44c554..0000000000 --- a/thirdparty/cmakefunctions/cmake_functions/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -#Ignore build directories -/_build* diff --git a/thirdparty/cmakefunctions/cmake_functions/CMakeLists.txt b/thirdparty/cmakefunctions/cmake_functions/CMakeLists.txt deleted file mode 100644 index 4d44da2ae7..0000000000 --- a/thirdparty/cmakefunctions/cmake_functions/CMakeLists.txt +++ /dev/null @@ -1,44 +0,0 @@ -cmake_minimum_required(VERSION 3.5) - -include(cmake_functions.cmake) - -project(CMakeFunctions VERSION 0.4.1) - -include(GNUInstallDirs) -if (MSVC) -# Variable definitions -set(cmake_functions_install_cmake_dir cmake) -else (MSVC) -set(cmake_functions_install_cmake_dir "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}-${PROJECT_VERSION}") -endif (MSVC) -set(cmake_functions_config ${CMAKE_CURRENT_BINARY_DIR}/cmake/${PROJECT_NAME}Config.cmake) -set(cmake_functions_config_version ${CMAKE_CURRENT_BINARY_DIR}/cmake/${PROJECT_NAME}ConfigVersion.cmake) - -include(CMakePackageConfigHelpers) -configure_package_config_file( - "cmake/${PROJECT_NAME}Config.cmake.in" - "${cmake_functions_config}" - INSTALL_DESTINATION "${cmake_functions_install_cmake_dir}" - PATH_VARS cmake_functions_install_cmake_dir -) - -write_basic_package_version_file( - ${cmake_functions_config_version} - VERSION ${CMakeFunctions_VERSION} - COMPATIBILITY SameMajorVersion -) - - -install(FILES - "${cmake_functions_config}" - "${cmake_functions_config_version}" - "cmake_functions.cmake" - DESTINATION "${cmake_functions_install_cmake_dir}" -) - -foreach (f ${file_list}) - get_filename_component( dir ${f} DIRECTORY ) - install( FILES ${f} DESTINATION "${cmake_functions_install_cmake_dir}/${dir}" ) -endforeach() - -include(cmake/cpack_variables.cmake) diff --git a/thirdparty/cmakefunctions/cmake_functions/cmake/CMakeFunctionsConfig.cmake.in b/thirdparty/cmakefunctions/cmake_functions/cmake/CMakeFunctionsConfig.cmake.in deleted file mode 100644 index c773417ae7..0000000000 --- a/thirdparty/cmakefunctions/cmake_functions/cmake/CMakeFunctionsConfig.cmake.in +++ /dev/null @@ -1,4 +0,0 @@ -@PACKAGE_INIT@ - -# make all runtask helper functions available -include("@PACKAGE_cmake_functions_install_cmake_dir@/cmake_functions.cmake") \ No newline at end of file diff --git a/thirdparty/cmakefunctions/cmake_functions/cmake/cpack_variables.cmake b/thirdparty/cmakefunctions/cmake_functions/cmake/cpack_variables.cmake deleted file mode 100644 index 5358bb786b..0000000000 --- a/thirdparty/cmakefunctions/cmake_functions/cmake/cpack_variables.cmake +++ /dev/null @@ -1,12 +0,0 @@ -include(InstallRequiredSystemLibraries) -set(CPACK_PACKAGE_NAME ${PROJECT_NAME}-dev) -set(CPACK_PACKAGE_DESCRIPTION_SUMMARY ${PROJECT_NAME}) -set(CPACK_PACKAGE_VENDOR "Continental Automotive Systems") -set(CPACK_PACKAGE_VERSION_MAJOR ${PROJECT_VERSION_MAJOR}) -set(CPACK_PACKAGE_VERSION_MINOR ${PROJECT_VERSION_MINOR}) -set(CPACK_PACKAGE_VERSION_PATCH ${PROJECT_VERSION_PATCH}) -set(CPACK_PACKAGE_CONTACT "kerstin.keller@continental-corporation.com") -set(CPACK_SOURCE_STRIP_FILES "") -set(CPACK_SOURCE_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}") - -include(CPack)