<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Finally found out solution to in Intel® oneAPI DPC++/C++ Compiler</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143988#M70</link>
    <description>&lt;P&gt;Finally found out solution to this problem. Had to add&amp;nbsp;--gcc-toolchain=/share/apps/compilers/gcc-7.3.0 (path to gcc installation directory) at the end of&amp;nbsp;the CXXFLAGS line in project's&amp;nbsp;vector-add&amp;nbsp;Makefile&lt;/P&gt;</description>
    <pubDate>Wed, 25 Mar 2020 08:46:22 GMT</pubDate>
    <dc:creator>John_Johnson</dc:creator>
    <dc:date>2020-03-25T08:46:22Z</dc:date>
    <item>
      <title>IntelOneAPI throws errors compiling vector-add example</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143984#M66</link>
      <description>&lt;P&gt;Hello I am having difficulties&amp;nbsp;create IntelOneAPI vector-add project.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Operating system and version: Centos 7.4&lt;/P&gt;&lt;P&gt;GNU Compiler Collection (GCC): 7.3.0 (gcc installed in /share/apps/compilers/gcc-7.3.0 directory)&lt;/P&gt;&lt;P&gt;Toolkit:&amp;nbsp;oneAPI DPC++ Compiler from Intel oneAPI 2021 beta04&lt;/P&gt;&lt;P&gt;Steps to reproduce:&lt;/P&gt;&lt;P&gt;1) source setvars.sh&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) oneapi-cli&lt;/P&gt;&lt;P&gt;3) Create-project &amp;gt;&amp;gt; cpp &amp;gt;&amp;gt;&amp;nbsp;&amp;nbsp;oneAPI DPC++ Compiler &amp;gt;&amp;gt;&amp;nbsp;CPU, GPU and FPGA &amp;gt;&amp;gt; Vector Add&lt;/P&gt;&lt;P&gt;4) cd ~/vector_add&lt;/P&gt;&lt;P&gt;5) make all&amp;nbsp;CC=/share/apps/compilers/gcc-7.3.0/bin/gcc CPP=/share/apps/compilers/gcc-7.3.0/bin/g++ CXX=/share/apps/compilers/gcc-7.3.0/bin/g++ LD=/share/apps/compilers/gcc-7.3.0/bin/g++&lt;/P&gt;&lt;P&gt;And&amp;nbsp; I got:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;/share/apps/compilers/gcc-7.3.0/bin/g++ -O2 -g -o vector-add src/vector-add.cpp -lOpenCL -lsycl&lt;BR /&gt;src/vector-add.cpp:7:10: fatal error: CL/sycl.hpp: No such file or directory&lt;BR /&gt;&amp;nbsp;#include &amp;lt;CL/sycl.hpp&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ^~~~~~~~~~~~~&lt;BR /&gt;compilation terminated.&lt;BR /&gt;make: *** [main] Error 1&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As far as I understand it cannot find&amp;nbsp;header in CL directory, which is&amp;nbsp;located in&amp;nbsp;/compiler/2021.1-beta04/linux/lib/oclfpga/host/include/CL, but&amp;nbsp;it should be found, because sycl.hpp exists there and I sourced setvars.sh script&lt;/P&gt;&lt;P&gt;UPDATE: I found out that during make all command I did overwrite CXX value from dpcpp to g++ and it was wrong. That was the reason why it could not find sycl.hpp header. But when I change command to make all (without additional parameters) I got errors about wrong gcc version (see attached file below). Centos 7.4 by default uses 4.8.5, but I compiled from source gcc 7.3.0 version. I suppose if somehow point to use gcc 7.3.0 I could go futher&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 19 Mar 2020 08:48:55 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143984#M66</guid>
      <dc:creator>John_Johnson</dc:creator>
      <dc:date>2020-03-19T08:48:55Z</dc:date>
    </item>
    <item>
      <title>Hi John,</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143985#M67</link>
      <description>&lt;P&gt;Hi John,&lt;/P&gt;&lt;P&gt;CentOS version 7.4 is not supported by oneAPI 2021.1-beta04&amp;nbsp;as of now. You can check the oneAPI system requirements here: &lt;A href="https://software.intel.com/en-us/articles/intel-oneapi-dpcpp-system-requirements-beta"&gt;https://software.intel.com/en-us/articles/intel-oneapi-dpcpp-system-requirements-beta&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;--Rahul&lt;/P&gt;</description>
      <pubDate>Fri, 20 Mar 2020 12:01:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143985#M67</guid>
      <dc:creator>RahulV_intel</dc:creator>
      <dc:date>2020-03-20T12:01:00Z</dc:date>
    </item>
    <item>
      <title>Okay. So maybe then there is</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143986#M68</link>
      <description>&lt;P&gt;Okay. So maybe then there is any known way how to let inteloneapi use gcc version compiled from source? Because most of the cases it uses my old compiler even if environment variables is properly set. Install compiler using other ways is not preferable, because I have to install it to specific directory. This error comes I guess just because of earlier mentioned&amp;nbsp;issue:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;/share/apps/devel/inteloneapi/inteloneapi/compiler/2021.1-beta04/linux/lib/clang/10.0.0/include/CL/sycl/intel/functional.hpp:47:17: error: too few template arguments for class template 'greater'&lt;BR /&gt;&amp;nbsp; &amp;nbsp; return std::greater&amp;lt;&amp;gt;()(std::forward&amp;lt;const T&amp;gt;(lhs), std::forward&amp;lt;const U&amp;gt;(rhs))&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ^&lt;BR /&gt;/usr/lib/gcc/x86_64-redhat-linux/4.8.5/../../../../include/c++/4.8.5/bits/stl_function.h:222:12: note: template is declared here&lt;BR /&gt;&amp;nbsp; &amp;nbsp; struct greater : public binary_function&amp;lt;_Tp, _Tp, bool&amp;gt;&lt;/P&gt;</description>
      <pubDate>Mon, 23 Mar 2020 08:29:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143986#M68</guid>
      <dc:creator>John_Johnson</dc:creator>
      <dc:date>2020-03-23T08:29:00Z</dc:date>
    </item>
    <item>
      <title>Hi John,</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143987#M69</link>
      <description>&lt;P&gt;Hi John,&lt;/P&gt;&lt;P&gt;Export gcc-7.3.0 path&amp;nbsp;(compiled from source) to your&amp;nbsp;bashrc file.&lt;/P&gt;&lt;P&gt;Steps to be followed:&lt;/P&gt;
&lt;PRE class="brush:bash; class-name:dark;"&gt;vim ~/.bashrc

Add these lines at the end of your file

export PATH=/share/apps/compilers/gcc-7.3.0/bin:$PATH

export LD_LIBRARY_PATH=/share/apps/compilers/gcc-7.3.0/lib64:$LD_LIBRARY_PATH&lt;/PRE&gt;

&lt;PRE class="brush:bash; class-name:dark;"&gt;source ~/.bashrc&lt;/PRE&gt;

&lt;P&gt;DPC++ codes run perfectly fine with gcc-7.3.0. Tried this on Ubuntu-18.04. Compiled gcc-7.3.0 from source and placed&amp;nbsp;the paths in&amp;nbsp;the bash file. Notice the gcc version change, upon running&amp;nbsp; &lt;STRONG&gt;gcc --version&lt;/STRONG&gt; command.&amp;nbsp;However, I cannot guarantee you that it would work on CentOS&amp;nbsp;7.4,&amp;nbsp;since this OS version is currently not supported by oneAPI-beta04 version.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;--Rahul&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2020 19:11:15 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143987#M69</guid>
      <dc:creator>RahulV_intel</dc:creator>
      <dc:date>2020-03-24T19:11:15Z</dc:date>
    </item>
    <item>
      <title>Finally found out solution to</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143988#M70</link>
      <description>&lt;P&gt;Finally found out solution to this problem. Had to add&amp;nbsp;--gcc-toolchain=/share/apps/compilers/gcc-7.3.0 (path to gcc installation directory) at the end of&amp;nbsp;the CXXFLAGS line in project's&amp;nbsp;vector-add&amp;nbsp;Makefile&lt;/P&gt;</description>
      <pubDate>Wed, 25 Mar 2020 08:46:22 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143988#M70</guid>
      <dc:creator>John_Johnson</dc:creator>
      <dc:date>2020-03-25T08:46:22Z</dc:date>
    </item>
    <item>
      <title>Hi,</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143989#M71</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Glad to hear that your issue got resolved. We are closing this thread. Feel free to reach out to us, in case of further queries.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;--Rahul&lt;/P&gt;</description>
      <pubDate>Fri, 27 Mar 2020 05:52:26 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/IntelOneAPI-throws-errors-compiling-vector-add-example/m-p/1143989#M71</guid>
      <dc:creator>RahulV_intel</dc:creator>
      <dc:date>2020-03-27T05:52:26Z</dc:date>
    </item>
  </channel>
</rss>

