Fixed #21. Added extern C to support C++. Thank Tasio for the patch.
This commit is contained in:
parent
00ef0cd434
commit
0a45e5495f
|
@ -10,6 +10,8 @@ common:
|
||||||
on github)
|
on github)
|
||||||
* Support "void goto_set_num_threads(int num_threads)" and "void
|
* Support "void goto_set_num_threads(int num_threads)" and "void
|
||||||
openblas_set_num_threads(int num_threads)" when USE_OPENMP=1
|
openblas_set_num_threads(int num_threads)" when USE_OPENMP=1
|
||||||
|
* Added extern "C" to support C++. Thank Tasio for the patch(Refs
|
||||||
|
issue #21 on github)
|
||||||
|
|
||||||
x86/x86_64:
|
x86/x86_64:
|
||||||
*
|
*
|
||||||
|
|
11
cblas.h
11
cblas.h
|
@ -1,6 +1,11 @@
|
||||||
#ifndef CBLAS_H
|
#ifndef CBLAS_H
|
||||||
#define CBLAS_H
|
#define CBLAS_H
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
/* Assume C declarations for C++ */
|
||||||
|
#endif /* __cplusplus */
|
||||||
|
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
#include "common.h"
|
#include "common.h"
|
||||||
|
|
||||||
|
@ -273,4 +278,10 @@ void cblas_zher2k(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANS
|
||||||
double *alpha, double *A, blasint lda, double *B, blasint ldb, double beta, double *C, blasint ldc);
|
double *alpha, double *A, blasint lda, double *B, blasint ldb, double beta, double *C, blasint ldc);
|
||||||
|
|
||||||
void cblas_xerbla(blasint p, char *rout, char *form, ...);
|
void cblas_xerbla(blasint p, char *rout, char *form, ...);
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif /* __cplusplus */
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
10
common.h
10
common.h
|
@ -39,6 +39,11 @@
|
||||||
#ifndef COMMON_H
|
#ifndef COMMON_H
|
||||||
#define COMMON_H
|
#define COMMON_H
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
/* Assume C declarations for C++ */
|
||||||
|
#endif /* __cplusplus */
|
||||||
|
|
||||||
#ifndef _GNU_SOURCE
|
#ifndef _GNU_SOURCE
|
||||||
#define _GNU_SOURCE
|
#define _GNU_SOURCE
|
||||||
#endif
|
#endif
|
||||||
|
@ -607,4 +612,9 @@ extern int gotoblas_profile;
|
||||||
#define PRINT_DEBUG_NAME if (readenv("GOTO_DEBUG")) fprintf(stderr, "GotoBLAS : %s\n", CHAR_NAME)
|
#define PRINT_DEBUG_NAME if (readenv("GOTO_DEBUG")) fprintf(stderr, "GotoBLAS : %s\n", CHAR_NAME)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif /* __cplusplus */
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue