Considering TF will also have this problem... We can wait until TF resolves it and add the new inc file.
[ 1%] Building CXX object lib/src/cuda/cudart/CMakeFiles/deepmd_dyn_cudart.dir/cudart_stub.cc.o
In file included from /__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cudart_stub.cc:8:
/usr/local/cuda/include/cuda_runtime_api.h:165:62: error: conflicting declaration of C function 'cudaError_t cudaStreamGetCaptureInfo_v2(cudaStream_t, cudaStreamCaptureStatus*, long long unsigned int*)'
165 | #define cudaStreamGetCaptureInfo __CUDART_API_PTSZ(cudaStreamGetCaptureInfo_v2)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/cuda/include/cuda_runtime_api.h:159:36: note: in definition of macro '__CUDART_API_PTSZ'
159 | #define __CUDART_API_PTSZ(api) api
| ^~~
/__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cuda_runtime_11_2.inc:487:39: note: in expansion of macro 'cudaStreamGetCaptureInfo'
487 | extern __host__ cudaError_t CUDARTAPI cudaStreamGetCaptureInfo(
| ^~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/cuda/include/cuda_runtime_api.h:165:62: note: previous declaration 'cudaError_t cudaStreamGetCaptureInfo_v2(cudaStream_t, cudaStreamCaptureStatus*, long long unsigned int*, CUgraph_st**, CUgraphNode_st* const**, size_t*)'
165 | #define cudaStreamGetCaptureInfo __CUDART_API_PTSZ(cudaStreamGetCaptureInfo_v2)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/cuda/include/cuda_runtime_api.h:159:36: note: in definition of macro '__CUDART_API_PTSZ'
159 | #define __CUDART_API_PTSZ(api) api
| ^~~
/usr/local/cuda/include/cuda_runtime_api.h:3089:39: note: in expansion of macro 'cudaStreamGetCaptureInfo'
3089 | extern __host__ cudaError_t CUDARTAPI cudaStreamGetCaptureInfo(cudaStream_t stream, enum cudaStreamCaptureStatus *captureStatus_out, unsigned long long *id_out __dv(0), cudaGraph_t *graph_out __dv(0), const cudaGraphNode_t **dependencies_out __dv(0), size_t *numDependencies_out __dv(0));
| ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from /__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cudart_stub.cc:79:
/__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cuda_runtime_11_2.inc:20[73](https://github.com/njzjz/deepmd-kit/actions/runs/3666376315/jobs/6198046005#step:8:74):39: error: conflicting declaration of C function 'cudaError_t cudaGraphInstantiate(CUgraphExec_st**, cudaGraph_t, CUgraphNode_st**, char*, size_t)'
2073 | extern __host__ cudaError_t CUDARTAPI cudaGraphInstantiate(
| ^~~~~~~~~~~~~~~~~~~~
In file included from /__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cudart_stub.cc:8:
/usr/local/cuda/include/cuda_runtime_api.h:11441:39: note: previous declaration 'cudaError_t cudaGraphInstantiate(CUgraphExec_st**, cudaGraph_t, long long unsigned int)'
11441 | extern __host__ cudaError_t CUDARTAPI cudaGraphInstantiate(cudaGraphExec_t *pGraphExec, cudaGraph_t graph, unsigned long long flags __dv(0));
| ^~~~~~~~~~~~~~~~~~~~
In file included from /__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cudart_stub.cc:79:
/__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cuda_runtime_11_2.inc:2127:1: error: conflicting declaration of C function 'cudaError_t cudaGraphExecUpdate(cudaGraphExec_t, cudaGraph_t, CUgraphNode_st**, cudaGraphExecUpdateResult*)'
2127 | cudaGraphExecUpdate(cudaGraphExec_t hGraphExec, cudaGraph_t hGraph,
| ^~~~~~~~~~~~~~~~~~~
In file included from /__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cudart_stub.cc:8:
/usr/local/cuda/include/cuda_runtime_api.h:12402:39: note: previous declaration 'cudaError_t cudaGraphExecUpdate(cudaGraphExec_t, cudaGraph_t, cudaGraphExecUpdateResultInfo*)'
12402 | extern __host__ cudaError_t CUDARTAPI cudaGraphExecUpdate(cudaGraphExec_t hGraphExec, cudaGraph_t hGraph, cudaGraphExecUpdateResultInfo *resultInfo);
| ^~~~~~~~~~~~~~~~~~~
In file included from /__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cudart_stub.cc:79:
/__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cuda_runtime_11_2.inc:2250:39: error: conflicting declaration of C function 'cudaError_t cudaGetDriverEntryPoint(const char*, void**, long long unsigned int)'
2250 | extern __host__ cudaError_t CUDARTAPI cudaGetDriverEntryPoint(
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from /__w/deepmd-kit/deepmd-kit/source/lib/src/cuda/cudart/cudart_stub.cc:8:
/usr/local/cuda/include/cuda_runtime_api.h:12[74](https://github.com/njzjz/deepmd-kit/actions/runs/3666376315/jobs/6198046005#step:8:75)0:39: note: previous declaration 'cudaError_t cudaGetDriverEntryPoint(const char*, void**, long long unsigned int, cudaDriverEntryPointQueryResult*)'
12740 | extern __host__ cudaError_t CUDARTAPI cudaGetDriverEntryPoint(const char *symbol, void **funcPtr, unsigned long long flags, enum cudaDriverEntryPointQueryResult *driverStatus = NULL);
| ^~~~~~~~~~~~~~~~~~~~~~~
make[2]: *** [lib/src/cuda/cudart/CMakeFiles/deepmd_dyn_cudart.dir/build.make:[76](https://github.com/njzjz/deepmd-kit/actions/runs/3666376315/jobs/6198046005#step:8:77): lib/src/cuda/cudart/CMakeFiles/deepmd_dyn_cudart.dir/cudart_stub.cc.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:3[97](https://github.com/njzjz/deepmd-kit/actions/runs/3666376315/jobs/6198046005#step:8:98): lib/src/cuda/cudart/CMakeFiles/deepmd_dyn_cudart.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
Bug summary
CUDA 12.0 may change some APIs and breaks the old
cuda_runtime_11_2.inc.Considering TF will also have this problem... We can wait until TF resolves it and add the new
incfile.DeePMD-kit Version
devel
TensorFlow Version
2.9.1
How did you download the software?
Offline packages
Input Files, Running Commands, Error Log, etc.
Steps to Reproduce
deepmd-kit/.github/workflows/build_cc.yml
Lines 23 to 32 in cc2c9c8
https://github.com/njzjz/deepmd-kit/actions/runs/3666376315/jobs/6198046005
Further Information, Files, and Links
No response