Skip to content

Commit 417cede

Browse files
committed
scope hack to non-aarch64 on "Bump pinned PT commit to 20250616 and mirror torch/standalone to ExecuTorch"
PyTorch added torch/standalone as a c10 dependency, so we need to mirror it to do a pin bump. Differential Revision: [D76909683](https://our.internmc.facebook.com/intern/diff/D76909683/) [ghstack-poisoned]
2 parents 973e62f + ec87933 commit 417cede

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

.ci/docker/common/install_conda.sh

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,25 @@ install_pip_dependencies() {
5454
popd
5555
}
5656

57+
fix_conda_ubuntu_libstdcxx() {
58+
cat /etc/issue
59+
# WARNING: This is a HACK from PyTorch core to be able to build PyTorch on 22.04.
60+
# Specifically, ubuntu-20+ all comes lib libstdc++ newer than 3.30+, but anaconda
61+
# is stuck with 3.29. So, remove libstdc++6.so.3.29 as installed by
62+
# https://anaconda.org/anaconda/libstdcxx-ng/files?version=11.2.0
63+
#
64+
# PyTorch sev: https://github.com/pytorch/pytorch/issues/105248
65+
# Ref: https://github.com/pytorch/pytorch/blob/main/.ci/docker/common/install_conda.sh
66+
if grep -e "2[02].04." /etc/issue >/dev/null; then
67+
rm /opt/conda/envs/py_${PYTHON_VERSION}/lib/libstdc++.so*
68+
fi
69+
}
70+
5771
install_miniconda
5872
install_python
5973
install_pip_dependencies
74+
# Hack breaks the job on aarch64 but is still necessary everywhere
75+
# else.
76+
if [ "$(uname -m)" != "aarch64" ]; then
77+
fix_conda_ubuntu_libstdcxx
78+
fi

0 commit comments

Comments
 (0)