diff --git a/check_binary.sh b/check_binary.sh index 58a19fffa..eaf29a1fe 100755 --- a/check_binary.sh +++ b/check_binary.sh @@ -435,8 +435,8 @@ fi ############################################################################### # Check for C++ ABI compatibility between gcc7 and gcc9 compiled binaries ############################################################################### -if [[ "$(uname)" == 'Linux' && ("$PACKAGE_TYPE" == 'conda' || "$PACKAGE_TYPE" == 'manywheel') && GLIBCXX_USE_CXX11_ABI=0 ]]; then +if [[ "$(uname)" == 'Linux' && ("$PACKAGE_TYPE" == 'conda' || "$PACKAGE_TYPE" == 'manywheel')]]; then pushd /tmp - python -c "import torch; exit(0 if torch._C._PYBIND11_BUILD_ABI == '_cxxabi1011' else 1)" + python -c "import torch; exit(0 if torch.compiled_with_cxx11_abi() else (0 if torch._C._PYBIND11_BUILD_ABI == '_cxxabi1011' else 1))" popd fi