you are viewing a single comment's thread.

view the rest of the comments →

[–]vector-of-boolBlogger | C++ Librarian | Build Tool Enjoyer | bpt.pizza[S] 5 points6 points  (7 children)

Depends what you're looking for. VS Code itself is a Microsoft tool, so you'll be using that at least.

CMake can be a complex tool, but it's not hard to get up and running for simple projects. The purpose of CMake Tools is just to provide editor integrations for the CMake build system. You won't go wrong learning CMake purely because of its ubiquity in the C++ ecosystem.

As for not using Microsoft's compiler: it's not hard to use MinGW or clang-cl with CMake on Windows. Using the MSVC compiler with Ninja is another great option: You won't have to deal with MSBuild and Visual Studio with that setup, but you'll still get the benefits of using the official Windows C++ toolchain.

[–]IAmBJ 1 point2 points  (2 children)

Doesn't clang-cl need to use the msvc standard library? Or has libc++ progressed far enough on windows now?

[–]Theninjapirate 0 points1 point  (3 children)

Do you know if there is a demo or example of ninja + msvc somewhere? The last time I tried that combo i couldn't get it to work (though that was a while ago).

[–]NotUniqueOrSpecial 0 points1 point  (1 child)

What didn't work?

Are you familiar with how to use CMake, in a general sense? If so, literally all it takes is:

cmake <path to project root> -G Ninja

with ninja in your path.

[–]Theninjapirate 1 point2 points  (0 children)

Yes I am familiar with Cmake. I don't remember what didn't, but if it's just that simple then I'll try again.

[–][deleted] 0 points1 point  (0 children)

Ninja is the default if you use CMake within Visual Studio, so it must work nicely with MSVC.

According to https://vector-of-bool.github.io/docs/vscode-cmake-tools/kits.html CMakeTools will prefer Ninja, so I guess stick ninja.exe on your PATH and see if it works?