Skip to content

Commit 098130f

Browse files
committed
[CMake][Polly] Remove dead CMake code
LLVM requires CMake 3.13.4 so remove code behind checks for an older version. Reviewed By: phosek Differential Revision: https://reviews.llvm.org/D87192
1 parent 80186e4 commit 098130f

File tree

2 files changed

+1
-17
lines changed

2 files changed

+1
-17
lines changed

polly/cmake/polly_macros.cmake

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -72,21 +72,6 @@ macro(add_polly_loadable_module name)
7272
endif()
7373
endmacro(add_polly_loadable_module)
7474

75-
# Use C99-compatible compile mode for all C source files of a target.
76-
function(target_enable_c99 _target)
77-
if(CMAKE_VERSION VERSION_GREATER "3.1")
78-
set_target_properties("${_target}" PROPERTIES C_STANDARD 99)
79-
elseif(CMAKE_COMPILER_IS_GNUCC)
80-
get_target_property(_sources "${_target}" SOURCES)
81-
foreach(_file IN LISTS _sources)
82-
get_source_file_property(_lang "${_file}" LANGUAGE)
83-
if(_lang STREQUAL "C")
84-
set_source_files_properties(${_file} COMPILE_FLAGS "-std=gnu99")
85-
endif()
86-
endforeach()
87-
endif()
88-
endfunction()
89-
9075
# Recursive helper for setup_source_group. Traverse the file system and add
9176
# source files matching the glob_expr to the prefix, recursing into
9277
# subdirectories as they are encountered

polly/lib/External/CMakeLists.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,8 +293,7 @@ if (POLLY_BUNDLED_ISL)
293293
)
294294

295295
# ISL requires at least C99 to compile. gcc < 5.0 use -std=gnu89 as default.
296-
target_enable_c99(PollyISL)
297-
target_enable_c99(polly-isl-test)
296+
set_property(TARGET PollyISL polly-isl-test PROPERTY C_STANDARD 99)
298297
endif (POLLY_BUNDLED_ISL)
299298

300299
set(PET_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/pet")

0 commit comments

Comments
 (0)