Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Change cmake to build googletest from source (#3319)
Summary: In the #3278, we to find_package to link to GTest. However, it needs to have googletest to build independently. Not everyone builds their googletest locally first. In this diff, we still try to build googletest from source and combine find_package together. Pull Request resolved: #3319 Test Plan: STEP 1: Install deps ``` conda install -y -q python=3.11 cmake make swig=4.0.2 mkl=2023 mkl-devel=2023 numpy scipy pytest gxx_linux-64 sysroot_linux-64 ``` STEP2: Compile ``` cmake -B build \ -DBUILD_TESTING=ON \ -DBUILD_SHARED_LIBS=ON \ -DFAISS_ENABLE_GPU=OFF \ -DFAISS_ENABLE_RAFT=OFF \ -DFAISS_OPT_LEVEL=avx2 \ -DFAISS_ENABLE_C_API=ON \ -DPYTHON_EXECUTABLE=$(which python) \ -DCMAKE_BUILD_TYPE=Release \ -DBLA_VENDOR=Intel10_64_dyn \ -DCMAKE_CUDA_FLAGS="-gencode arch=compute_75,code=sm_75" \ . ``` Reviewed By: algoriddle Differential Revision: D55358059 Pulled By: junjieqi fbshipit-source-id: 95ad4a745238b88b438728de64173f99d3d50dbe
- Loading branch information