<s> """<STR_LIT>""" <EOL> import logging <EOL> import os <EOL> import subprocess <EOL> import sys <EOL> import gflags <EOL> FLAGS = gflags . FLAGS <EOL> def verify_binary ( flag_name , process_args = None ) : <EOL> """<STR_LIT>""" <EOL> if process_args is None : <EOL> process_args = [ ] <EOL> path = getattr ( FLAGS , flag_name ) <EOL> if not path : <EOL> logging . error ( '<STR_LIT>' % flag_name ) <EOL> sys . exit ( <NUM_LIT:1> ) <EOL> with open ( os . devnull , '<STR_LIT:w>' ) as dev_null : <EOL> try : <EOL> subprocess . check_call ( <EOL> [ path ] + process_args , <EOL> stdout = dev_null , <EOL> stderr = subprocess . STDOUT ) <EOL> except : <EOL> logging . exception ( '<STR_LIT>' , <EOL> flag_name , path ) <EOL> sys . exit ( <NUM_LIT:1> ) </s>
