mirror of
https://gitlab.com/ita1024/waf.git
synced 2024-11-21 17:35:55 +01:00
When creating the waf script, assume that the 'extras' folder only contains Python files
Files are also listed in a static arbitrary order.
This commit is contained in:
parent
4ed9af0ee9
commit
2e58ac4134
25
wscript
25
wscript
@ -258,20 +258,19 @@ def create_waf(self, *k, **kw):
|
||||
for x in Options.options.coretools.split(','):
|
||||
coretools.append(x + '.py')
|
||||
|
||||
for d in '. Tools extras'.split():
|
||||
dd = os.path.join('waflib', d)
|
||||
for k in os.listdir(dd):
|
||||
if k == '__init__.py':
|
||||
files.append(os.path.normpath(os.path.join(dd, k)))
|
||||
up_node = self.generator.bld.path
|
||||
for node in up_node.find_dir('waflib').ant_glob(incl=['*.py', 'Tools/*.py', 'extras/*.py']):
|
||||
relpath = node.path_from(up_node)
|
||||
if node.name == '__init__.py':
|
||||
files.append(relpath)
|
||||
continue
|
||||
if node.parent.name == 'Tools' and Options.options.coretools != 'default':
|
||||
if node.name not in coretools:
|
||||
continue
|
||||
if d == 'Tools' and Options.options.coretools != 'default':
|
||||
if not k in coretools:
|
||||
continue
|
||||
if d == 'extras':
|
||||
if not k in add3rdparty:
|
||||
continue
|
||||
if k.endswith('.py'):
|
||||
files.append(os.path.normpath(os.path.join(dd, k)))
|
||||
if node.parent.name == 'extras':
|
||||
if node.name not in add3rdparty:
|
||||
continue
|
||||
files.append(relpath)
|
||||
|
||||
if Options.options.namesfrom:
|
||||
with tarfile.open(Options.options.namesfrom) as tar:
|
||||
|
Loading…
Reference in New Issue
Block a user