- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I have simple CMake project and trying to build it using Intel C++. It is build ok if I use from Intel One API Command Prompt without any issues, but I open this project in visual studio icx-cl is not found. It is explainable because it looks like OneAPI is not integrates compilers into Visual Studio Developer Command Line.
So the question is, does it supported CMake Project in Visual Studio or CMake is supported only from One API Command Prompt?
Thanks,
Daniil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
HI,
I found solution this is covered in
Automate the setvars.bat Script with Microsoft Visual Studio* (intel.com)
I found this article from by googling that, but it would be great to have it inside using Visual Studio
Thanks,
Daniil
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @dkasianov , can you be more specific about the error you saw ? Did you see the error from Visual studio GUI or the command line prompt ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It is just a cmake output.
1> [CMake] -- The C compiler identification is unknown
1> [CMake] -- The CXX compiler identification is unknown
1> [CMake] The CMAKE_C_COMPILER:
1> [CMake]
1> [CMake] icx-cl
1> [CMake]
1> [CMake] is not a full path and was not found in the PATH.
It is looks like Visual Studio does not setup environment and doesn't see compilers.
And FYI, if I choose Developer PowerShell in Tools->Command Line, intel's compilers are also not there.
Thanks,
Daniil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @dkasianov, so you're trying to open a CMake project in Visual studio, do you mind sharing the CMakeLists.txt file or the steps to reproduce the issue ?
In visual studio developer command line, you may need to execute the script, C:\Program Files (x86)\Intel\oneAPI\setvars.bat in order to see Intel compilers.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Yes, to run for command line I need to run *.bat file, but I expected in visual studio it was by default. But is ok, looks like it is a feature.
My example is just simple hello world example. I use presets. I commented out all deps. So you should be able to build it using msvc or intel's (from command line). Try it out.
Thanks,
Daniil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
HI,
I found solution this is covered in
Automate the setvars.bat Script with Microsoft Visual Studio* (intel.com)
I found this article from by googling that, but it would be great to have it inside using Visual Studio
Thanks,
Daniil

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page