Commit d6877e6c authored by Daniel Pfeifer's avatar Daniel Pfeifer

Don't include CMakeParseArguments

The cmake_parse_arguments command is builtin with version 3.5.
The CMakeParseArguments module is empty and exists for backwards
compatibility with CMake 3.4 and lower.

Remove the includes of CMakeParseArguments from CMake's modules.
The modules are always used with the current version of CMake.

Leave the includes in the tests, as the tests may be run with an older
version of CMake.
parent 3e5fbbd6
Pipeline #41999 passed with stage
......@@ -45,7 +45,6 @@
set(_MS_MINGW_SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR})
include(CheckLanguage)
include(ExternalProject)
include(CMakeParseArguments)
function(_setup_mingw_config_and_build source_dir build_dir)
# Look for a MinGW gfortran.
......
......@@ -11,8 +11,6 @@ function(_readFile file)
set(_compiler_id_pp_test_${CompilerId} ${_compiler_id_pp_test} PARENT_SCOPE)
endfunction()
include(${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake)
function(compiler_id_detection outvar lang)
if (NOT lang STREQUAL Fortran AND NOT lang STREQUAL CSharp)
......
......@@ -37,9 +37,6 @@
# LIBRARIES ${CMAKE_REQUIRED_LIBRARIES}
# CONFIGURATION "${CMAKE_TRY_COMPILE_CONFIGURATION}" )
include(${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake)
function(CMAKE_EXPAND_IMPORTED_TARGETS _RESULT )
set(options )
......
......@@ -201,9 +201,6 @@
#
# check_required_components(Foo)
include(CMakeParseArguments)
include(WriteBasicConfigVersionFile)
macro(WRITE_BASIC_PACKAGE_VERSION_FILE)
......
......@@ -39,8 +39,6 @@
#
# -- CMAKE_C_COMPILER="/usr/bin/gcc" ; CMAKE_MAJOR_VERSION="2" ; DOES_NOT_EXIST=""
include(CMakeParseArguments)
function(CMAKE_PRINT_VARIABLES)
set(msg "")
foreach(var ${ARGN})
......
......@@ -630,10 +630,6 @@ if(NOT CPackComponent_CMake_INCLUDED)
include(CPackComponent)
endif()
if(NOT __CMAKE_PARSE_ARGUMENTS_INCLUDED)
include(CMakeParseArguments)
endif()
# Resolve full filename for script file
macro(_cpack_ifw_resolve_script _variable)
set(_ifw_script_macro ${_variable})
......
......@@ -65,7 +65,6 @@
# Suppress non-error messages that otherwise would have been
# printed out by this function.
include(CMakeParseArguments)
function(ctest_coverage_collect_gcov)
set(options QUIET GLOB DELETE)
set(oneValueArgs TARBALL SOURCE BUILD GCOV_COMMAND)
......
......@@ -26,9 +26,6 @@ Functions
#]=======================================================================]
include("${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake")
function(_FS_GET_FEATURE_SUMMARY _property _var _includeQuiet)
set(_type "ANY")
......
......@@ -84,8 +84,6 @@
find_program(BISON_EXECUTABLE NAMES bison win_bison DOC "path to the bison executable")
mark_as_advanced(BISON_EXECUTABLE)
include(CMakeParseArguments)
if(BISON_EXECUTABLE)
# the bison commands should be executed with the C locale, otherwise
# the message (which are parsed) may be translated
......
......@@ -107,8 +107,6 @@ find_path(FLEX_INCLUDE_DIR FlexLexer.h
mark_as_advanced(FL_LIBRARY FLEX_INCLUDE_DIR)
include(${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake)
set(FLEX_INCLUDE_DIRS ${FLEX_INCLUDE_DIR})
set(FLEX_LIBRARIES ${FL_LIBRARY})
......
......@@ -165,7 +165,6 @@
#=============================================================
include(${CMAKE_CURRENT_LIST_DIR}/SelectLibraryConfigurations.cmake)
include(${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake)
function(_GTK2_GET_VERSION _OUT_major _OUT_minor _OUT_micro _gtkversion_hdr)
file(STRINGS ${_gtkversion_hdr} _contents REGEX "#define GTK_M[A-Z]+_VERSION[ \t]+")
......
......@@ -77,8 +77,6 @@ FIND_PACKAGE_HANDLE_STANDARD_ARGS(Gettext
REQUIRED_VARS GETTEXT_MSGMERGE_EXECUTABLE GETTEXT_MSGFMT_EXECUTABLE
VERSION_VAR GETTEXT_VERSION_STRING)
include(${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake)
function(_GETTEXT_GET_UNIQUE_TARGET_NAME _name _unique_name)
set(propertyName "_GETTEXT_UNIQUE_COUNTER_${_name}")
get_property(currentCounter GLOBAL PROPERTY "${propertyName}")
......
......@@ -130,7 +130,6 @@ message.
#]=======================================================================]
include(${CMAKE_CURRENT_LIST_DIR}/FindPackageMessage.cmake)
include(${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake)
# internal helper macro
macro(_FPHSA_FAILURE_MESSAGE _msg)
......
......@@ -119,9 +119,6 @@
#
# This is deprecated. Use SQUISH_V3_ADD_TEST() if you are using Squish 3.x instead.
include(CMakeParseArguments)
set(SQUISH_INSTALL_DIR_STRING "Directory containing the bin, doc, and lib directories for Squish; this should be the root of the installation directory.")
set(SQUISH_SERVER_EXECUTABLE_STRING "The squishserver executable program.")
set(SQUISH_CLIENT_EXECUTABLE_STRING "The squishclient executable program.")
......
......@@ -184,7 +184,6 @@
# :prop_tgt:`CXX_VISIBILITY_PRESET <<LANG>_VISIBILITY_PRESET>` and
# :prop_tgt:`VISIBILITY_INLINES_HIDDEN` instead.
include(CMakeParseArguments)
include(CheckCXXCompilerFlag)
# TODO: Install this macro separately?
......
......@@ -403,8 +403,6 @@
# Sets the directory where the header files will be generated. Same behavior as option
# '-d' of javah tool. If not specified, ${CMAKE_CURRENT_BINARY_DIR} is used as output directory.
include(${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake)
function (__java_copy_file src dest comment)
add_custom_command(
OUTPUT ${dest}
......
......@@ -231,8 +231,6 @@ endmacro()
macro(SWIG_ADD_LIBRARY name)
include(CMakeParseArguments)
set(options "")
set(oneValueArgs LANGUAGE
TYPE)
......@@ -340,4 +338,3 @@ macro(SWIG_LINK_LIBRARIES name)
message(SEND_ERROR "Cannot find Swig library \"${name}\".")
endif()
endmacro()
......@@ -18,8 +18,6 @@
#
# Deprecated, see WRITE_BASIC_PACKAGE_VERSION_FILE(), it is identical.
include(CMakeParseArguments)
function(WRITE_BASIC_CONFIG_VERSION_FILE _filename)
set(options )
......
......@@ -216,7 +216,6 @@
# CompatSupport_DEPRECATED=
# )
include(${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake)
include(${CMAKE_CURRENT_LIST_DIR}/CMakeCompilerIdDetection.cmake)
function(_load_compiler_variables CompilerId lang)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment