From 4bd3519e8928929900a602a59cbe9430f5012a8a Mon Sep 17 00:00:00 2001 From: Brad King Date: Fri, 24 Jan 2025 10:37:28 -0500 Subject: CPack: Avoid mentioning internal CMake module in documentation --- Modules/CPack.cmake | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Modules/CPack.cmake b/Modules/CPack.cmake index 3afe082..aecd125 100644 --- a/Modules/CPack.cmake +++ b/Modules/CPack.cmake @@ -479,7 +479,7 @@ The following variables are for advanced uses of CPack: Specify the ``readelf`` executable path used by CPack. The default value will be taken from the ``CMAKE_READELF`` variable, if set, - which may be populated by an internal CMake module. If ``CMAKE_READELF`` + which may be populated CMake when enabling languages. If ``CMAKE_READELF`` is not set, CPack will use :command:`find_program` to determine the ``readelf`` path when needed. @@ -489,7 +489,7 @@ The following variables are for advanced uses of CPack: Specify the ``objcopy`` executable path used by CPack. The default value will be taken from the ``CMAKE_OBJCOPY`` variable, if set, - which may be populated by an internal CMake module. If ``CMAKE_OBJCOPY`` + which may be populated by CMake when enabling languages. If ``CMAKE_OBJCOPY`` is not set, CPack will use :command:`find_program` to determine the ``objcopy`` path when needed. @@ -499,7 +499,7 @@ The following variables are for advanced uses of CPack: Specify the ``objdump`` executable path used by CPack. The default value will be taken from the ``CMAKE_OBJDUMP`` variable, if set, - which may be populated by an internal CMake module. If ``CMAKE_OBJDUMP`` + which may be populated by CMake when enabling languages. If ``CMAKE_OBJDUMP`` is not set, CPack will use :command:`find_program` to determine the ``objdump`` path when needed. -- cgit v0.12 From dc7aabf4d0cdc0a07f39f9de29c57a7b2e9d4be5 Mon Sep 17 00:00:00 2001 From: Peter Kokot Date: Thu, 23 Jan 2025 17:34:19 +0100 Subject: Help: Document CMAKE_OBJDUMP variable --- Help/command/file.rst | 4 ++-- Help/manual/cmake-variables.7.rst | 1 + Help/variable/CMAKE_OBJDUMP.rst | 16 ++++++++++++++++ Modules/CMakeFindBinUtils.cmake | 1 + Modules/CPack.cmake | 2 +- Modules/GetPrerequisites.cmake | 3 ++- 6 files changed, 23 insertions(+), 4 deletions(-) create mode 100644 Help/variable/CMAKE_OBJDUMP.rst diff --git a/Help/command/file.rst b/Help/command/file.rst index 135f3ed..dc9e27b 100644 --- a/Help/command/file.rst +++ b/Help/command/file.rst @@ -1337,7 +1337,7 @@ Handling Runtime Binaries the actual path to ``objdump``, ``dumpbin``, or ``otool``. If this variable is not specified, it is determined by the value of - ``CMAKE_OBJDUMP`` if set, else by system introspection. + :variable:`CMAKE_OBJDUMP` variable if set, else by system introspection. .. versionadded:: 3.18 - Use ``CMAKE_OBJDUMP`` if set. + Uses :variable:`CMAKE_OBJDUMP` if set. diff --git a/Help/manual/cmake-variables.7.rst b/Help/manual/cmake-variables.7.rst index 4b96f12..9421da1 100644 --- a/Help/manual/cmake-variables.7.rst +++ b/Help/manual/cmake-variables.7.rst @@ -93,6 +93,7 @@ Variables that Provide Information /variable/CMAKE_MINOR_VERSION /variable/CMAKE_NETRC /variable/CMAKE_NETRC_FILE + /variable/CMAKE_OBJDUMP /variable/CMAKE_PARENT_LIST_FILE /variable/CMAKE_PATCH_VERSION /variable/CMAKE_PROJECT_DESCRIPTION diff --git a/Help/variable/CMAKE_OBJDUMP.rst b/Help/variable/CMAKE_OBJDUMP.rst new file mode 100644 index 0000000..9a01beb --- /dev/null +++ b/Help/variable/CMAKE_OBJDUMP.rst @@ -0,0 +1,16 @@ +CMAKE_OBJDUMP +------------- + +Path to the ``objdump`` executable on the host system. This tool, typically +part of the Binutils collection on Unix-like systems, provides information +about compiled object files. + +This cache variable may be populated by CMake when project languages are +enabled using the :command:`project` or :command:`enable_language` commands. + +See Also +^^^^^^^^ + +* The :command:`file(GET_RUNTIME_DEPENDENCIES)` command provides a more general + way to get information from runtime binaries. +* The :variable:`CPACK_OBJDUMP_EXECUTABLE` variable. diff --git a/Modules/CMakeFindBinUtils.cmake b/Modules/CMakeFindBinUtils.cmake index 8784d83..8f59a18 100644 --- a/Modules/CMakeFindBinUtils.cmake +++ b/Modules/CMakeFindBinUtils.cmake @@ -15,6 +15,7 @@ # CMAKE_RANLIB # CMAKE_LINKER # CMAKE_MT +# CMAKE_OBJDUMP # CMAKE_STRIP # CMAKE_INSTALL_NAME_TOOL diff --git a/Modules/CPack.cmake b/Modules/CPack.cmake index aecd125..f6d02d5 100644 --- a/Modules/CPack.cmake +++ b/Modules/CPack.cmake @@ -498,7 +498,7 @@ The following variables are for advanced uses of CPack: .. versionadded:: 3.25 Specify the ``objdump`` executable path used by CPack. - The default value will be taken from the ``CMAKE_OBJDUMP`` variable, if set, + The default value will be taken from the :variable:`CMAKE_OBJDUMP` variable, which may be populated by CMake when enabling languages. If ``CMAKE_OBJDUMP`` is not set, CPack will use :command:`find_program` to determine the ``objdump`` path when needed. diff --git a/Modules/GetPrerequisites.cmake b/Modules/GetPrerequisites.cmake index e866512..d917341 100644 --- a/Modules/GetPrerequisites.cmake +++ b/Modules/GetPrerequisites.cmake @@ -26,7 +26,8 @@ files: otool (Mac OSX) .. versionchanged:: 3.16 - The tool specified by ``CMAKE_OBJDUMP`` will be used, if set. + The tool specified by the :variable:`CMAKE_OBJDUMP` variable + will be used, if set. The following functions are provided by this module: -- cgit v0.12