Unverified Commit 3b73b88b authored by Axel Kohlmeyer's avatar Axel Kohlmeyer Committed by GitHub
Browse files

Merge pull request #1926 from akohlmey/doc-cleanup

Documentation cleanup
parents 33996d9b 010b1f74
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1383,8 +1383,8 @@ cmake -C ../cmake/presets/all_on.cmake -C ../cmake/presets/nolib.cmake -D PKG_GP
  Some potentials that are also implemented in the Yet Another Force Field (YAFF) code.
  The expressions and their use are discussed in the following papers:
  <ul>
    <li><a href="http://dx.doi.org/10.1002/jcc.23877" target="_blank">Vanduyfhuys et al., J. Comput. Chem., 36 (13), 1015-1027 (2015)</a></li>
    <li><a href="http://dx.doi.org/10.1002/jcc.25173" target="_blank">Vanduyfhuys et al., J. Comput. Chem., 39 (16), 999-1011 (2018)</a></li>
    <li><a href="https://doi.org/10.1002/jcc.23877" target="_blank">Vanduyfhuys et al., J. Comput. Chem., 36 (13), 1015-1027 (2015)</a></li>
    <li><a href="https://doi.org/10.1002/jcc.25173" target="_blank">Vanduyfhuys et al., J. Comput. Chem., 39 (16), 999-1011 (2018)</a></li>
  </ul>
  </td>
  <td>
+1 −1
Original line number Diff line number Diff line
@@ -78,7 +78,7 @@ html: $(ANCHORCHECK) $(MATHJAX)
	@cp -r src/PDF html/PDF
	@cp -r src/USER html/USER
	@mkdir -p html/JPG
	@cp `grep -A2 '\.\. image::' src/*.rst | grep ':target:' | sed -e 's,.*:target: JPG/,src/JPG/,' | sort | uniq` html/JPG/
	@cp `grep -A2 '\.\. .*image::' src/*.rst | grep ':target:' | sed -e 's,.*:target: JPG/,src/JPG/,' | sort | uniq` html/JPG/
	@rm -rf html/PDF/.[sg]*
	@rm -rf html/USER/.[sg]*
	@rm -rf html/USER/*/.[sg]*
+0 −1
Original line number Diff line number Diff line
@@ -8,7 +8,6 @@ for use with GNU make or gmake, or a build environment generated by CMake
alternative you can download a package with pre-built executables
as described on the :doc:`Install <Install>` doc page.


.. toctree::
   :maxdepth: 1

+3 −20
Original line number Diff line number Diff line
@@ -10,10 +10,8 @@ CMake and make:
* :ref:`Build the LAMMPS documentation <doc>`
* :ref:`Install LAMMPS after a build <install>`


----------


.. _serial:

Serial vs parallel build
@@ -57,7 +55,6 @@ The build with traditional makefiles has to be done inside the source folder `sr
   make serial             # serial build, produces lmp_serial using Makefile/serial
   make mybox              # uses Makefile.mybox to produce lmp_mybox


Any "make machine" command will look up the make settings from a file
Makefile.machine, create a folder Obj\_machine with all objects and
generated files and an executable called *lmp\_machine*\ .  The standard
@@ -154,10 +151,8 @@ while dropping all 'shared()' directives. The script
'src/USER-OMP/hack\_openmp\_for\_pgi\_gcc9.sh' can be used to automate
this conversion.


----------


.. _compile:

Choice of compiler and compile/link options
@@ -204,7 +199,6 @@ for all the C++ files:
   -D CMAKE_C_FLAGS=string               # flags to use with C compiler
   -D CMAKE_Fortran_FLAGS=string         # flags to use with Fortran compiler


A few example command lines are:

.. code-block:: bash
@@ -323,7 +317,7 @@ Several options are available and "mode=exe" is the default.
.. code-block:: bash

   make machine               # build LAMMPS executable lmp_machine
   mkae mode=exe machine      # same as "make machine"
   make mode=exe machine      # same as "make machine"
   make mode=lib machine      # build LAMMPS static lib liblammps_machine.a
   make mode=shlib machine    # build LAMMPS shared lib liblammps_machine.so
   make mode=shexe machine    # same as "mode=exe" but uses objects from "mode=shlib"
@@ -347,7 +341,6 @@ build may generate an error. This means you will need to install a
shared library version of the auxiliary library.  The build instructions
for the library should tell you how to do this.


As an example, here is how to build and install the `MPICH library
<mpich_>`_, a popular open-source version of MPI, as a shared library
in the default /usr/local/lib location:
@@ -377,7 +370,6 @@ recommended to ensure the integrity of the system software installation.

----------


.. _doc:

Build the LAMMPS documentation
@@ -412,7 +404,6 @@ LAMMPS source distribution.
  make package_check # check for complete and consistent package lists
  make spelling      # spell-check the manual


Thus "make html" will create a "doc/html" directory with the HTML format
manual pages so that you can browse them with a web browser locally on
your system.
@@ -421,8 +412,7 @@ your system.

   You can also download a tarball of the documentation for the
   current LAMMPS version (HTML and PDF files), from the website
   `download page <http://lammps.sandia.gov/download.html>`_.

   `download page <https://lammps.sandia.gov/download.html>`_.

**CMake build option**\ :

@@ -436,10 +426,8 @@ the "install" step when installing LAMMPS after the CMake build via

   -D BUILD_DOC=value       # yes or no (default)


----------


.. _tools:

Build LAMMPS tools
@@ -450,7 +438,6 @@ using CMake or Make.

**CMake build3**\ :


.. code-block:: bash

   -D BUILD_TOOLS=value       # yes or no (default)
@@ -460,7 +447,6 @@ The generated binaries will also become part of the LAMMPS installation

**Traditional make**\ :


.. code-block:: bash

   cd lammps/tools
@@ -470,10 +456,8 @@ The generated binaries will also become part of the LAMMPS installation
   make micelle2d        # build only micelle2d tool
   make thermo_extract   # build only thermo_extract tool


----------


.. _install:

Install LAMMPS after a build
@@ -487,7 +471,6 @@ you want to copy files to is protected.

**CMake build**\ :


.. code-block:: bash

   cmake -D CMAKE_INSTALL_PREFIX=path [options ...] ../cmake
+1 −21
Original line number Diff line number Diff line
@@ -9,17 +9,14 @@ Richard Berger (Temple U) has also written a `more comprehensive guide <https://
for how to use CMake to build LAMMPS.  If you are new to CMake it is a
good place to start.


----------


Building LAMMPS with CMake is a two-step process.  First you use CMake
to create a build environment in a new directory.  On Linux systems,
this will be based on makefiles for use with make.  Then you use the
make command to build LAMMPS, which uses the created
Makefile(s). Example:


.. code-block:: bash

   cd lammps                        # change to the LAMMPS distribution directory
@@ -51,7 +48,6 @@ even more.
After compilation, you may optionally install the LAMMPS executable into
your system with:


.. code-block:: bash

   make install    # optional, copy LAMMPS executable & library elsewhere
@@ -62,10 +58,8 @@ manpages, potential and force field files. The location of the installation
tree is set by the CMake variable "CMAKE\_INSTALL\_PREFIX" which defaults
to ${HOME}/.local


----------


There are 3 variants of CMake: a command-line version (cmake), a text mode
UI version (ccmake), and a graphical GUI version (cmake-GUI).  You can use
any of them interchangeably to configure and create the LAMMPS build
@@ -106,13 +100,10 @@ ccmake or cmake-gui) again from the same build directory and alter
various options; see details below.  Or you can remove the entire build
folder, recreate the directory and start over.


----------


**Command-line version of CMake**\ :


.. code-block:: bash

   cmake [options ...] /path/to/lammps/cmake  # build from any dir
@@ -121,10 +112,9 @@ folder, recreate the directory and start over.
The cmake command takes one required argument, which is the LAMMPS
cmake directory which contains the CMakeLists.txt file.

The argument can be preceeded or followed by various CMake
The argument can be prefixed or followed by various CMake
command-line options.  Several useful ones are:


.. code-block:: bash

   -D CMAKE_INSTALL_PREFIX=path  # where to install LAMMPS executable/lib if desired
@@ -168,13 +158,10 @@ In these cases it is usually better to first remove all the
files/directories in the build directory, or start with a fresh build
directory.


----------


**Curses version (terminal-style menu) of CMake**\ :


.. code-block:: bash

   ccmake ../cmake
@@ -186,13 +173,10 @@ required to edit some of the entries of CMake configuration variables
in between.  Please see the `ccmake manual <https://cmake.org/cmake/help/latest/manual/ccmake.1.html>`_ for
more information.


----------


**GUI version of CMake**\ :


.. code-block:: bash

   cmake-gui ../cmake
@@ -205,15 +189,12 @@ edit some of the entries of CMake configuration variables in between.
Please see the `cmake-gui manual <https://cmake.org/cmake/help/latest/manual/cmake-gui.1.html>`_
for more information.


----------


**Installing CMake**

Check if your machine already has CMake installed:


.. code-block:: bash

   which cmake             # do you have it?
@@ -223,7 +204,6 @@ Check if your machine already has CMake installed:
On clusters or supercomputers which use environment modules to manage
software packages, do this:


.. code-block:: bash

   module list            # is a module for cmake already loaded?
Loading