File tree Expand file tree Collapse file tree 2 files changed +12
-5
lines changed Expand file tree Collapse file tree 2 files changed +12
-5
lines changed Original file line number Diff line number Diff line change @@ -40,9 +40,6 @@ RUN yum -y install \
4040 wget \
4141 which
4242
43- # Install ninja-build to save build-time
44- RUN yum -y install ninja-build && ln -s /usr/bin/ninja-build /usr/bin/ninja
45-
4643RUN mkdir -p /usr/local/lib/python3.7/site-packages/
4744
4845RUN easy_install-3.7 six
@@ -92,7 +89,7 @@ ENV PATH="${SWIFT_PREFIX}/usr/bin:${PATH}"
9289
9390
9491COPY ./swift-ci/main/install-extra-packages.sh /tmp/install-extra-packages.sh
95- RUN /tmp/install-extra-packages.sh cmake sccache && rm /tmp/install-extra-packages.sh
92+ RUN /tmp/install-extra-packages.sh cmake sccache ninja && rm /tmp/install-extra-packages.sh
9693
9794USER build-user
9895
Original file line number Diff line number Diff line change @@ -8,7 +8,8 @@ install_wasmtime() {
88
99install_cmake () {
1010 local version=" 3.29.7"
11- local workdir=" $( mktemp -d) "
11+ local workdir
12+ workdir=" $( mktemp -d) "
1213 curl -L -o " $workdir /install_cmake.sh" " https://github.com/Kitware/CMake/releases/download/v$version /cmake-$version -linux-$( uname -m) .sh"
1314 chmod +x " $workdir /install_cmake.sh"
1415 " $workdir /install_cmake.sh" --skip-license --prefix=" $PREFIX "
@@ -26,6 +27,15 @@ install_sccache() {
2627 ln -sf " $PREFIX /sccache/sccache" " $PREFIX /bin/sccache"
2728}
2829
30+ install_ninja () {
31+ local version=" v1.11.1"
32+ local workdir
33+ workdir=" $( mktemp -d) "
34+ curl -L " https://github.com/ninja-build/ninja/archive/refs/tags/$version .tar.gz" | tar xz --strip-component=1
35+ cmake -B " $workdir " -S . -DCMAKE_INSTALL_PREFIX=" $PREFIX "
36+ cmake --build " $workdir " --target install -- -j " $( nproc) "
37+ }
38+
2939# ./install-extra-packages.sh [package1] [package2] ...
3040# Install packages into $PREFIX (default: /usr/local)
3141
You can’t perform that action at this time.
0 commit comments