Christian Pfeiffer 9a58e69cc8 FindMPI: Modernization from ground up
This is a near-total rewrite of FindMPI implementing the following
features:

Environmental improvements:

- C++ settings can now be picked from C settings if no dedicated C++
  settings are found (some installs of IBM Platform MPI)
- Fortran settings can now be found on MPICH-1, MVAPICH-1, Microsoft
  MPI and MPICH-2 on Windows.

- Improved flag procession logic: Flags related to security enhancements
  of MPI itself, and unrelated to MPI usage (-fstack-protector-strong on
  e.g. RHEL 7 for MPICH and MVAPICH) will be filtered out properly now.
  -pthread is now being handled. -fno-strict-aliasing, which may be needed
  while compiling MVAPICH (e.g. RHEL 7's MVAPICH package) is also
  filtered.

Features added:

- MPI version can be determined for each language and is exposed as the
  package version
- MPI functionality is being tested to ensure the correctness of
  settings
- MPI-2 C++ bindings can be suppressed if desired by the project or
  user. For older MPIs, this often resolves issues and eliminated the
  infamous SEEK_SET trouble.
- MPI-2 C++ bindings are now being searched for and exposed by a
  variable if detected.
- Fortran support now does not make assumptions over the MPI present and
  works with ILP64 MPI implementations.
- Fortran now exposes which bindings (mpif.h, mpi/mpi_f08 modules) are
  available
- MPI detection can now work hybridly, which for example permits using the
  Fortran modules shipped with some compiler suites together with MPI
  (e.g. PGI on Windows shipping MSMPI modules)
- Ability to determine MPI library version (*requires* try_run, caution)
  upon request
- Ability to determine Fortran capabilities from MPI-3 for each of the
  bindings (subarrays, asynchronous attribute protecting entities) (also
  requires try_run)

Fine grained control over the search process:

- Possibility to selectively enable and disable steps like compiler
  wrapper search and guessing. Permits picking Microsoft MPI over Intel
  MPI if both are loaded (previously not possible without removing the
  IMPI compiler wrappers from the environment)
- Ability to pick MPICH2 over MSMPI (previously the first one located
  was taken)
- A user may now pass compiler flags to the compiler wrapper script,
  enabling much more flexibility. This permits for example linking the
  Intel MPI debug runtime, static linking, ILP64 with Fortran,
  linking tracing, ...
- A user may define a suffix for all MPI binaries that are being looked
  for (useful on Debian/Ubuntu where the alternative MPI installs are each
  appended with their name, e.g. mpicc.mpich and mpicc.lam)

Cache variable improvements

- Instead of the previous plural cache variables a list-of-variables
  approach is now in place. Permits correcting individual variables
  instead of having to wade through a list, also speeds up the search
  process and increases comfort by eliminating duplicate entries in
  LIBRARIES over languages
- MPIEXEC was corrected to MPIEXEC_EXECUTABLE in order to fix the
  grouping in the CMake GUI for the variable (previously ungrouped)
2017-09-15 14:55:08 +02:00

CMake
*****

Introduction
============

CMake is a cross-platform, open-source build system generator.
For full documentation visit the `CMake Home Page`_ and the
`CMake Documentation Page`_.

.. _`CMake Home Page`: https://cmake.org
.. _`CMake Documentation Page`: https://cmake.org/cmake/help/documentation.html

CMake is maintained and supported by `Kitware`_ and developed in
collaboration with a productive community of contributors.

.. _`Kitware`: http://www.kitware.com/cmake

License
=======

CMake is distributed under the OSI-approved BSD 3-clause License.
See `Copyright.txt`_ for details.

.. _`Copyright.txt`: Copyright.txt

Building CMake
==============

Supported Platforms
-------------------

* Microsoft Windows
* Apple macOS
* Linux
* FreeBSD
* OpenBSD
* Solaris
* AIX

Other UNIX-like operating systems may work too out of the box, if not
it should not be a major problem to port CMake to this platform.
Subscribe and post to the `CMake Users List`_ to ask if others have
had experience with the platform.

.. _`CMake Users List`: https://cmake.org/mailman/listinfo/cmake

Building CMake from Scratch
---------------------------

UNIX/Mac OSX/MinGW/MSYS/Cygwin
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

You need to have a C++ compiler (supporting C++11) and a ``make`` installed.
Run the ``bootstrap`` script you find in the source directory of CMake.
You can use the ``--help`` option to see the supported options.
You may use the ``--prefix=<install_prefix>`` option to specify a custom
installation directory for CMake. You can run the ``bootstrap`` script from
within the CMake source directory or any other build directory of your
choice. Once this has finished successfully, run ``make`` and
``make install``.  In summary::

 $ ./bootstrap && make && make install

Windows
^^^^^^^

You need to download and install a binary release of CMake in order to build
CMake.  You can get these releases from the `CMake Download Page`_ .  Then
proceed with the instructions below.

.. _`CMake Download Page`: https://cmake.org/cmake/resources/software.html

Building CMake with CMake
-------------------------

You can build CMake as any other project with a CMake-based build system:
run the installed CMake on the sources of this CMake with your preferred
options and generators. Then build it and install it.
For instructions how to do this, see documentation on `Running CMake`_.

.. _`Running CMake`: https://cmake.org/cmake/help/runningcmake.html

Reporting Bugs
==============

If you have found a bug:

1. If you have a patch, please read the `CONTRIBUTING.rst`_ document.

2. Otherwise, please join the `CMake Users List`_ and ask about
   the expected and observed behaviors to determine if it is really
   a bug.

3. Finally, if the issue is not resolved by the above steps, open
   an entry in the `CMake Issue Tracker`_.

.. _`CMake Issue Tracker`: https://gitlab.kitware.com/cmake/cmake/issues

Contributing
============

See `CONTRIBUTING.rst`_ for instructions to contribute.

.. _`CONTRIBUTING.rst`: CONTRIBUTING.rst
Description
Patched versions of CMake for ReactOS needs
Readme 113 MiB
Languages
C 44.8%
C++ 29.2%
CMake 23.2%
Roff 0.9%
Shell 0.4%
Other 1.1%