How to use clang compiler in Dymola 2021 - Windows - dymola

I installed MS Build Tools 2019 (along with clang) and verified the compiler (Visual Studio 2019) but couldn't figure out how to set the compiler to use clang in Dymola. The documentation only mentions support for clang in the linux version but doesn't seem to mention anything about Windows support.
I was wondering if anyone has figured out how to set the compiler to clang through MS Build.

Related

Building a project using CMake and Clang from the LLVM SDK on Windows

On Windows when invoking cmake with -G Visual Studio 17 2022 -T ClangCL the Visual Studio project will use the version of the Clang toolchain that comes packaged with Visual Studio.
How can cmake instead be configured to generate a Visual Studio project that will specifically use the version of the Clang toolchain that can be installed via the LLVM SDK?

How to target Windows XP with MSVC2017 and CMake?

I wanted to accomplish what other 2 threads are doing, but with latest MSVC to support targetting Windows XP and CMake support.
I keep following the advice given in How can I generate a Visual Studio 2012 project targeting Windows XP with CMake? and How does CMake specify "Platform Toolset" for a Visual Studio 2015 project? but CMake keeps telling me that it configured the source code for Windows 10.foo.bar SDK version which is not going to work. I tried hamfisting v141_xp into the project as CMAKE_GENERATOR_TOOLSET and -T parameter for cmake but it all ultimately fails. How can I accomplish this? And if possible, where can I specify this in CMakeSettings.json?
Bonus points for amd64 support, since the target system I want to make binaries for is Windows XP x64.
For what it's worth, I have tried to open a .sln file and I confirm that v141_xp is available as a platform toolset.
I figured it out on my own. From x64 tools console:
Prepare .sln files
cmake path/to/CMakeLists.txt -G "Visual Studio 15 2017 Win64" -A x64 -T v141_xp
Build from .sln:
msbuild path/to/.sln /p:XPDeprecationWarning=false /p:Platform=x64

Configuring an Intel compiler from MSVC 2019 built-in CMake

Recent Visual Studio versions support CMake natively, with documentation for compilation with MSVC, Clang, and for linux. However, there is no official documentation for configuring the Intel compiler.
What is the best way to configure the Intel compiler using Visual Studio's native CMake? Can I create a custom environment?
I found one forum post that attempts to solve the problem, but it relies on the Windows CLI to launch Visual Studio. I've also submitted a feature request for native CMake support for the Intel C/C++ compiler within Visual Studio.

CMake cannot identify C compiler from installed Visual Studio 2015

I have been trying to install CMake for vtk, but I'm getting this error message:
The C compiler identification is unknown,The CXX compiler identification is unknown.
I'm using CMake 3.2.1, vtk 6.2.0 and Visual Studio 2015.
Screenshot
Please take a look at this answer if it helps:
CMake does not find Visual C++ compiler
Basically VS2015 doesn't install Cx compilers by default. Creating a C++ project in VS2015 will force VS to download necessary compilers.
here is what worked for me:
Relaunch Visual Studio 2015 install
Choose "modify"
Check that both this components are installed: "Common tools for visual c++ 2015" AND "Tools and Windows XX SDK"
If not, check and choose "update"
Once I installed this components, CMake was able to detect the C/C++ compiler.
Open developer command prompt from visual studio tools.
reach to the directory where your cmake exe resides.
Run it.
Hopefully, now it will find the c and cxx compiler and run as desired.

Eclipse C/C++ Compiler Visual Studio C++

I have just installed cdt plugin for eclipse and tried to make a new project. On the tool chain its showing Microsoft Visual C++ not MinGW.
On writing #include its showing Unresolved inclusion:
What should I do now? How can I have MinGW now? Please help me out.