Skip to content

Commit b8f9ddb

Browse files
committed
grrrr
1 parent 2db4bb9 commit b8f9ddb

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

conda-recipe/build.sh

+9-6
Original file line numberDiff line numberDiff line change
@@ -34,16 +34,19 @@ if [ ! -d "${INSTALLED_DIR}/imex/lib" ]; then
3434
# as long as the conda packages differ from system oneAPI installs we need to explicitly provide the include dir for SYCL
3535
# see also below in cmake call
3636
for root in "${CONDA_PREFIX}" "${BUILD_PREFIX}"; do
37-
spirvdir=$(find "${root}" -d -name __spirv | head -n 1)
37+
spirvdir=$(find "${root}" -type d -name __spirv | head -n 1)
3838
if [ -d "${spirvdir}" ]; then
39-
SYCL_INC_DIR=$(dirname $(dirname "${spirvdir}"))
39+
SPIRV_INC_DIR=$(dirname $(dirname "${spirvdir}"))
4040
break
4141
fi
4242
done
43-
if [ -d "${SYCL_INC_DIR}" ]; then
44-
echo "Using SYCL_INC_DIR=${SYCL_INC_DIR}"
43+
if [ -d "${SPIRV_INC_DIR}" ]; then
44+
echo "Using SPIRV_INC_DIR=${SPIRV_INC_DIR}"
45+
mkdir "${SRC_DIR}/grrrr"
46+
ln -s "${SPIRV_INC_DIR}" "${SRC_DIR}/grrrr/include"
47+
SPIRV_INC_DIR="${SRC_DIR}/grrrr/include"
4548
else
46-
echo "Fatal error: SYCL_INC_DIR not found"
49+
echo "Fatal error: SPIRV_INC_DIR not found"
4750
exit 1
4851
fi
4952

@@ -95,7 +98,7 @@ if [ ! -d "${INSTALLED_DIR}/imex/lib" ]; then
9598
-DLEVEL_ZERO_DIR=${INSTALLED_DIR}/level-zero \
9699
-DIMEX_ENABLE_SYCL_RUNTIME=1 \
97100
-DIMEX_ENABLE_L0_RUNTIME=1 \
98-
-DCMAKE_CXX_FLAGS="-I${SYCL_INC_DIR}" # grrrr
101+
-DCMAKE_CXX_FLAGS="-I${SPIRV_INC_DIR}" # grrrr
99102
cmake --build build
100103
cmake --install build --prefix=${INSTALLED_DIR}/imex
101104
popd

0 commit comments

Comments
 (0)