Commits

William Deegan committed 058e71e

restore SCONS_LIB_DIR to primary choice for SCons logic, then source tree from which it was run.

  • Participants
  • Parent commits e19c805

Comments (0)

Files changed (1)

src/script/scons.py

 import os
 import sys
 
+
 ##############################################################################
 # BEGIN STANDARD SCons SCRIPT HEADER
 #
 if "SCONS_LIB_DIR" in os.environ:
     libs.append(os.environ["SCONS_LIB_DIR"])
 
+# - running from source takes priority (since 2.3.2)
+script_path = os.path.abspath(os.path.dirname(__file__))
+source_path = os.path.join(script_path, '..', 'engine')
+libs.append(source_path)
+
 local_version = 'scons-local-' + __version__
 local = 'scons-local'
 if script_dir:
 # preferred order of scons lookup paths
 prefs = []
 
-# - running from source takes priority (since 2.3.2)
-script_path = os.path.abspath(os.path.dirname(__file__))
-source_path = os.path.join(script_path, '..', 'engine')
 
 # - running from egg check
 try:
 libs.extend([os.path.join(x, scons_version) for x in prefs])
 libs.extend([os.path.join(x, 'scons') for x in prefs])
 
-sys.path = [source_path] + libs + sys.path
+sys.path = libs + sys.path
 
 ##############################################################################
 # END STANDARD SCons SCRIPT HEADER