All examples from openapi-cli work, but oneDNN example give errors
The following tools are needed to build this sample but are not locally installed: (dnnl icc)
But tools actually installed.
Was this issue observed when you were trying to run the oneDNN sample or are you referring to the error message in the Description tab in oneapi-cli as you browse through the samples before creating the project directory.
Also, I have errors when trying to build oneDNN example:
pushd ~/oneapi/cpu_dpcpp_gpu_dpcpp/examples; mkdir build; pushd build; cmake ..
-- The C compiler identification is GNU 9.2.1
-- The CXX compiler identification is GNU 9.2.1
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- DNNLROOT: /opt/intel/inteloneapi/oneDNN/2021.1-beta03/cpu_dpcpp_gpu_dpcpp
-- Found OpenMP_C: -fopenmp (found version "4.5")
-- Found OpenMP_CXX: -fopenmp (found version "4.5")
-- Found OpenMP: TRUE (found version "4.5")
-- Looking for CL_VERSION_2_2
-- Looking for CL_VERSION_2_2 - not found
-- Looking for CL_VERSION_2_1
-- Looking for CL_VERSION_2_1 - not found
-- Looking for CL_VERSION_2_0
-- Looking for CL_VERSION_2_0 - not found
-- Looking for CL_VERSION_1_2
-- Looking for CL_VERSION_1_2 - not found
-- Looking for CL_VERSION_1_1
-- Looking for CL_VERSION_1_1 - not found
-- Looking for CL_VERSION_1_0
-- Looking for CL_VERSION_1_0 - not found
-- Found OpenCL: /opt/intel/inteloneapi/compiler/latest/linux/lib/libOpenCL.so
-- Performing Test DPCPP_SUPPORTED
-- Performing Test DPCPP_SUPPORTED - Failed
-- Could NOT find DPCPP (missing: DPCPP_SUPPORTED)
CMake Error at /opt/intel/inteloneapi/oneDNN/2021.1-beta03/cpu_dpcpp_gpu_dpcpp/lib/cmake/dnnl/FindComputeCpp.cmake:114 (message):
Package version - Error obtaining version!
Call Stack (most recent call first):
-- Configuring incomplete, errors occurred!
I also see the problem you discovered. At first I thought it was simply that the DPCPP compiler isn't set in the CMakeLists.txt file, but that doesn't actually seem to fix it. I'll bring it to the attention of the right people and see if we can figure out what's going on.
Thanks for bringing this to our attention!
I see the problem. Consult the ReadMe.MD file for that sample. Apparently, the setvars.sh script has to be run with special args to get that sample work, and the same applies to cmake when building.
You can also follow build sample to build oneDNN sample with DPC++ compiler.
Let us know if you still face any building issue by following the README.md from below link.