Define NVML_NO_UNVERSIONED_FUNC_DEFS#20146
Conversation
|
Hey @Zha0q1 , Thanks for submitting the PR
CI supported jobs: [centos-cpu, clang, website, centos-gpu, unix-gpu, miscellaneous, unix-cpu, sanity, edge, windows-cpu, windows-gpu] Note: |
|
@mxnet-bot run ci [all] |
|
Jenkins CI successfully triggered : [windows-gpu, unix-cpu, website, edge, sanity, unix-gpu, centos-gpu, centos-cpu, clang, miscellaneous, windows-cpu] |
|
@mxnet-bot run ci [all] |
|
Jenkins CI successfully triggered : [edge, windows-cpu, miscellaneous, unix-gpu, windows-gpu, website, sanity, unix-cpu, centos-gpu, clang, centos-cpu] |
| if(USE_NVML) | ||
| find_package(NVML) | ||
| if(NVML_FOUND) | ||
| target_compile_definitions(mxnet PRIVATE NVML_NO_UNVERSIONED_FUNC_DEFS) |
There was a problem hiding this comment.
How about moving this to line 595 above and avoid duplication of the nested ifs?
There was a problem hiding this comment.
I think we need to add this compile def after https://github.com/apache/incubator-mxnet/blob/2cd1b4666d4e6d5df20bc139012061ef0d2e1a37/CMakeLists.txt#L656-L660. In fact I tried what you suggested and got into this error
[2021-04-08T23:00:06.226Z] CMake Error at CMakeLists.txt:600 (target_compile_definitions):
[2021-04-08T23:00:06.226Z] Cannot specify compile definitions for target "mxnet" which is not built by
[2021-04-08T23:00:06.226Z] this project.
There was a problem hiding this comment.
You're right. So you can consider add it after line 660, or move 656-660 to an earlier location in the file. It's not necessary to do it now.
fixes #20145