fix lapacke config
diff --git a/Eigen/Core b/Eigen/Core
index af71891..631d3df 100644
--- a/Eigen/Core
+++ b/Eigen/Core
@@ -155,6 +155,14 @@
* \endcode
*/
+#ifdef EIGEN_USE_LAPACKE
+ #ifdef EIGEN_USE_MKL
+ #include "mkl_lapacke.h"
+ #else
+ #include "src/misc/lapacke.h"
+ #endif
+#endif
+
#include "src/Core/util/Constants.h"
#include "src/Core/util/Meta.h"
#include "src/Core/util/Assert.h"
diff --git a/Eigen/src/QR/ColPivHouseholderQR_LAPACKE.h b/Eigen/src/QR/ColPivHouseholderQR_LAPACKE.h
index 8a6ae9b..70df6db 100644
--- a/Eigen/src/QR/ColPivHouseholderQR_LAPACKE.h
+++ b/Eigen/src/QR/ColPivHouseholderQR_LAPACKE.h
@@ -119,33 +119,30 @@
ColPivHouseholderQR_LAPACKE_impl<MatrixType>::init(rows, cols, m_hCoeffs, m_colsPermutation, m_isInitialized, \
m_usePrescribedThreshold); } \
- #define COLPIVQR_LAPACKE(EIGTYPE) \
- COLPIVQR_LAPACKE_COMPUTEINPLACE(EIGTYPE) \
- COLPIVQR_LAPACKE_INIT(EIGTYPE) \
+ #define COLPIVQR_LAPACKE(EIGTYPE) \
+ COLPIVQR_LAPACKE_COMPUTEINPLACE(EIGTYPE) \
+ COLPIVQR_LAPACKE_INIT(EIGTYPE) \
+ COLPIVQR_LAPACKE_COMPUTEINPLACE(Ref<EIGTYPE>) \
+ COLPIVQR_LAPACKE_INIT(Ref<EIGTYPE>) \
- typedef Matrix<float, Dynamic, Dynamic, RowMajor> MatrixXfR;
- typedef Matrix<double, Dynamic, Dynamic, RowMajor> MatrixXdR;
- typedef Matrix<scomplex, Dynamic, Dynamic, RowMajor> MatrixXcfR;
- typedef Matrix<dcomplex, Dynamic, Dynamic, RowMajor> MatrixXcdR;
+ typedef Matrix<float, Dynamic, Dynamic, ColMajor> MatrixXfC;
+ typedef Matrix<double, Dynamic, Dynamic, ColMajor> MatrixXdC;
+ typedef Matrix<lapack_complex_float, Dynamic, Dynamic, ColMajor> MatrixXcfC;
+ typedef Matrix<lapack_complex_double, Dynamic, Dynamic, ColMajor> MatrixXcdC;
+ typedef Matrix<float, Dynamic, Dynamic, RowMajor> MatrixXfR;
+ typedef Matrix<double, Dynamic, Dynamic, RowMajor> MatrixXdR;
+ typedef Matrix<lapack_complex_float, Dynamic, Dynamic, RowMajor> MatrixXcfR;
+ typedef Matrix<lapack_complex_double, Dynamic, Dynamic, RowMajor> MatrixXcdR;
- COLPIVQR_LAPACKE(MatrixXf)
- COLPIVQR_LAPACKE(MatrixXd)
- COLPIVQR_LAPACKE(MatrixXcf)
- COLPIVQR_LAPACKE(MatrixXcd)
+ COLPIVQR_LAPACKE(MatrixXfC)
+ COLPIVQR_LAPACKE(MatrixXdC)
+ COLPIVQR_LAPACKE(MatrixXcfC)
+ COLPIVQR_LAPACKE(MatrixXcdC)
COLPIVQR_LAPACKE(MatrixXfR)
COLPIVQR_LAPACKE(MatrixXdR)
COLPIVQR_LAPACKE(MatrixXcfR)
COLPIVQR_LAPACKE(MatrixXcdR)
- COLPIVQR_LAPACKE(Ref<MatrixXf>)
- COLPIVQR_LAPACKE(Ref<MatrixXd>)
- COLPIVQR_LAPACKE(Ref<MatrixXcf>)
- COLPIVQR_LAPACKE(Ref<MatrixXcd>)
- COLPIVQR_LAPACKE(Ref<MatrixXfR>)
- COLPIVQR_LAPACKE(Ref<MatrixXdR>)
- COLPIVQR_LAPACKE(Ref<MatrixXcfR>)
- COLPIVQR_LAPACKE(Ref<MatrixXcdR>)
-
#endif
} // end namespace Eigen
diff --git a/Eigen/src/misc/lapacke.h b/Eigen/src/misc/lapacke.h
index 3d8e24f..c20204c 100644
--- a/Eigen/src/misc/lapacke.h
+++ b/Eigen/src/misc/lapacke.h
@@ -46,7 +46,11 @@
#include <stdlib.h>
#ifndef lapack_int
-#define lapack_int int
+ #ifdef LAPACK_ILP64
+ #define lapack_int int64_t
+ #else
+ #define lapack_int int
+ #endif
#endif
#ifndef lapack_logical
@@ -72,8 +76,7 @@
/* Complex type (single precision) */
#ifndef lapack_complex_float
-#include <complex.h>
-#define lapack_complex_float float _Complex
+#define lapack_complex_float std::complex<float>
#endif
#ifndef lapack_complex_float_real
@@ -88,8 +91,7 @@
/* Complex type (double precision) */
#ifndef lapack_complex_double
-#include <complex.h>
-#define lapack_complex_double double _Complex
+#define lapack_complex_double std::complex<double>
#endif
#ifndef lapack_complex_double_real