From 5c2c3370d3f065f24b1026d43403c5c79275265b Mon Sep 17 00:00:00 2001 From: stevenknight Date: Tue, 27 Jan 2009 16:21:05 +0000 Subject: [PATCH] Detect the presence of 8.3 names on Windows when looking on-disk for whethr an entry exists. git-svn-id: http://scons.tigris.org/svn/scons/trunk@3922 fdb21ef1-2011-0410-befe-b5e4ea1792b1 --- src/engine/SCons/Node/FS.py | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/engine/SCons/Node/FS.py b/src/engine/SCons/Node/FS.py index 3742f345..e601a670 100644 --- a/src/engine/SCons/Node/FS.py +++ b/src/engine/SCons/Node/FS.py @@ -1735,9 +1735,19 @@ class Dir(Base): pass else: for entry in map(_my_normcase, entries): - d[entry] = 1 + d[entry] = True self.on_disk_entries = d - return d.has_key(_my_normcase(name)) + if sys.platform == 'win32': + name = _my_normcase(name) + result = d.get(name) + if result is None: + # Belt-and-suspenders for Windows: check directly for + # 8.3 file names that don't show up in os.listdir(). + result = os.path.exists(self.abspath + os.sep + name) + d[name] = result + return result + else: + return d.has_key(name) memoizer_counters.append(SCons.Memoize.CountValue('srcdir_list')) -- 2.26.2