aedi: target filter for cmake modules allows hyphen in target names

This commit is contained in:
alexey.lysiuk 2021-07-25 12:04:19 +03:00
parent 3df0e9dc2b
commit 92bb063a74

View file

@ -460,8 +460,8 @@ class CMakeStaticDependencyTarget(CMakeTarget):
def keep_module_target(self, state: BuildState, target: str):
import_patterns = (
r'list\s*\(APPEND\s+_IMPORT_CHECK_TARGETS\s+(?P<target>\w+::\w+)[\s)]',
r'list\s*\(APPEND\s+_IMPORT_CHECK_FILES_FOR_(?P<target>\w+::\w+)\s',
r'list\s*\(APPEND\s+_IMPORT_CHECK_TARGETS\s+(?P<target>\w+::[\w-]+)[\s)]',
r'list\s*\(APPEND\s+_IMPORT_CHECK_FILES_FOR_(?P<target>\w+::[\w-]+)\s',
)
import_regexes = [re.compile(regex, re.IGNORECASE) for regex in import_patterns]