-
Notifications
You must be signed in to change notification settings - Fork 891
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stop CMake from marking cudf's libcudacxx and thrust includes as system #9277
Stop CMake from marking cudf's libcudacxx and thrust includes as system #9277
Conversation
nvcc automatically adds the CUDA Toolkit system include paths before any system include paths that CMake adds. CMake implicitly treats all includes on import targets as 'SYSTEM' includes. To get the cudacxx shipped with cudf to be picked up by consumers instead of the version shipped with the CUDA Toolkit we need to make sure it is a non-SYSTEM include on the CMake side.
rerun tests |
Codecov Report
@@ Coverage Diff @@
## branch-21.10 #9277 +/- ##
================================================
- Coverage 10.85% 10.80% -0.06%
================================================
Files 115 116 +1
Lines 19158 19321 +163
================================================
+ Hits 2080 2087 +7
- Misses 17078 17234 +156
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple of questions.
cpp/CMakeLists.txt
Outdated
# version shipped with the CUDA Toolkit we need to make sure it is a non-SYSTEM | ||
# include on the CMake side. | ||
# | ||
# Todo this currently we move the includes from the cudf::cudf target to a |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this a TODO? Or are you saying "To do this currently, we move..."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am saying "To do this currently, ... ". I will revise the comment to be clear.
# nvcc automatically adds the CUDA Toolkit system include paths before any | ||
# system include paths that CMake adds. | ||
# | ||
# CMake implicitly treats all includes on import targets as 'SYSTEM' includes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmmm, so this is the root cause? Would it be possible to make this configurable in a future CMake version to avoid all the below complexity?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes the root cause is implicit behavior in CMake, and I am working on upstreaming solutions to CMake for this issue.
Is this needed in 21.10? |
I defer to @trxcllnt who reported the issue to me |
@harrism this is necessary for anyone using the libcudf CMake library targets. Without this, the CUDA toolkit's libcu++ paths will take precedence over libcudf's, and including libcudf headers that have libcu++ includes will fail their project's build. |
nvcc automatically adds the CUDA Toolkit system include paths before any system include paths that CMake adds.
CMake implicitly treats all includes on import targets as 'SYSTEM' includes.
To get the cudacxx shipped with cudf to be picked up by consumers instead of the version shipped with the CUDA Toolkit we need to make sure it is a non-SYSTEM include on the CMake side.