-
Notifications
You must be signed in to change notification settings - Fork 13.5k
[llvm] Enable building Analysis plugins on windows #112303
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
[llvm] Enable building Analysis plugins on windows #112303
Conversation
Enable building InlineAdvisorPlugin and InlineOrderPlugin on windows for shared library builds. This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and LLVM plugins on window.
@llvm/pr-subscribers-llvm-analysis Author: Thomas Fransham (fsfod) ChangesEnable building InlineAdvisorPlugin and InlineOrderPlugin on windows for shared library builds. This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and LLVM plugins on window. Full diff: https://github.com/llvm/llvm-project/pull/112303.diff 2 Files Affected:
diff --git a/llvm/unittests/Analysis/InlineAdvisorPlugin/CMakeLists.txt b/llvm/unittests/Analysis/InlineAdvisorPlugin/CMakeLists.txt
index 22cd0cb1d9a034..deabf110f2e439 100644
--- a/llvm/unittests/Analysis/InlineAdvisorPlugin/CMakeLists.txt
+++ b/llvm/unittests/Analysis/InlineAdvisorPlugin/CMakeLists.txt
@@ -2,7 +2,7 @@
# libraries, but expects them to exist in the process loading the plugin. This
# doesn't work with DLLs on Windows (where a shared library can't have undefined
# references), so just skip this testcase on Windows.
-if (NOT WIN32 AND NOT CYGWIN)
+if ((NOT WIN32 OR LLVM_BUILD_LLVM_DYLIB) AND NOT CYGWIN)
unset(LLVM_LINK_COMPONENTS)
add_llvm_library(InlineAdvisorPlugin MODULE BUILDTREE_ONLY
InlineAdvisorPlugin.cpp
diff --git a/llvm/unittests/Analysis/InlineOrderPlugin/CMakeLists.txt b/llvm/unittests/Analysis/InlineOrderPlugin/CMakeLists.txt
index cc470a934426d5..0b37cebe3da6de 100644
--- a/llvm/unittests/Analysis/InlineOrderPlugin/CMakeLists.txt
+++ b/llvm/unittests/Analysis/InlineOrderPlugin/CMakeLists.txt
@@ -2,7 +2,7 @@
# libraries, but expects them to exist in the process loading the plugin. This
# doesn't work with DLLs on Windows (where a shared library can't have undefined
# references), so just skip this testcase on Windows.
-if (NOT WIN32 AND NOT CYGWIN)
+if ((NOT WIN32 OR LLVM_BUILD_LLVM_DYLIB) AND NOT CYGWIN)
unset(LLVM_LINK_COMPONENTS)
add_llvm_library(InlineOrderPlugin MODULE BUILDTREE_ONLY
InlineOrderPlugin.cpp
|
Hi @dwblaikie, this lgtm but since I could not find an obvious reviewer maybe that's around an area you have experience with? |
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.
Sure, I guess - best of luck :)
Thank you! |
Enable building InlineAdvisorPlugin and InlineOrderPlugin on windows for shared library builds. This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and LLVM plugins on window.
Enable building InlineAdvisorPlugin and InlineOrderPlugin on windows for shared library builds. This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and LLVM plugins on window.
Enable building InlineAdvisorPlugin and InlineOrderPlugin on windows for shared library builds.
This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and LLVM plugins on window.