-
Notifications
You must be signed in to change notification settings - Fork 203
Export symbols for Windows DLL and MSVC build compatibility #294
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
Conversation
WIP Export symbols for Windows DLL and MSVC build compatibility
|
I missed this PR, I am really sorry. I am happy to merge it once tests pass. Let me know if you need any help in fixing those. |
WIP Export symbols for Windows DLL and MSVC build compatibility|
Don't worry, it's not ready yet anyway, I hadn't tested the pip build process. The new changes seem to break the I'm not entirely sure what the root cause is (and why the Linux build is also not working now) since the additions were meant to fix the unresolved symbols issue when building on Windows - #290. I'm guessing something in the compiler or linker arguments in the |
|
Yes, this is a bit weird since it looks identical to rusty1s/pytorch_sparse#198. Hopefully @dfalbel has some idea? |
|
I've since revisited this and the linking failure seems to only occur with the I.e. commenting out these lines: namespace scatter {
SCATTER_API int64_t cuda_version() noexcept;
namespace detail {
SCATTER_INLINE_VARIABLE int64_t _cuda_version = cuda_version();
} // namespace detail
} // namespace scatterin scatter.h allows Trying to investigate why this symbol doesn't export correctly. The setup seems to be the same as in the |
|
I have a feeling that it has something to do with the fact that the main header This is really the only thing I can see that's different between the implementations in those repos which worked and here where it isn't. Note, the other files build and link correctly (especially notably The above commit brings the changes even more inline with the export symbols PRs in the other repos. But unsure how to fully fix - needs separation of |
Codecov Report
@@ Coverage Diff @@
## master #294 +/- ##
=======================================
Coverage 97.54% 97.54%
=======================================
Files 9 9
Lines 204 204
=======================================
Hits 199 199
Misses 5 5 📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more |
|
So it works now? By removing the I don't have enough C++/Python extension knowledge to know why that works or if it's a bad solution. So I'll leave it up to others... |
|
Thank you! The "fix" makes sense. |
Export DLL symbols for Windows and MSVC build compatibility. Related to #290