aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPjotr Prins2017-12-19 07:57:55 +0000
committerPjotr Prins2017-12-19 07:57:55 +0000
commitfe883b9730925c75ac2bd09e7060c042929a942e (patch)
tree727ae4246f2044007470958e4b0939707fe63ce9
parent8b0985fb484c0691deb8fe0091b9edf2b5ab973e (diff)
downloadpangemma-fe883b9730925c75ac2bd09e7060c042929a942e.tar.gz
Use OpenBlas cblas interface by default
-rw-r--r--INSTALL.md4
-rw-r--r--Makefile8
2 files changed, 10 insertions, 2 deletions
diff --git a/INSTALL.md b/INSTALL.md
index 0a39604..6b51edb 100644
--- a/INSTALL.md
+++ b/INSTALL.md
@@ -114,6 +114,10 @@ workstation it easily doubles speed). When you check the output .log
file of GEMMA after a run, it will tell you how the linked-in OpenBlas
was compiled.
+It is worth checking that you use OpenBlas's lapack and cblas
+interfaces instead of linking against default lapack and gslcblas
+libs.
+
To link a new version, compile OpenBlas as per
[instructions](http://www.openblas.net/). You can start with the
default:
diff --git a/Makefile b/Makefile
index fcc2007..8a57a27 100644
--- a/Makefile
+++ b/Makefile
@@ -46,8 +46,9 @@ SYS = LNX # LNX|MAC (Linux is the default)
DIST_NAME = gemma-$(GEMMA_VERSION)
DEBUG = 1 # DEBUG mode, set DEBUG=0 for a release
SHOW_COMPILER_WARNINGS =
-WITH_LAPACK = # Force linking LAPACK
WITH_OPENBLAS = 1 # Without OpenBlas uses LAPACK
+WITH_LAPACK = # Force linking LAPACK (if OpenBlas lacks it)
+WITH_GSLCBLAS = # Force linking gslcblas (if OpenBlas lacks it)
OPENBLAS_LEGACY = # Using older OpenBlas
FORCE_STATIC = # Static linking of libraries
GCC_FLAGS = -Wall -O3 -std=gnu++11 # extra flags -Wl,--allow-multiple-definition
@@ -97,7 +98,10 @@ ifdef SHOW_COMPILER_WARNINGS
endif
ifndef FORCE_STATIC
- LIBS = -lopenblas -lgsl -lgslcblas -pthread -lz
+ LIBS = -lopenblas -lgsl -pthread -lz
+ ifdef WITH_GSLCBLAS
+ LIBS += -lgslcblas
+ endif
else
ifndef TRAVIS_CI # Travis static compile we cheat a little
CPPFLAGS += -static