summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sci-physics/lammps/files/1080.patch')
-rw-r--r--sci-physics/lammps/files/1080.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/sci-physics/lammps/files/1080.patch b/sci-physics/lammps/files/1080.patch
new file mode 100644
index 00000000000..85538b2a638
--- /dev/null
+++ b/sci-physics/lammps/files/1080.patch
@@ -0,0 +1,29 @@
+From a10bb4b96f40f3b5574b0fade2cfece8bf4c6fc9 Mon Sep 17 00:00:00 2001
+From: Christoph Junghans <junghans@lanl.gov>
+Date: Thu, 23 Aug 2018 15:02:36 -0600
+Subject: [PATCH] cmake: fix link issue with --as-needed
+
+---
+ cmake/CMakeLists.txt | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt
+index 460d177c92..51997593db 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -276,11 +276,14 @@ endif()
+
+ if(PKG_MSCG OR PKG_USER-ATC OR PKG_USER-AWPMD OR PKG_USER-QUIP OR PKG_LATTE)
+ find_package(LAPACK)
+- if(NOT LAPACK_FOUND)
++ find_package(BLAS)
++ if(NOT LAPACK_FOUND OR NOT BLAS_FOUND)
+ enable_language(Fortran)
+ file(GLOB LAPACK_SOURCES ${LAMMPS_LIB_SOURCE_DIR}/linalg/*.[fF])
+ add_library(linalg STATIC ${LAPACK_SOURCES})
+ set(LAPACK_LIBRARIES linalg)
++ else()
++ list(APPEND LAPACK_LIBRARIES ${BLAS_LIBRARIES})
+ endif()
+ endif()
+