<s> """<STR_LIT>""" <EOL> __revision__ = "<STR_LIT>" <EOL> import SCons . Action <EOL> import SCons . Builder <EOL> import SCons . Defaults <EOL> import SCons . Scanner . IDL <EOL> import SCons . Util <EOL> from MSCommon import msvc_exists <EOL> def midl_emitter ( target , source , env ) : <EOL> """<STR_LIT>""" <EOL> base , ext = SCons . Util . splitext ( str ( target [ <NUM_LIT:0> ] ) ) <EOL> tlb = target [ <NUM_LIT:0> ] <EOL> incl = base + '<STR_LIT>' <EOL> interface = base + '<STR_LIT>' <EOL> t = [ tlb , incl , interface ] <EOL> midlcom = env [ '<STR_LIT>' ] <EOL> if midlcom . find ( '<STR_LIT>' ) != - <NUM_LIT:1> : <EOL> proxy = base + '<STR_LIT>' <EOL> t . append ( proxy ) <EOL> if midlcom . find ( '<STR_LIT>' ) != - <NUM_LIT:1> : <EOL> dlldata = base + '<STR_LIT>' <EOL> t . append ( dlldata ) <EOL> return ( t , source ) <EOL> idl_scanner = SCons . Scanner . IDL . IDLScan ( ) <EOL> midl_action = SCons . Action . Action ( '<STR_LIT>' , '<STR_LIT>' ) <EOL> midl_builder = SCons . Builder . Builder ( action = midl_action , <EOL> src_suffix = '<STR_LIT>' , <EOL> suffix = '<STR_LIT>' , <EOL> emitter = midl_emitter , <EOL> source_scanner = idl_scanner ) <EOL> def generate ( env ) : <EOL> """<STR_LIT>""" <EOL> env [ '<STR_LIT>' ] = '<STR_LIT>' <EOL> env [ '<STR_LIT>' ] = SCons . Util . CLVar ( '<STR_LIT>' ) <EOL> env [ '<STR_LIT>' ] = '<STR_LIT>' <EOL> env [ '<STR_LIT>' ] [ '<STR_LIT>' ] = midl_builder <EOL> def exists ( env ) : <EOL> return msvc_exists ( ) </s>
