Example #1
0
 def __init__(self):
     # look for wabt in the path. if it's not here, don't run wasm2c
     try:
         wabt_bin = shared.which('wasm2c')
         wabt_root = os.path.dirname(os.path.dirname(wabt_bin))
         self.wasm2c_dir = os.path.join(wabt_root, 'wasm2c')
         if not os.path.isdir(self.wasm2c_dir):
             print('wabt found, but not wasm2c support dir')
             self.wasm2c_dir = None
     except Exception as e:
         print('warning: no wabt found:', e)
         self.wasm2c_dir = None
Example #2
0
            def __init__(self):
                super(Wasm2C2Wasm, self).__init__()

                self.has_emcc = shared.which('emcc') is not None