From bdd1dc1bfbe1492edf3ce5e4288cfbc55be329ab Mon Sep 17 00:00:00 2001 From: Thomas Schwinge Date: Fri, 29 Apr 2022 10:33:15 +0200 Subject: [PATCH] 'include/cuda/cuda.h': For C++, wrap in 'extern "C"' include/ * cuda/cuda.h: For C++, wrap in 'extern "C"'. --- include/cuda/cuda.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/include/cuda/cuda.h b/include/cuda/cuda.h index 5c813ad2cf8..d7105fb331e 100644 --- a/include/cuda/cuda.h +++ b/include/cuda/cuda.h @@ -32,6 +32,10 @@ the proprietary CUDA toolkit. */ #define CUDA_VERSION 8000 +#ifdef __cplusplus +extern "C" { +#endif + typedef void *CUcontext; typedef int CUdevice; #if defined(__LP64__) || defined(_WIN64) @@ -191,4 +195,8 @@ CUresult cuStreamQuery (CUstream); CUresult cuStreamSynchronize (CUstream); CUresult cuStreamWaitEvent (CUstream, CUevent, unsigned); +#ifdef __cplusplus +} +#endif + #endif /* GCC_CUDA_H */