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

Side by Side Diff: src/scripts/check_deps

Issue 1100004: Adding another special directory to check_deps script (Closed)
Patch Set: Created 10 years, 9 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 2
3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. 3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 import os 7 import os
8 import re 8 import re
9 import sys 9 import sys
10 10
(...skipping 16 matching lines...) Expand all
27 self._libcache = set() 27 self._libcache = set()
28 self._verbose = verbose 28 self._verbose = verbose
29 29
30 # Insert some default directories into our library cache. 30 # Insert some default directories into our library cache.
31 # The /usr/lib/nss and /usr/lib/nspr directories are 31 # The /usr/lib/nss and /usr/lib/nspr directories are
32 # required for understanding old-style Netscape plugins. 32 # required for understanding old-style Netscape plugins.
33 self._ReadLibs([ 33 self._ReadLibs([
34 "%s/lib" % root, 34 "%s/lib" % root,
35 "%s/usr/lib" % root, 35 "%s/usr/lib" % root,
36 "%s/usr/lib/nss" % root, 36 "%s/usr/lib/nss" % root,
37 "%s/usr/lib/nspr" % root 37 "%s/usr/lib/nspr" % root,
38 "%s/opt/google/o3d/lib" % root
38 ], self._libcache) 39 ], self._libcache)
39 40
40 def _ReadLibs(self, paths, libcache): 41 def _ReadLibs(self, paths, libcache):
41 for path in paths: 42 for path in paths:
42 if os.path.exists(path): 43 if os.path.exists(path):
43 for lib in os.listdir(path): 44 for lib in os.listdir(path):
44 libcache.add(lib) 45 libcache.add(lib)
45 46
46 def _ReadDependencies(self, binary): 47 def _ReadDependencies(self, binary):
47 """Run readelf -d on BINARY, returning (deps, rpaths).""" 48 """Run readelf -d on BINARY, returning (deps, rpaths)."""
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 if not checker.CheckDependencies(binary): 118 if not checker.CheckDependencies(binary):
118 errors = True 119 errors = True
119 120
120 if errors: 121 if errors:
121 sys.exit(1) 122 sys.exit(1)
122 else: 123 else:
123 sys.exit(0) 124 sys.exit(0)
124 125
125 if __name__ == "__main__": 126 if __name__ == "__main__":
126 main() 127 main()
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698