Unverified Commit ca6c1c4b authored by Jacob Gissinger's avatar Jacob Gissinger Committed by GitHub
Browse files

Merge pull request #38 from lammps/master

rebase
parents 482e120a c26b2078
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -126,3 +126,6 @@ python/* @rbberger
doc/utils/*/*         @rbberger
doc/Makefile          @rbberger
doc/README            @rbberger

# for releases
src/version.h         @sjplimp
+11 −8
Original line number Diff line number Diff line
@@ -171,7 +171,7 @@ set(LAMMPS_DEPS)
set(LAMMPS_API_DEFINES)

set(DEFAULT_PACKAGES ASPHERE BODY CLASS2 COLLOID COMPRESS DIPOLE GRANULAR
  KSPACE MANYBODY MC MEAM MESSAGE MISC MOLECULE PERI REAX REPLICA RIGID SHOCK
  KSPACE MANYBODY MC MESSAGE MISC MOLECULE PERI REPLICA RIGID SHOCK
  SPIN SNAP SRD KIM PYTHON MSCG MPIIO VORONOI POEMS LATTE USER-ATC USER-AWPMD
  USER-BOCS USER-CGDNA USER-MESO USER-CGSDK USER-COLVARS USER-DIFFRACTION
  USER-DPD USER-DRUDE USER-EFF USER-FEP USER-H5MD USER-LB USER-MANIFOLD
@@ -191,11 +191,11 @@ endforeach()
######################################################
# packages with special compiler needs or external libs
######################################################
if(PKG_REAX OR PKG_MEAM OR PKG_USER-QUIP OR PKG_USER-QMMM OR PKG_LATTE OR PKG_USER-SCAFACOS)
if(PKG_USER-QUIP OR PKG_USER-QMMM OR PKG_LATTE OR PKG_USER-SCAFACOS)
  enable_language(Fortran)
endif()

if(PKG_MEAM OR PKG_USER-H5MD OR PKG_USER-QMMM OR PKG_USER-SCAFACOS)
if(PKG_USER-H5MD OR PKG_USER-QMMM OR PKG_USER-SCAFACOS)
  enable_language(C)
endif()

@@ -221,7 +221,7 @@ else()
endif()


set(LAMMPS_SIZES "smallbig" CACHE STRING "LAMMPS size limit")
set(LAMMPS_SIZES "smallbig" CACHE STRING "LAMMPS integer sizes (smallsmall: all 32-bit, smallbig: 64-bit #atoms #timesteps, bigbig: also 64-bit imageint, 64-bit atom ids)")
set(LAMMPS_SIZES_VALUES smallbig bigbig smallsmall)
set_property(CACHE LAMMPS_SIZES PROPERTY STRINGS ${LAMMPS_SIZES_VALUES})
validate_option(LAMMPS_SIZES LAMMPS_SIZES_VALUES)
@@ -354,7 +354,7 @@ if(PKG_KSPACE)
  endif()
endif()

if(PKG_MSCG OR PKG_USER-ATC OR PKG_USER-AWPMD OR PKG_USER-QUIP OR PKG_LATTE OR PKG_USER-PLUMED)
if(PKG_MSCG OR PKG_USER-ATC OR PKG_USER-AWPMD OR PKG_USER-QUIP OR PKG_LATTE)
  find_package(LAPACK)
  find_package(BLAS)
  if(NOT LAPACK_FOUND OR NOT BLAS_FOUND)
@@ -569,7 +569,7 @@ if(PKG_USER-PLUMED)
    if(PLUMED_MODE STREQUAL "STATIC")
      add_definitions(-D__PLUMED_WRAPPER_CXX=1)
      list(APPEND LAMMPS_LINK_LIBS ${PLUMED_INSTALL_DIR}/lib/plumed/obj/kernel.o
        "${PLUMED_INSTALL_DIR}/lib/plumed/obj/PlumedStatic.o" ${GSL_LIBRARIES} ${CMAKE_DL_LIBS} ${LAPACK_LIBRARIES})
        "${PLUMED_INSTALL_DIR}/lib/plumed/obj/PlumedStatic.o" ${GSL_LIBRARIES} ${CMAKE_DL_LIBS})
    elseif(PLUMED_MODE STREQUAL "SHARED")
      list(APPEND LAMMPS_LINK_LIBS ${PLUMED_INSTALL_DIR}/lib/libplumed.so ${CMAKE_DL_LIBS})
    elseif(PLUMED_MODE STREQUAL "RUNTIME")
@@ -826,7 +826,7 @@ endforeach()
##############################################
# add lib sources of (simple) enabled packages
############################################
foreach(SIMPLE_LIB REAX MEAM POEMS USER-ATC USER-AWPMD USER-COLVARS USER-H5MD
foreach(SIMPLE_LIB POEMS USER-ATC USER-AWPMD USER-COLVARS USER-H5MD
  USER-QMMM)
  if(PKG_${SIMPLE_LIB})
    string(REGEX REPLACE "^USER-" "" PKG_LIB "${SIMPLE_LIB}")
@@ -856,6 +856,9 @@ if(PKG_USER-AWPMD)
endif()

if(PKG_USER-ATC)
  if(LAMMPS_SIZES STREQUAL BIGBIG)
    message(FATAL_ERROR "The USER-ATC Package is not compatible with -DLAMMPS_BIGBIG")
  endif()
  target_link_libraries(atc ${LAPACK_LIBRARIES})
endif()

@@ -1322,7 +1325,7 @@ if(BUILD_LIB)
  configure_file(pkgconfig/liblammps.pc.in ${CMAKE_CURRENT_BINARY_DIR}/liblammps${LAMMPS_LIB_SUFFIX}.pc @ONLY)
  install(FILES ${CMAKE_CURRENT_BINARY_DIR}/liblammps${LAMMPS_LIB_SUFFIX}.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
  configure_file(FindLAMMPS.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/FindLAMMPS${LAMMPS_LIB_SUFFIX}.cmake @ONLY)
  install(FILES ${CMAKE_CURRENT_BINARY_DIR}/FindLAMMPS${LAMMPS_LIB_SUFFIX}.cmake DESTINATION ${CMAKE_INSTALL_DATADIR}/cmake/Module)
  install(FILES ${CMAKE_CURRENT_BINARY_DIR}/FindLAMMPS${LAMMPS_LIB_SUFFIX}.cmake DESTINATION ${CMAKE_INSTALL_DATADIR}/cmake/Modules)
else()
  list(APPEND LMP_SOURCES ${LIB_SOURCES})
endif()
+19 −2
Original line number Diff line number Diff line
@@ -24,7 +24,7 @@ tasks, act as a reference and provide examples of typical use cases.
      * [Build directory vs. Source Directory](#build-directory-vs-source-directory)
   * [Defining and using presets](#defining-and-using-presets)
   * [Reference](#reference)
      * [Common CMAKE Configuration Options](#common-cmake-configuration-options)
      * [Common CMake Configuration Options](#common-cmake-configuration-options)
      * [LAMMPS Configuration Options](#lammps-configuration-options)
      * [Parallelization and Accelerator Packages](#parallelization-and-accelerator-packages)
      * [Default Packages](#default-packages)
@@ -179,7 +179,7 @@ cmake -C ../cmake/presets/std_nolib.cmake -D PKG_GPU=on ../cmake

# Reference

## Common CMAKE Configuration Options
## Common CMake Configuration Options


<table>
@@ -208,6 +208,16 @@ cmake -C ../cmake/presets/std_nolib.cmake -D PKG_GPU=on ../cmake
  </dl>
  </td>
</tr>
<tr>
  <td><code><CMAKE_VERBOSE_MAKEFILE/code></td>
  <td>Enable verbose output from Makefile builds (useful for debugging), the same can be achived by adding `VERBOSE=1` to the `make` call.</td>
  <td>
  <dl>
    <dt><code>off</code> (default)</dt>
    <dt><code>on</code></dt>
  </dl>
  </td>
</tr>
</tbody>
</table>

@@ -1729,6 +1739,13 @@ cache by setting the `CMAKE_C_COMPILER`, `CMAKE_CXX_COMPILER`,
  value of `FC` environment variable at first `cmake` run
  </td>
</tr>
<tr>
  <td><code>CXX_COMPILER_LAUNCHER</code></td>
  <td>CMake will run this tool and pass the compiler and its arguments to the tool. Some example tools are distcc and ccache.</td>
  <td>
  (empty)
  </td>
</tr>
</tbody>
</table>

+3 −2
Original line number Diff line number Diff line
# Makefile for LAMMPS documentation

SHELL         = /bin/bash
SHA1          = $(shell echo $USER-$PWD | python utils/sha1sum.py)
SHA1          = $(shell echo ${USER}-${PWD} | python utils/sha1sum.py)
BUILDDIR      = /tmp/lammps-docs-$(SHA1)
RSTDIR        = $(BUILDDIR)/rst
VENV          = $(BUILDDIR)/docenv
@@ -48,6 +48,7 @@ help:
	@echo "  clean-all  reset the entire build environment"
	@echo "  txt2html   build txt2html tool"
	@echo "  anchor_check  scan for duplicate anchor labels"
	@echo "  spelling   spell-check the manual"

# ------------------------------------------

+5 −4
Original line number Diff line number Diff line
@@ -6,7 +6,7 @@ choices the LAMMPS developers have agreed on. Git and GitHub provide the
tools, but do not set policies, so it is up to the developers to come to
an agreement as to how to define and interpret policies. This document
is likely to change as our experiences and needs change and we try to
adapt accordingly. Last change 2018-11-15.
adapt accordingly. Last change 2018-12-19.

## Table of Contents

@@ -129,16 +129,17 @@ Here are some items to check:
    * stdlib.h -> cstdlib
    * string.h -> cstring
    * time.h -> ctime
  Do not replace (as they are C++-11): `inttypes.h` and `stdint.h`.
    * Do NOT replace (as they are C++-11): `inttypes.h` and `stdint.h`.
  * Code should follow the C++-98 standard. C++-11 is only accepted
  in individual special purpose packages
  * indentation is two spaces per level
  * there should be no tabs and no trailing whitespace
  * indentation is 2 spaces per level
  * there should be NO tabs and no trailing whitespace
  * header files, especially of new styles, should not include any
  other headers, except the header with the base class or cstdio.
  Forward declarations should be used instead when possible.
  * iostreams should be avoided. LAMMPS uses stdio from the C-library.
  * use of STL in headers and class definitions should be avoided.
  * there MUST NOT be any "using namespace XXX;" statements in headers.
  * static class members should be avoided at all cost.
  * anything storing atom IDs should be using `tagint` and not `int`.
  This can be flagged by the compiler only for pointers and only when
Loading