Просмотр исходного кода

Merge topic 'patch-FindXMLRPC'

826a3d8c3f FindXMLRPC: Update documentation

Acked-by: Kitware Robot <[email protected]>
Merge-request: !10558
Brad King 10 месяцев назад
Родитель
Сommit
d14fd03e8f
1 измененных файлов с 59 добавлено и 16 удалено
  1. 59 16
      Modules/FindXMLRPC.cmake

+ 59 - 16
Modules/FindXMLRPC.cmake

@@ -5,31 +5,74 @@
 FindXMLRPC
 ----------
 
-Find xmlrpc
+Finds the native XML-RPC library for C and C++.  XML-RPC is a standard network
+protocol that enables remote procedure calls (RPC) between systems.  It encodes
+requests and responses in XML and uses HTTP as the transport mechanism.
 
-Find the native XMLRPC headers and libraries.
+Components
+^^^^^^^^^^
 
-::
+The XML-RPC C/C++ library consists of various features (modules) that provide
+specific functionality.  The availability of these features depends on the
+installed XML-RPC library version and system configuration.  Some features also
+have dependencies on others.
 
-  XMLRPC_INCLUDE_DIRS      - where to find xmlrpc.h, etc.
-  XMLRPC_LIBRARIES         - List of libraries when using xmlrpc.
-  XMLRPC_FOUND             - True if xmlrpc found.
+To list the available features on a system, the ``xmlrpc-c-config`` command-line
+utility can be used.
 
-XMLRPC modules may be specified as components for this find module.
-Modules may be listed by running "xmlrpc-c-config".  Modules include:
+In CMake, these features can be specified as components with the
+``find_package()`` command:
 
-::
-
-  c++            C++ wrapper code
-  libwww-client  libwww-based client
-  cgi-server     CGI-based server
-  abyss-server   ABYSS-based server
+.. code-block:: cmake
 
-Typical usage:
+  find_package(XMLRPC [COMPONENTS <components>...])
+
+Components may be:
+
+``c++2``
+  C++ wrapper API, replacing the legacy ``c++`` feature.
+``c++``
+  The legacy C++ wrapper API (superseded by ``c++2``).
+``client``
+  XML-RPC client functions (also available as the legacy libwww-based feature
+  named ``libwww-client``).
+``cgi-server``
+  CGI-based server functions.
+``abyss-server``
+  Abyss-based server functions.
+``pstream-server``
+  The pstream-based server functions.
+``server-util``
+  Basic server functions (they are automatically included with ``*-server``
+  features).
+``abyss``
+  Abyss HTTP server (not needed with ``abyss-server``).
+``openssl``
+  OpenSSL convenience functions.
+
+Result Variables
+^^^^^^^^^^^^^^^^
+
+This module defines the following variables:
+
+``XMLRPC_INCLUDE_DIRS``
+  Include directories containing ``xmlrpc.h`` and other headers needed to use
+  the XML-RPC library.
+``XMLRPC_LIBRARIES``
+  List of libraries needed for linking to XML-RPC library and its requested
+  features.
+``XMLRPC_FOUND``
+  Boolean indicating whether the XML-RPC library and all its requested
+  components are found.
+
+Examples
+^^^^^^^^
+
+Finding XML-RPC library and its ``client`` feature to use in the project:
 
 .. code-block:: cmake
 
-  find_package(XMLRPC REQUIRED libwww-client)
+  find_package(XMLRPC REQUIRED COMPONENTS client)
 #]=======================================================================]
 
 # First find the config script from which to obtain other values.