Skip to content

Commit 5fe751d

Browse files
committed
[workflows] Use /mnt as the build directory on Linux (llvm#80583)
There is more space available on /mnt (~56G) than on / (~30G), and we are starting to see some of the CI jobs run out of disk space on Linux. (cherry picked from commit 1a64260)
1 parent a47808e commit 5fe751d

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

.github/workflows/llvm-project-tests.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,15 @@ jobs:
106106
PKG_CONFIG_PATH: /usr/local/Homebrew/Library/Homebrew/os/mac/pkgconfig//12
107107
shell: bash
108108
run: |
109+
if [ "${{ runner.os }}" == "Linux" ]; then
110+
builddir="/mnt/build/"
111+
sudo mkdir -p $builddir
112+
sudo chown `whoami`:`whoami` $builddir
113+
else
114+
builddir=build
115+
fi
109116
cmake -G Ninja \
110-
-B build \
117+
-B "$builddir" \
111118
-S llvm \
112119
-DLLVM_ENABLE_PROJECTS="${{ inputs.projects }}" \
113120
-DCMAKE_BUILD_TYPE=Release \
@@ -116,7 +123,7 @@ jobs:
116123
-DCMAKE_C_COMPILER_LAUNCHER=sccache \
117124
-DCMAKE_CXX_COMPILER_LAUNCHER=sccache \
118125
${{ inputs.extra_cmake_args }}
119-
ninja -C build '${{ inputs.build_target }}'
126+
ninja -C "$builddir" '${{ inputs.build_target }}'
120127
121128
- name: Build and Test libclc
122129
if: "!startsWith(matrix.os, 'windows') && contains(inputs.projects, 'libclc')"

0 commit comments

Comments
 (0)