Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(29)

Unified Diff: tools/isolate_driver.py

Issue 1320793004: Fix sbox_validation_tests & Make isolate_driver.py include the executable itself (Closed) Base URL: https://chromium.googlesource.com/a/chromium/src.git@master
Patch Set: Fix for official build Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/gn/gn_unittests.isolate ('k') | ui/accessibility/accessibility_unittests.isolate » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/isolate_driver.py
diff --git a/tools/isolate_driver.py b/tools/isolate_driver.py
index c5d80fc01a1a04aaa26e300ddaa5dbf1abc620db..f75b4bdf71995e9928e8eac3c10499034e6a7efc 100755
--- a/tools/isolate_driver.py
+++ b/tools/isolate_driver.py
@@ -118,9 +118,9 @@ def using_blacklist(item):
if item.endswith('.isolated.gen.json'):
return True
IGNORED = (
- '.a', '.cc', '.css', '.def', '.frag', '.h', '.html', '.js', '.json',
- '.manifest', '.o', '.obj', '.pak', '.png', '.pdb', '.strings', '.test',
- '.txt', '.vert',
+ '.a', '.cc', '.css', '.dat', '.def', '.frag', '.h', '.html', '.isolate',
+ '.js', '.json', '.manifest', '.o', '.obj', '.pak', '.png', '.pdb', '.py',
+ '.strings', '.test', '.txt', '.vert',
)
# ninja files use native path format.
ext = os.path.splitext(item)[1]
@@ -180,11 +180,16 @@ def post_process_deps(build_dir, dependencies):
return i[:-4]
return i
- def f(i):
+ def is_exe(i):
# This script is only for adding new binaries that are created as part of
# the component build.
ext = os.path.splitext(i)[1]
- if ext not in ['.dll', '.nexe', '.so', '.dylib']:
+ # On POSIX, executables have no extension.
+ if ext not in ('', '.dll', '.dylib', '.exe', '.nexe', '.so'):
+ return False
+ if os.path.isabs(i):
+ # In some rare case, there's dependency set explicitly on files outside
+ # the checkout.
return False
# Check for execute access and strip directories. This gets rid of all the
@@ -192,7 +197,7 @@ def post_process_deps(build_dir, dependencies):
p = os.path.join(build_dir, i)
return os.access(p, os.X_OK) and not os.path.isdir(p)
- return filter(f, map(filter_item, dependencies))
+ return filter(is_exe, map(filter_item, dependencies))
def create_wrapper(args, isolate_index, isolated_index):
« no previous file with comments | « tools/gn/gn_unittests.isolate ('k') | ui/accessibility/accessibility_unittests.isolate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698