diff --git a/common/cmake/ispc.cmake b/common/cmake/ispc.cmake index 9b6d3b6dc0..1682b8561f 100644 --- a/common/cmake/ispc.cmake +++ b/common/cmake/ispc.cmake @@ -20,7 +20,9 @@ MACRO (INCLUDE_DIRECTORIES_ISPC) ENDMACRO () execute_process(COMMAND which ispc OUTPUT_VARIABLE ISPC_EXECUTABLE) -execute_process(COMMAND dirname ${ISPC_EXECUTABLE} OUTPUT_VARIABLE ISPC_DIR_TEMP) +IF (EXISTS ${ISPC_EXECUTABLE}) + execute_process(COMMAND dirname ${ISPC_EXECUTABLE} OUTPUT_VARIABLE ISPC_DIR_TEMP) +ENDIF() STRING(REGEX REPLACE "\n" "" ISPC_DIR "${ISPC_DIR_TEMP}") MACRO (ispc_compile targets)