prepend modules with autocmake_ to avoid namespace issues
This commit is contained in:
parent
87205c4c8a
commit
4755abbd31
@ -211,7 +211,7 @@ def gen_cmakelists(config, relative_path, list_of_modules):
|
|||||||
s.append('\n')
|
s.append('\n')
|
||||||
s.append('# included cmake modules')
|
s.append('# included cmake modules')
|
||||||
for m in list_of_modules:
|
for m in list_of_modules:
|
||||||
s.append('include(%s)' % os.path.splitext(m)[0])
|
s.append('include(autocmake_%s)' % os.path.splitext(m)[0])
|
||||||
|
|
||||||
s.append('\n')
|
s.append('\n')
|
||||||
s.append('add_subdirectory(${PROJECT_SOURCE_DIR}/src)')
|
s.append('add_subdirectory(${PROJECT_SOURCE_DIR}/src)')
|
||||||
@ -240,7 +240,7 @@ def fetch_modules(config, module_directory):
|
|||||||
for src in config.get(section, 'source').split('\n'):
|
for src in config.get(section, 'source').split('\n'):
|
||||||
module_name = os.path.basename(src)
|
module_name = os.path.basename(src)
|
||||||
list_of_modules.append(module_name)
|
list_of_modules.append(module_name)
|
||||||
dst = os.path.join(module_directory, module_name)
|
dst = os.path.join(module_directory, 'autocmake_%s' % module_name)
|
||||||
if 'http' in src:
|
if 'http' in src:
|
||||||
fetch_url(src, dst)
|
fetch_url(src, dst)
|
||||||
else:
|
else:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user