Index: source/test/depstest/depstest.py |
diff --git a/source/test/depstest/depstest.py b/source/test/depstest/depstest.py |
index bcc527b8e15a1bdc3e9b399e46cd12693c2a1538..51bdf2b58d469fc53f4008c16e4a04033fbb5e99 100755 |
--- a/source/test/depstest/depstest.py |
+++ b/source/test/depstest/depstest.py |
@@ -1,7 +1,7 @@ |
#! /usr/bin/python |
# -*- coding: utf-8 -*- |
# |
-# Copyright (C) 2011, International Business Machines |
+# Copyright (C) 2011-2014, International Business Machines |
# Corporation and others. All Rights Reserved. |
# |
# file name: depstest.py |
@@ -127,8 +127,13 @@ def _Resolve(name, parents): |
for symbol in imports: |
for file_name in files: |
if symbol in _obj_files[file_name]["imports"]: |
- sys.stderr.write("Error: %s %s file %s imports %s but %s does not depend on %s\n" % |
- (item_type, name, file_name, symbol, name, _symbols_to_files.get(symbol))) |
+ neededFile = _symbols_to_files.get(symbol) |
+ if neededFile in dependencies.file_to_item: |
+ neededItem = "but %s does not depend on %s (for %s)" % (name, dependencies.file_to_item[neededFile], neededFile) |
+ else: |
+ neededItem = "- is this a new system symbol?" |
+ sys.stderr.write("Error: in %s %s: %s imports %s %s\n" % |
+ (item_type, name, file_name, symbol, neededItem)) |
_return_value = 1 |
del parents[-1] |
return item |
@@ -183,6 +188,8 @@ def main(): |
print "Info: ignored symbols:\n%s" % sorted(_ignored_symbols) |
if not _return_value: |
print "OK: Specified and actual dependencies match." |
+ else: |
+ print "Error: There were errors, please fix them and re-run. Processing may have terminated abnormally." |
return _return_value |
if __name__ == "__main__": |