intellij icon indicating copy to clipboard operation
intellij copied to clipboard

Windows sync errors

Open zpervan opened this issue 2 years ago • 1 comments

Description of the bug:

When using the Bazel sync option in CLion on Windows with msbuild, I get the following error message:

Warning:Unable to check compiler version for "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.33.31629\bin\HostX64\x64\cl.exe".
stderr: "Microsoft (R) C/C++ Optimizing Compiler Version 19.33.31629 for x64
Copyright (C) Microsoft Corporation.  All rights reserved.

cl : Command line warning D9002 : ignoring unknown option '--version'
cl : Command line error D8003 : missing source filename
"
stdout: ""
Check if running the compiler with --version works on the cmdline.

Also, intelisense does not work properly because of that (i.e. cannot autocomplete or ctrl+left-click search within my project files), and doing the same on Ubuntu with gcc or clang syncs the project without any problems and the intelisense works perfectly.

I am aware that this issue has been raised before in this bug report https://github.com/bazelbuild/intellij/issues/467. Maybe I don't see it, but is there any workaround or any plans to fix this issue? It would be really nice to have one plugin to rule them all 😄

What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

Sync the project within the CLion IDE

Which Intellij IDE are you using? Please provide the specific version.

CLion 2022.3.1

What programming languages and tools are you using? Please provide specific versions.

MsBuild 14.33.31629, C++20 and Bazel 5.4.0

What Bazel plugin version are you using?

2022.11.07.0.1-api-version-223

Have you found anything relevant by searching the web?

https://github.com/bazelbuild/intellij/issues/467

Any other information, logs, or outputs that you want to share?

No response

zpervan avatar Jan 09 '23 08:01 zpervan

Oh, it seems like we just not support MSVC at the moment. There's a comment saying this exactly in the line throwing this warning

https://github.com/bazelbuild/intellij/blob/f894c76e3f492cf9322a9142b43fc0cf2526b39f/cpp/src/com/google/idea/blaze/cpp/CompilerVersionCheckerImpl.java#L40-L41

tpasternak avatar Feb 22 '23 09:02 tpasternak

Duplicate of #6451

ujohnny avatar Jul 24 '24 10:07 ujohnny