Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix iOS simulator build (pytorch#25633)
Summary: Pull Request resolved: pytorch#25633 The iOS simulator build (x86_64) is broken right now. To fix it: 1. Fix the bug in iOS.cmake 2. Disable avx2 for mobile x86_64 build Test Plan: 1. The `build_ios.sh` can be run successfully for iOS x86 build. The build script I'm using: ```shell ./scripts/build_ios.sh \ -DBUILD_CAFFE2_MOBILE=OFF \ -DIOS_PLATFORM=SIMULATOR \ -DUSE_NNPACK=OFF \ -DCMAKE_PREFIX_PATH=$(python -c 'from distutils.sysconfig import get_python_lib; print(get_python_lib())') \ -DPYTHON_EXECUTABLE=$(python -c 'import sys; print(sys.executable)') ``` 2. All generated static libs are x86 libs as shown below ``` > lipo -i *.a Non-fat file: libasmjit.a is architecture: x86_64 Non-fat file: libc10.a is architecture: x86_64 Non-fat file: libcaffe2_protos.a is architecture: x86_64 Non-fat file: libclog.a is architecture: x86_64 Non-fat file: libcpuinfo.a is architecture: x86_64 Non-fat file: libfbgemm.a is architecture: x86_64 Non-fat file: libtorch.a is architecture: x86_64 Differential Revision: D17183803 Pulled By: xta0 fbshipit-source-id: 870d5433a3616b8e7ed9fb7dfab6aebbda26f723
- Loading branch information