aboutsummaryrefslogtreecommitdiffhomepage
path: root/blas
diff options
context:
space:
mode:
Diffstat (limited to 'blas')
-rw-r--r--blas/xerbla.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/blas/xerbla.cpp b/blas/xerbla.cpp
index bda1d2f46..0d57710fe 100644
--- a/blas/xerbla.cpp
+++ b/blas/xerbla.cpp
@@ -1,12 +1,18 @@
#include <iostream>
+#if (defined __GNUC__)
+#define EIGEN_WEAK_LINKING __attribute__ ((weak))
+#else
+#define EIGEN_WEAK_LINKING
+#endif
+
#ifdef __cplusplus
extern "C"
{
#endif
-int xerbla_(const char * msg, int *info, int)
+EIGEN_WEAK_LINKING int xerbla_(const char * msg, int *info, int)
{
std::cerr << "Eigen BLAS ERROR #" << *info << ": " << msg << "\n";
return 0;