I’m using my apple silicon MBP to build LAMMPS. After cmake configuration, there is a fatal error i occur:
/Users/roy/lammps/src/lmptype.h:34:2: error: LAMMPS requires a C++11 (or later) compliant compiler. Enable C++11 compatibility or upgrade the compiler.
#error LAMMPS requires a C++11 (or later) compliant compiler. Enable C++11 compatibility or upgrade the compiler.
In file included from /Users/roy/lammps/src/angle.cpp:14:
In file included from /Users/roy/lammps/src/angle.h:17:
In file included from /Users/roy/lammps/src/pointers.h:31:
In file included from /Users/roy/lammps/src/fmt/format.h:44:
/Users/roy/lammps/src/fmt/core.h:265:21: warning: alias declarations are a C++11 extension [-Wc++11-extensions]
using enable_if_t = typename std::enable_if<B, T>::type;
So how to set up -std=c++11 in cmake, or use clang to compile LAMMPS. Does M1 processor’s compatibility leads to this error?
Thanks in advanced!
University of Science & Technology of China