Skip to content

Commit

Permalink
[Windows][Polly] Disable LLVMPolly module for all compilers on Windows
Browse files Browse the repository at this point in the history
Before this patch, the cmake disabled loadable modules when compiling
with Visual Studio. However, the reason for this is a limitation of the
Windows DLLs, thus this restriction should apply to any compiler for the
Windows platform, such as MinGW, Cygwin, icc, etc.

Differential Revision: https://reviews.llvm.org/D87524
  • Loading branch information
mati865 authored and mstorsjo committed Sep 15, 2020
1 parent 61e0b2b commit e71cda2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion polly/cmake/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ else()
endif()

set(POLLY_CONFIG_EXPORTED_TARGETS Polly ${ISL_TARGET})
if (NOT MSVC AND LLVM_ENABLE_PIC)
if (NOT WIN32 AND LLVM_ENABLE_PIC)
# LLVMPolly is a dummy target on Win or if PIC code is disabled.
list(APPEND POLLY_CONFIG_EXPORTED_TARGETS LLVMPolly)
endif()
Expand Down
2 changes: 1 addition & 1 deletion polly/lib/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ endif ()

# Create a loadable module Polly.so that can be loaded using
# LLVM's/clang's "-load" option.
if (MSVC OR NOT LLVM_ENABLE_PIC)
if (WIN32 OR NOT LLVM_ENABLE_PIC)
# Add dummy target, either because loadable modules are not supported
# as on Windows or because PIC code has been disabled
add_custom_target(LLVMPolly)
Expand Down

0 comments on commit e71cda2

Please sign in to comment.