From fc47b8c6ddd462794018230c31979c7be4d1f1d8 Mon Sep 17 00:00:00 2001
From: Axel Kohlmeyer <akohlmey@gmail.com>
Date: Wed, 22 Aug 2018 09:51:29 -0400
Subject: [PATCH] some more tweaks and epxlanations for windows support

---
 doc/src/Build_windows.txt | 40 ++++++++++++++++++++++++++-------------
 1 file changed, 27 insertions(+), 13 deletions(-)

diff --git a/doc/src/Build_windows.txt b/doc/src/Build_windows.txt
index 4d4efb398f..e847711705 100644
--- a/doc/src/Build_windows.txt
+++ b/doc/src/Build_windows.txt
@@ -9,14 +9,14 @@ Documentation"_ld - "LAMMPS Commands"_lc :c
 
 Notes for building LAMMPS on Windows :h3
 
-"General remarks"_#general
+"General remarks"_#generic
 "Running Linux on Windows"_#linux
 "Using GNU GCC ported to Windows"_#gnu
 "Using a cross-compiler"_#cross
 
 :line
 
-General remarks :h4,link(general)
+General remarks :h4,link(generic)
 
 LAMMPS is developed and tested primarily on Linux machines.  The vast
 majority of HPC clusters and supercomputers today runs on Linux as well.
@@ -53,12 +53,20 @@ are included, but may not always up-to-date for recently added functionality
 and the corresponding new code. A machine makefile for using cygwin for
 the old build system is provided. The CMake build system is untested
 for this; you will have to request that makefiles are generated and
-manually set the compiler.  In case of problems, you are recommended to
-contact somebody with experience in using cygwin.  If you come across
-portability problems requiring changes to the LAMMPS source code, or
-figure out corrections yourself, please report them on the lammps-users
-mailing list, or file them as an issue or pull request on the LAMMPS
-github project.
+manually set the compiler.  
+
+When compiling for Windows [not] set the -DLAMMPS_MEMALIGN define
+in the LMP_INC makefile variable and add -lwsock32 -lpsapi to the linker
+flags in LIB makefile variable. Try adding -static-libgcc or -static or 
+both to the linker flags when your resulting LAMMPS Windows executable
+complains about missing .dll files. The CMake configuration should set
+this up automatically, but is untested. 
+
+In case of problems, you are recommended to contact somebody with
+experience in using cygwin.  If you do come across portability problems
+requiring changes to the LAMMPS source code, or figure out corrections
+yourself, please report them on the lammps-users mailing list, or file
+them as an issue or pull request on the LAMMPS github project.
 
 
 Using a cross-compiler :h4,link(cross)
@@ -68,11 +76,17 @@ need to do the compilation on Windows, please consider using a Linux
 to Windows cross-compiler. This is how currently the Windows binary
 packages are created by the LAMMPS developers. Because of that, this is
 probably the currently best tested and supported way to build LAMMPS
-executables for Windows. Please keep in mind, though, that this only
-applies to compiling. Whether the resulting binaries do work correctly
-is no tested. The LAMMPS developers rely on the feedback of the users
-of the precompiled LAMMPS packages for Windows to become aware of
-issues and then try to apply corrections, if possible.
+executables for Windows.  There are makefiles provided for the
+traditional build system, but CMake has also been successfully tested
+using the mingw32-cmake and mingw64-cmake wrappers that are bundled
+with the cross-compiler environment on Fedora machines.
+
+Please keep in mind, though, that this only applies to compiling LAMMPS.
+Whether the resulting binaries do work correctly is no tested by the
+LAMMPS developers.  We instead rely on the feedback of the users
+of these precompiled LAMMPS packages for Windows.  We will try to resolve
+issues to the best of our abilities if we become aware of them. However
+this is subject to time constraints and focus on HPC platforms.
 
 
 Native Visual C++ support :h4,link(native)
-- 
GitLab