add instruction to compile with new C++ ABI (#95177)

Fixes #ISSUE_NUMBER

Pull Request resolved: https://github.com/pytorch/pytorch/pull/95177
Approved by: https://github.com/jgong5, https://github.com/mingfeima, https://github.com/kit1980
This commit is contained in:
Jing Xu 2023-06-14 22:25:24 +00:00 committed by PyTorch MergeBot
parent 55cf5c00fa
commit 600f7dc211

View File

@ -231,6 +231,11 @@ git submodule update --init --recursive
#### Install PyTorch
**On Linux**
If you would like to compile PyTorch with [new C++ ABI](https://gcc.gnu.org/onlinedocs/libstdc++/manual/using_dual_abi.html) enabled, then first run this command:
```bash
export _GLIBCXX_USE_CXX11_ABI=1
```
If you're compiling for AMD ROCm then first run this command:
```bash
# Only run this if you're compiling for ROCm