Skip to content

Commit a88b998

Browse files
committed
[workflows] Fix libclc CI tests (#80942)
This was broken by 1a64260. (cherry picked from commit ab92f62)
1 parent 9e2e194 commit a88b998

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

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

+7-3
Original file line numberDiff line numberDiff line change
@@ -104,14 +104,16 @@ jobs:
104104
# This should be a no-op for non-mac OSes
105105
PKG_CONFIG_PATH: /usr/local/Homebrew/Library/Homebrew/os/mac/pkgconfig//12
106106
shell: bash
107+
id: build-llvm
107108
run: |
108109
if [ "${{ runner.os }}" == "Linux" ]; then
109110
builddir="/mnt/build/"
110111
sudo mkdir -p $builddir
111112
sudo chown `whoami`:`whoami` $builddir
112113
else
113-
builddir=build
114+
builddir="$(pwd)"/build
114115
fi
116+
echo "llvm-builddir=$builddir" >> "$GITHUB_OUTPUT"
115117
cmake -G Ninja \
116118
-B "$builddir" \
117119
-S llvm \
@@ -126,9 +128,11 @@ jobs:
126128
127129
- name: Build and Test libclc
128130
if: "!startsWith(matrix.os, 'windows') && contains(inputs.projects, 'libclc')"
131+
env:
132+
LLVM_BUILDDIR: ${{ steps.build-llvm.outputs.llvm-builddir }}
129133
run: |
130134
# Make sure all of LLVM libraries that llvm-config needs are built.
131-
ninja -C build
132-
cmake -G Ninja -S libclc -B libclc-build -DLLVM_DIR="$(pwd)"/build/lib/cmake/llvm -DLIBCLC_TARGETS_TO_BUILD="amdgcn--;amdgcn--amdhsa;r600--;nvptx--;nvptx64--;nvptx--nvidiacl;nvptx64--nvidiacl"
135+
ninja -C "$LLVM_BUILDDIR"
136+
cmake -G Ninja -S libclc -B libclc-build -DLLVM_DIR="$LLVM_BUILDDIR"/lib/cmake/llvm -DLIBCLC_TARGETS_TO_BUILD="amdgcn--;amdgcn--amdhsa;r600--;nvptx--;nvptx64--;nvptx--nvidiacl;nvptx64--nvidiacl"
133137
ninja -C libclc-build
134138
ninja -C libclc-build test

0 commit comments

Comments
 (0)