Skip to content

Commit

Permalink
Merge pull request #13 from Amaury070/main
Browse files Browse the repository at this point in the history
add cmake compilation
  • Loading branch information
simongravelle authored Oct 28, 2024
2 parents b8278f1 + ce05918 commit ca4926b
Showing 1 changed file with 27 additions and 1 deletion.
28 changes: 27 additions & 1 deletion docs/source/lammps.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ For instance, from the terminal, download the last stable release:
<a href="https://www.lammps.org/download.html" target="_blank">LAMMPS</a>


Compile LAMMPS
Compile LAMMPS with make
--------------

For compiling in serial, simply navidate to the ``src/`` folder, and type:
Expand All @@ -50,6 +50,32 @@ Then, from the ``src/`` folder, type:
make mpi
Compile LAMMPS with cmake using guix environment
--------------

source your guix environment and install the following package(specified the openmpi version, some issues were observed on dahu cluster with openmpi 5)

.. code-block::
source /applis/site/guix-start.sh
guix install cmake
guix install glibc-locales
guix install gcc-toolchain
guix install [email protected]
guix install clang
guix install ffmpeg
navigate into your lammps home, create a folder ``build/``. From the ``build/`` folder, compile LAMMPS:

.. code-block::
mkdir build
cd build
cmake ../cmake -D PKG_MOLECULE=on -D PKG_KSPACE=on -D PKG_RIGID=on
It creates an executable lmp in the directory. You can add as many packages as you want and you can create different build if you need it.


Run LAMMPS
----------

Expand Down

0 comments on commit ca4926b

Please sign in to comment.