clang 8 is required for cuda 10.2.
Code: Select all
#!/bin/bash
#sudo apt-get install clang
## the dependencies
#sudo apt-get install ninja-build git cmake
#sudo apt-get install libjpeg-dev libopenmpi-dev libomp-dev ccache
#sudo apt-get install libopenblas-dev libblas-dev libeigen3-dev
#sudo -H pip3 install -U --user wheel mock pillow
export BUILD_CAFFE2_OPS=OFF
export USE_FBGEMM=OFF
export USE_FAKELOWP=OFF
export BUILD_TEST=OFF
export USE_MKLDNN=OFF
export USE_NNPACK=ON
export USE_XNNPACK=ON
export USE_QNNPACK=ON
export MAX_JOBS=4
export USE_OPENCV=OFF
export USE_NCCL=OFF
export USE_SYSTEM_NCCL=OFF
export PATH=/usr/lib/ccache:$PATH
# set clang compiler
export CC=clang-8
export CXX=clang++-8
# clean up the previous build, if necessary
#python3 setup.py clean
# start the build
python3 setup.py bdist_wheel