瀏覽代碼

Use libc++ for xcode 10 (#5303)

The xcode 10 removes the deprecated libstdc++ library. We could set
"MACOSX_DEPLOYMENT_TARGET" to "10.9" to use libc++ instead.
Jerry 6 年之前
父節點
當前提交
28f8e5c3e4
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      python/setup.py

+ 3 - 0
python/setup.py

@@ -186,6 +186,9 @@ if __name__ == '__main__':
         extra_compile_args.append('-Wno-invalid-offsetof')
         extra_compile_args.append('-Wno-sign-compare')
 
+    if sys.platform == 'darwin':
+      os.environ['MACOSX_DEPLOYMENT_TARGET'] = '10.9'
+
     # https://github.com/Theano/Theano/issues/4926
     if sys.platform == 'win32':
       extra_compile_args.append('-D_hypot=hypot')