Browse Source

dist: don't search same directory for dependencies more than once

rdb 5 years ago
parent
commit
8e39072f6f
1 changed files with 4 additions and 1 deletions
  1. 4 1
      direct/src/dist/commands.py

+ 4 - 1
direct/src/dist/commands.py

@@ -1080,7 +1080,10 @@ class build_apps(setuptools.Command):
         source_dir = os.path.dirname(source_path)
         target_dir = os.path.dirname(target_path)
         base = os.path.basename(target_path)
-        self.copy_dependencies(target_path, target_dir, search_path + [source_dir], base)
+
+        if source_dir not in search_path:
+            search_path = search_path + [source_dir]
+        self.copy_dependencies(target_path, target_dir, search_path, base)
 
     def copy_dependencies(self, target_path, target_dir, search_path, referenced_by):
         """ Copies the dependencies of target_path into target_dir. """