diff --git a/src/build/scanner.py b/src/build/scanner.py index 63f286994..fdb0addcf 100644 --- a/src/build/scanner.py +++ b/src/build/scanner.py @@ -31,6 +31,7 @@ import property import bjam +import os from b2.exceptions import * from b2.manager import get_manager @@ -103,7 +104,7 @@ class Scanner: # Common scanner class, which can be used when there's only one # kind of includes (unlike C, where "" and <> includes have different # search paths). -def CommonScanner(Scanner): +class CommonScanner(Scanner): def __init__ (self, includes): Scanner.__init__(self) @@ -114,8 +115,8 @@ def CommonScanner(Scanner): target_path = os.path.normpath(os.path.dirname(binding[0])) bjam.call("mark-included", target, matches) - engine.set_target_variable(matches, "SEARCH", - [target_path] + self.includes_) + get_manager().engine().set_target_variable(matches, "SEARCH", + [target_path] + self.includes) get_manager().scanners().propagate(self, matches) class ScannerRegistry: