Fix some issues on MacOS platform (#937)

Fix some issues on MacOS platform
- Enable libc-wasi by default
- Set target abi to "gnu" if it is not set for wamrc to avoid generating
  object file of unsupported Mach-O format
- Set `<vendor>-<sys>` info according to target abi for wamrc to support
  generating AOT file for other OSs but not current host
- Set cpu name if arch/abi/cpu are not set to avoid checking SIMD
  capability failed
- Set size level to 1 for MacOS/Windows platform to avoid relocation type
  unsupported warning
- Clear posix_memmap.c compiling warning
- Fix spec case test script issues, enable test spec cases on MacOS

Signed-off-by: Wenyong Huang <wenyong.huang@intel.com>
This commit is contained in:
Wenyong Huang
2022-01-07 09:53:48 +08:00
committed by GitHub
parent 308d31c621
commit cb51dbb513
6 changed files with 106 additions and 10 deletions

View File

@ -21,7 +21,8 @@ import time
The script itself has to be put under the same directory with the "spec".
"""
IWASM_CMD = "../../../product-mini/platforms/linux/build/iwasm"
PLATFORM_NAME = os.uname().sysname.lower()
IWASM_CMD = "../../../product-mini/platforms/" + PLATFORM_NAME + "/build/iwasm"
IWASM_SGX_CMD = "../../../product-mini/platforms/linux-sgx/enclave-sample/iwasm"
SPEC_TEST_DIR = "spec/test/core"
WAST2WASM_CMD = "./wabt/out/gcc/Release/wat2wasm"

View File

@ -141,6 +141,8 @@ class Runner():
os.killpg(self.p.pid, signal.SIGTERM)
except OSError:
pass
except IOError:
pass
self.p = None
self.stdin.close()
if self.stdin != self.stdout: