installing user-atc


I am new user of Lammps and I want to make Lammps with user-atc in Cygwin. I cannot compile the program (make cygwin) because of the following error:

/usr/lib/gcc/i686-pc-cygwin/4.5.3/../../../../i686-pc-cygwin/bin/ld: cannot find -lblas

/usr/lib/gcc/i686-pc-cygwin/4.5.3/../../../../i686-pc-cygwin/bin/ld: cannot find -llapack

I installed lapack-3.4.2 on my PC and edit Lammps-11May13\/lib/atc/ makefile.lammps as follow:

user-atc_SYSINC =

user-atc_SYSLIB = -lblas -llapack

user-atc_SYSPATH= -L/cygdrive/c/cygwin/home/mypc/lapack-3.4.2

But, the error is same as before. Can you help me to solve this problem?

Thank you


The linker cannot find the files referred to in user-atc_SYSLIB at the
path referred to in user-atc_SYSPATH. It's pretty obvious;
StackOverflow is a more appropriate place to query basic issues like
this that are really independent of LAMMPS.

Run this command at a bash prompt:

if [ ! -a /cygdrive/c/cygwin/home/mypc/lapack-3.4.2/liblapack.a -o -a
/cygdrive/c/cygwin/home/mypc/lapack-3.4.2/ ] ; then echo
The absence of the files for which the compiler looks is the source of
your error. ; fi

I have not used Cygwin in about 7 years so I have no idea what the
proper path is, but you might run this command (at any shell prompt):

find ~/. -name "liblapack.*" -exec echo The correct location of your
lapack library is {} ";"

Obviously, you may repeat for "s/lapack/blas/" as appropriate.


... and probably easier would be to use the bundled BLAS/LAPACK subset
in lib/linalg that are packaged with LAMMPS for exactly the reason
that you don't have to struggle with installing BLAS/LAPACK on
windows. i've recently updated the package to also support lib/awpmd,
with the latest LAPACK improvements and tested it with a
linux-to-windows cross compiler (using mingw). the pending updates
have been sent to steve for inclusion in LAMMPS and are already
available in LAMMPS-ICMS. i just yesterday conducted a LAMMPS tutorial
here in italy with windows binaries built this way.


Hi Ehsan, are you sure this is where the libraries are? You should also run the make check after you build them to confirm they are correctly built. I don’t use cygwin, and on linux/mac I just have the libraries in /usr/lib or /usr/local/lib so they are in my path.