Commit e3281851 authored by Davis King's avatar Davis King

Added checks to see if cblas.h has already been #included.

parent 15022b22
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
#ifndef DLIB_CBLAS_CONSTAnTS_Hh_ #ifndef DLIB_CBLAS_CONSTAnTS_Hh_
#define DLIB_CBLAS_CONSTAnTS_Hh_ #define DLIB_CBLAS_CONSTAnTS_Hh_
#ifndef CBLAS_H
namespace dlib namespace dlib
{ {
namespace blas_bindings namespace blas_bindings
...@@ -15,6 +16,7 @@ namespace dlib ...@@ -15,6 +16,7 @@ namespace dlib
} }
} }
#endif // if not CBLAS_H
#endif // DLIB_CBLAS_CONSTAnTS_Hh_ #endif // DLIB_CBLAS_CONSTAnTS_Hh_
...@@ -44,6 +44,7 @@ namespace dlib ...@@ -44,6 +44,7 @@ namespace dlib
#define DLIB_TEST_BLAS_BINDING_SCAL #define DLIB_TEST_BLAS_BINDING_SCAL
#endif #endif
#ifndef CBLAS_H
extern "C" extern "C"
{ {
// Here we declare the prototypes for the CBLAS calls used by the BLAS bindings below // Here we declare the prototypes for the CBLAS calls used by the BLAS bindings below
...@@ -133,6 +134,7 @@ namespace dlib ...@@ -133,6 +134,7 @@ namespace dlib
const void *alpha, const void *X, const int incX, const void *alpha, const void *X, const int incX,
const void *Y, const int incY, void *A, const int lda); const void *Y, const int incY, void *A, const int lda);
} }
#endif // if not CBLAS_H
// ---------------------------------------------------------------------------------------- // ----------------------------------------------------------------------------------------
// ---------------------------------------------------------------------------------------- // ----------------------------------------------------------------------------------------
......
...@@ -9,7 +9,7 @@ namespace dlib ...@@ -9,7 +9,7 @@ namespace dlib
{ {
namespace blas_bindings namespace blas_bindings
{ {
#ifndef CBLAS_H
extern "C" extern "C"
{ {
void cblas_strsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, void cblas_strsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
...@@ -24,6 +24,7 @@ namespace dlib ...@@ -24,6 +24,7 @@ namespace dlib
const double alpha, const double *A, const int lda, const double alpha, const double *A, const int lda,
double *B, const int ldb); double *B, const int ldb);
} }
#endif // if not CBLAS_H
// ------------------------------------------------------------------------------------ // ------------------------------------------------------------------------------------
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment