Intel® oneAPI DPC++/C++ Compiler
Talk to fellow users of Intel® oneAPI DPC++/C++ Compiler and companion tools like Intel® oneAPI DPC++ Library, Intel® DPC++ Compatibility Tool, and Intel® Distribution for GDB*

fatal error: 'CL/sycl.hpp' file not found

QM
Employee
9,870 Views

Hi Folks,

 

Hope you have a wonderful day at work.

 

I am trying to build DPC++ on my computer which is using Ubuntu. I followed exactly what mentioned in the guild:  https://intel.github.io/llvm-docs/GetStartedGuide.html

 

My DPC++ toolchain is built using configure.py without any further options added (no CUDA, no HIP, no ESIMD CPU Emulation ), I also installed OpenCL RT for CPU and set working environment/libs as followed.

export DPCPP_HOME=~/sycl_workspace
export PATH=$DPCPP_HOME/llvm/build/bin:$PATH
export LD_LIBRARY_PATH=$DPCPP_HOME/llvm/build/lib:$LD_LIBRARY_PATH

 

DPC++ toolchain is tested and passed by $DPCPP_HOME/llvm/buildbot/check.py

 

However when I run a simple DPC++ application provided by the guild, the <CL/sycl.hpp> can not be found. Did I miss some step in the build process? Or do I need to install OpenCL separately? Thank you for your help.

 

Regards,

Quan

0 Kudos
1 Solution
QM
Employee
9,751 Views

Hi Vidya,

 

I have resolved my issue after installing OpenCL sdk and include its header files. Thanks for your time and we can close the topic. Again, thank you.

 

Best regards,

Quan

View solution in original post

0 Kudos
5 Replies
VidyalathaB_Intel
Moderator
9,826 Views

Hi,

 

Thanks for reaching out to us.

 

>>without any further options added (no CUDA, no HIP, no ESIMD CPU Emulation )

Could you please let us know the GPU with which you are working?

 

If you are working on Intel GPU you can use Intel oneAPI DPC++ compiler by downloading oneAPI BaseToolkit (Link to download: https://www.intel.com/content/www/us/en/developer/tools/oneapi/base-toolkit-download.html) instead of using OpenSource DPC++ compiler.

 

If you still wish to continue with the opensource oneAPI DPC++ compiler, we suggest you raise this issue in Github for better assistance as we do not provide support for opensource oneAPI in this forum.

 

Please refer to the below GitHub link to raise this issue:

https://github.com/intel/llvm/issues

 

Regards,

Vidya.

 

0 Kudos
QM
Employee
9,762 Views

Hi Vidya,

 

Thank you for your reply.

 

I am using Intel GPU and decided to install the oneAPI BaseToolkit on Windows because oneAPI is only supporting CPU flow in WSL2 (ubuntu in my case) I think. I have tried to build a sample project using Visual Studio but encountering the same issue "CL/sycl.hpp not found". So I believe I need to install Intel OpenCL driver and including the CL library in build step, is that correct? Please let me know your idea.

 

Best,

Quan

0 Kudos
QM
Employee
9,752 Views

Hi Vidya,

 

I have resolved my issue after installing OpenCL sdk and include its header files. Thanks for your time and we can close the topic. Again, thank you.

 

Best regards,

Quan

0 Kudos
VidyalathaB_Intel
Moderator
9,729 Views

Hi Quan,


>>I have resolved my issue

Glad to know that your issue is resolved and thanks for letting us know.


>>Thanks for your time and we can close the topic

Thanks for the confirmation. As the issue is resolved we are closing this thread. Please post a new question if you need any additional information from Intel as this thread will no longer be monitored.


Have a Great Day!


Regards,

Vidya.


0 Kudos
SushmitaRamdasHoskeri
4,507 Views

Hi Team, 

We were trying to compile the llvm [https://github.com/intel/llvm] from sources in the Ubuntu environment as described in this document: https://intel.github.io/llvm-docs/GetStartedGuide.html

 

We tried 2 configurations:

1.) Ninja based:

python $DPCPP_HOME/llvm/buildbot/configure.py
python $DPCPP_HOME/llvm/buildbot/compile.py

 

2.) Unix based:

python $DPCPP_HOME/llvm/buildbot/configure.py --cmake-gen "Unix Makefiles"

python $DPCPP_HOME/llvm/buildbot/compile.py

 

Ran into issues for both variations in the Ubuntu platform (please find the error logs attached).

 

OS details:

cat /etc/os-release
PRETTY_NAME="Ubuntu 22.04.4 LTS"
NAME="Ubuntu"
VERSION_ID="22.04"
VERSION="22.04.4 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=jammy

uname -r
5.15.0-94-generic

 

Can you please help us with any additional steps we could be missing?

 

0 Kudos
Reply