Generate visual studio solution on mac with cmake - macos

Using the CMake GUI, for the same CMakeList, I am able to generate VS solution files on Windows and XCode solution files on Mac. However I am unable to generate VS solution on Mac, as I don't use any VS options under Specify the generator for this project.
I have VS 2017 Community for Mac installed on the Macbook. Is there anything I am missing?

Visual Studio for Mac is very different from Visual Studio.
The former is based on Xamarin Studio, a product of Xamarin Inc., which was acquired by Microsoft in early 2016. Microsoft then basically rebranded Xamarin Studio as Visual Studio for Mac. Note that Xamarin Studio was mainly an IDE for developing mobile apps. Visual Studio for Mac currently has no support for C++.
Because of this, CMake currently does not support Visual Studio for Mac. The Visual Studio generators that ship with CMake only work with the Windows versions of Visual Studio.
And before someone asks: They also don't work with Visual Studio Code, which is yet another product that has little in common with Visual Studio except the name. Unlike Visual Studio for Mac however, Visual Studio Code has extensive support for C++ development with CMake through plugins and might be a viable alternative if you're looking for a Visual Studio-like development experience for C++ on Mac.
In that case, you open the workspace directly with VS Code and let its CMake plugins handle the configuration of CMake. You will not use the Visual Studio generators of CMake for VS Code, as VS Code is unable to work with the generated solution files.

Related

How to open a new MonoGame Desktop Project in Visual Studio 2019 Community Edition?

I heard that MonoGame is a replacement for XNA but i do not know how to open the desktop project.
Specifically, what workload should I install to be able to develop MonoGame projects on Windows?
MonoGame v3.7.1 doesn't officially support Visual Studio 2019 but that's only because it doesn't install the Visual Studio Project Templates in the right place.
There are number of workarounds to this issue including this one by uranusexplorer:
I could not find templates for VS 2017 anywhere, so I had to install VS 2017 to get them. Leaving them here until there is support for Visual Studio 2019 in the official MonoGame installer.
Download MonoGame Visual Studio Templates
Unzip to Documents\Visual Studio 2019\Templates\ProjectTemplates\Visual C#
Funnily enough, I actually created a MonoGame Hello World project on github recently for this exact reason. If you just want to get started you can download that project and open it in Visual Studio 2019.
Alternatively you can create a MonoGame .NET Core project which will also work in Visual Studio 2019.
MonoGame is not installed with Visual Studio (neither was XNA, btw). You need to install it separately. The process is well described in their documentation: http://www.monogame.net/documentation/?page=Setting_Up_MonoGame

Debugging information does not match, when using v60 platform toolset inside Visual Studio 2013

I am using Visual Studio 2013, but I'm in need to develop an old project using the Visual C++ 6.0 compiler.
For this purpose, I have been using Daffodil with no problem on Windows 8.1 for a while.
(You can read more how to use the VC++ 6 compiler in newer Visual Studio versions in this StackOverflow question: Is it possible to use the VC++ 6 compiler in Visual Studio 2012?)
Now I got a new Windows 10 machine, where I reinstalled Visual Studio 6, 2010, 2013 and Daffodil.
Using v60 build tools (Visual C++ 6.0 compiler), project gets compiled fine.
However, when I try to debug, VS says that "debugging information does not match", and I am unable to set breakpoints etc., but:
PDB file is there, same folder and name of debug executable;
Application built in Debug mode, with debug information enabled;
Debugger works fine when using Visual Studio 2010 or 2013 build tools;
Debugger works fine if opening the project inside Visual C++ 6 IDE.
I tried reinstalling all Visual Studio versions as well as Daffodil, but didn't solve.
Any clue what could the problem be?
Finally I actually found a working solution!
for VS 2013:
Enable "Native Edit and Continue"
under Tools->Options->Debugging->Edit and Continue
for VS 2015:
Enable "Use Native Compatibility Mode"
under Tools->Options->Debugging->General

Install WinCE 5.0 Platform Builder SDK - build code with Visual Studio 2012 or higher

I have a Windows CE 5.0-based Platform Builder image. It is intended to be installed on Visual Studio 2005. My team would like to upgrade our build tools to utilize Visual Studio 2012, but Visual Studio 2012 does not support this platform image.
To be clear; I am not asking whether or not Visual Studio 2012 (or higher) supports Platform Builder SDKs targeting Windows CE 5.0. That question has already been answered (more or less), and the answer is clearly "No."
Instead, what I'd like to do is install the Platform Builder SDK, and manually modify the Visual Studio 2012 environment to allow compilation of my Windows CE code. Features like remote debugging and deployment are acceptable losses to my team; we have our own pathway for deployment and debugging on our embedded device. What I'm really hoping to gain is simply the ability to build WinCE 5.0 code in VS2012, which was intended for VS2005. I am attempting to reduce the number of Visual Studio installations, and get access to the superior intellisense faculties of newer versions of Visual Studio.
Does anyone know if this is possible? How would I go about doing that?
There does not appear to be a way to do this, in such a fashion as to no longer require Visual Studio 2005.
You can, however, use registry hacks to force Visual Studio 2012 to build a WinCE 5.0 project by utilizing the compiler binaries from Visual Studio 2005, during compilation. This would allow you to develop code in VS2012, but would also require that VS2005 be installed for a successful build.
Here is an article explaining the steps to set this up.
VS2012 doesn't have any of the Windows CE compilers. The last one that shipped with compilers compatible with CE 5.0 was VS 2008, so that's the "latest" version you'll be able to use to build. (VS2012 is capable of building for Windows CE, but only for WEC 2013, and only after installing a WEC 2013 SDK, which includes the requisite compiler pieces).
In short, there's no way you can get VS2012 by itself to compile a CE 7.0 or earlier app.
There is a plug-in for VS 2013 that will allow you to use that IDE for managed code (I've never used it, so I can't say how well it works), but it still requires VS 2008 to be installed to get the compilers.

Mono Develop and Visual Studio Compatibility

Will code developed with Mono (Develop) be compatible with Visual Studio (2010 for now)? Meaning, is it ok to have some members of a team using mono develop (linux) and some using Visual Studio (windows)? Or should I expect problems?
For this project, it will be using C++ on Visual Studio 2010 (most members). If its compatible, can I expect the same from Visual Studio 2012? Except those specified on the Mono website
If you have been a long time Visual C++ developer, you will know using Windows's stuffs (such as MFC) locks you up on Windows.
MonoDevelop's C++ support (for example GTK+) does not aim to clone Visual C++ or be compatible with it,
http://monodevelop.com/documentation/creating_c_and_cpp_projects
So I think the answer is No.

Possible to use Qt Open Source integrated in Visual Studio?

I'm currently having issues installing Qt (Open Source Edition) such that I can use it in integrated into Visual Studio 2010. I realize that the 2008 edition will have deployment issues, and so I installed it from the source, only to be missing qtmaind.lib.
Anyways, I was looking around for a solution to this, and I came upon this: http://doc.qt.io/qt-4.8/install-win.html, which states:
Open Source Versions of Qt is not officially supported for use with
any version of Visual Studio. Integration with Visual Studio is
available as part of the Qt Commercial Edition.
Anyways, I thought maybe this was the reason I was having problems, and so I wanted to ask the following question:
Is it possible to integrate Open Source Qt into Visual Studio?
Absolutely. I use Qt 4.7 integrated with Visual Studio 2005.
I configured Qt this way:
configure -debug-and-release -opensource -shared -ltcg
-no-accessibility -no-qt3support
Once Qt was built (via nmake), I also installed the Qt Visual Studio Add-in.

Resources