Skip to content

Commit 24bf5da

Browse files
committed
update
1 parent 09cd3a3 commit 24bf5da

File tree

2 files changed

+5
-15
lines changed

2 files changed

+5
-15
lines changed

Sonarcloud.cmake

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ set(_sonarcloud_newline "\\\n ")
1717
function(transform_sonarcloud_source_files output_variable target)
1818
#
1919
# Based off of https://cmake.org/cmake/help/latest/prop_tgt/SOURCES.html we
20-
# need to correcty interpret the SOURCES properties to be able to transform
21-
# them into what sonarcloud project properties is comfortable with (ie. paths
22-
# from project source directory
20+
# need to correctly interpret the SOURCES properties to be able to transform
21+
# them into what sonarcloud project properties is comfortable with (ie.
22+
# relative path from project source directory).
2323
#
2424
get_target_property(target_binary_dir ${target} BUILD_DIR)
2525
get_target_property(target_source_dir ${target} SOURCE_DIR)
@@ -85,17 +85,8 @@ function(extract_sonarcloud_project_files output_project_source_files output_pro
8585

8686
foreach (target IN LISTS ARGN)
8787
get_target_property(target_type ${target} TYPE)
88-
if (${target_type} STREQUAL "INTERFACE_LIBRARY")
89-
get_target_property(swift_project ${target} INTERFACE_SWIFT_PROJECT)
90-
else()
91-
get_target_property(swift_project ${target} SWIFT_PROJECT)
92-
endif()
93-
94-
if(NOT ${swift_project} STREQUAL ${PROJECT_NAME})
95-
continue()
96-
endif()
9788

98-
if (NOT ${target_type} STREQUAL "INTERFACE_LIBRARY")
89+
if (NOT target_type STREQUAL "INTERFACE_LIBRARY")
9990
get_target_property(target_source_files ${target} SOURCES)
10091
if (target_source_files)
10192
transform_sonarcloud_source_files(target_source_files ${target} ${target_source_files})
@@ -140,7 +131,7 @@ endfunction()
140131
function(generate_sonarcloud_project_properties sonarcloud_project_properties_path)
141132
if (NOT IS_ABSOLUTE ${sonarcloud_project_properties_path})
142133
message(FATAL_ERROR "Function \"generate_sonarcloud_project_properties\""
143-
"only accepts sonarcloud project properties output as absolute paths")
134+
"only accepts absolute paths to avoid ambiguity")
144135
endif()
145136

146137
if (NOT ${PROJECT_SOURCE_DIR} STREQUAL ${CMAKE_CURRENT_SOURCE_DIR})

SwiftTargets.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,6 @@ define_property(TARGET
181181
BRIEF_DOCS "Target's source directory"
182182
FULL_DOCS "Identical use as SOURCE_DIR except that this applies to ALL target types, including INTERFACE")
183183

184-
185184
macro(swift_collate_arguments prefix name)
186185
set(exclusion_list ${ARGN})
187186
set(${name}_args "")

0 commit comments

Comments
 (0)