Skip to content

Commit fe3fcf7

Browse files
authored
build: Downgrade patchelf version from 0.18.0 to 0.17.2 (#7959)
Co-authored-by: Ryan McCormick <[email protected]> Patchelf shipped a regression in 0.18.0 and has since yanked the pypi release pointing to 0.17.2 as the most recent version. However, 0.18.0 is still the version shipped in both the apt and yum repositories, thus we must use pip to install the version we want. See mayeut/patchelf-pypi#87
1 parent 3679084 commit fe3fcf7

File tree

2 files changed

+12
-9
lines changed

2 files changed

+12
-9
lines changed

build.py

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -962,7 +962,6 @@ def create_dockerfile_buildbase_rhel(ddir, dockerfile_name, argmap):
962962
libcurl-devel \\
963963
libb64-devel \\
964964
gperftools-devel \\
965-
patchelf \\
966965
python3-pip \\
967966
python3-setuptools \\
968967
rapidjson-devel \\
@@ -990,7 +989,8 @@ def create_dockerfile_buildbase_rhel(ddir, dockerfile_name, argmap):
990989
wheel \\
991990
setuptools \\
992991
docker \\
993-
virtualenv
992+
virtualenv \\
993+
patchelf==0.17.2
994994
995995
# Install boost version >= 1.78 for boost::span
996996
# Current libboost-dev apt packages are < 1.78, so install from tar.gz
@@ -1089,7 +1089,6 @@ def create_dockerfile_buildbase(ddir, dockerfile_name, argmap):
10891089
libcurl4-openssl-dev \\
10901090
libb64-dev \\
10911091
libgoogle-perftools-dev \\
1092-
patchelf \\
10931092
python3-dev \\
10941093
python3-pip \\
10951094
python3-wheel \\
@@ -1110,7 +1109,8 @@ def create_dockerfile_buildbase(ddir, dockerfile_name, argmap):
11101109
RUN pip3 install --upgrade \\
11111110
build \\
11121111
docker \\
1113-
virtualenv
1112+
virtualenv \\
1113+
patchelf==0.17.2
11141114
11151115
# Install boost version >= 1.78 for boost::span
11161116
# Current libboost-dev apt packages are < 1.78, so install from tar.gz
@@ -1354,11 +1354,13 @@ def dockerfile_prepare_container_linux(argmap, backends, enable_gpu, target_mach
13541354
libcurl-devel \\
13551355
libb64-devel \\
13561356
gperftools-devel \\
1357-
patchelf \\
13581357
wget \\
13591358
python3-pip \\
13601359
numactl-devel
13611360
1361+
RUN pip3 install --upgrade pip \\
1362+
&& pip3 install patchelf==0.17.2
1363+
13621364
"""
13631365
else:
13641366
df += """
@@ -1562,7 +1564,9 @@ def add_cpu_libs_to_linux_dockerfile(backends, target_machine):
15621564
15631565
# patchelf is needed to add deps of libcublasLt.so.12 to libtorch_cuda.so
15641566
RUN apt-get update \\
1565-
&& apt-get install -y --no-install-recommends openmpi-bin patchelf
1567+
&& apt-get install -y --no-install-recommends openmpi-bin
1568+
RUN pip3 install --upgrade pip \\
1569+
&& pip3 install patchelf==0.17.2
15661570
15671571
ENV LD_LIBRARY_PATH /usr/local/cuda/targets/{cuda_arch}-linux/lib:/usr/local/cuda/lib64/stubs:${{LD_LIBRARY_PATH}}
15681572
""".format(

docs/user_guide/jetson.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
# Copyright 2021-2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
2+
# Copyright 2021-2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
33
#
44
# Redistribution and use in source and binary forms, with or without
55
# modification, are permitted provided that the following conditions
@@ -82,7 +82,6 @@ apt-get update && \
8282
libtool \
8383
libboost-dev \
8484
rapidjson-dev \
85-
patchelf \
8685
pkg-config \
8786
libopenblas-dev \
8887
libarchive-dev \
@@ -95,7 +94,7 @@ apt-get update && \
9594
Additional Onnx Runtime dependencies must be installed to build the Onnx Runtime backend:
9695

9796
```
98-
pip3 install --upgrade flake8 flatbuffers
97+
pip3 install --upgrade flake8 flatbuffers patchelf==0.17.2
9998
```
10099

101100
Additional PyTorch dependencies must be installed to build (and run) the PyTorch backend:

0 commit comments

Comments
 (0)