cmake: always split property lists (fixes #7228)

0.54
Daniel Mensinger 5 years ago committed by Nirbheek Chauhan
parent 4d82cfffc5
commit 8515ae2e0c
  1. 2
      mesonbuild/cmake/interpreter.py
  2. 5
      mesonbuild/cmake/traceparser.py
  3. 2
      test cases/cmake/2 advanced/subprojects/cmMod/CMakeLists.txt

@ -353,7 +353,7 @@ class ConverterTarget:
if 'CONFIGURATIONS' in tgt.properties:
cfgs += [x for x in tgt.properties['CONFIGURATIONS'] if x]
cfg = cfgs[0]
is_debug = self.env.coredata.get_builtin_option('debug');
if is_debug:
if 'DEBUG' in cfgs:

@ -64,6 +64,7 @@ class CMakeTarget:
return
for key, val in self.properties.items():
self.properties[key] = [x.strip() for x in val]
assert all([';' not in x for x in self.properties[key]])
class CMakeGeneratorTarget(CMakeTarget):
def __init__(self, name):
@ -574,10 +575,10 @@ class CMakeTraceParser:
continue
if mode in ['INTERFACE', 'LINK_INTERFACE_LIBRARIES', 'PUBLIC', 'LINK_PUBLIC']:
interface += [i]
interface += i.split(';')
if mode in ['PUBLIC', 'PRIVATE', 'LINK_PRIVATE']:
private += [i]
private += i.split(';')
if paths:
interface = self._guess_files(interface)

@ -20,7 +20,7 @@ set_target_properties(cmModLib PROPERTIES VERSION 1.0.1)
add_executable(testEXE main.cpp)
target_link_libraries(cmModLib ZLIB::ZLIB)
target_link_libraries(cmModLibStatic ZLIB::ZLIB)
target_link_libraries(cmModLibStatic ;ZLIB::ZLIB;)
target_link_libraries(testEXE cmModLib)
target_compile_definitions(cmModLibStatic PUBLIC CMMODLIB_STATIC_DEFINE)

Loading…
Cancel
Save