64bit deployment - c++

I would like to start making my application's 64bit, however, I am not sure on the changes I should make on my sln and vsproj files. What changes should I make to my sln and vsproj to make them 64bit?
On the same note, are there changes to the default sln or project file that are good for game development? I am using Visual Studio 2010.

From the VS menu select Build|Configuration Manager.
On the Configuration Manager dialog, open the Platform drop down and select <New...>.
On the New Project Platform dialog select x64 as your platform and click Ok.

To add to what was said before, make sure you understand why you need 64-bit support. In most cases you won't need access to larger memory allocations. Also, be aware that there will be x86/x64 P/Invoke compatibility problems (if you plan on using third-party unmanaged assemblies - in case you are working with managed C++).
For more information, read what Scott Hanselman has to say about this. Also, just as a sidenote, I would recommend reading this blog post that explains some of the migration ideas.

you need to add x64 solution platform:
Build -> Configuration Manager -> Active Solution Platform -> New -> New platform = x64
if you don't see "x64" make sure you installed it in Visual Studio installer
then just select "x64" as active solution platform and build

Related

"Manage Client-Side Libraries" menu not appearing

I'm trying to use the new Library Manager (LibMan) feature in Visual Studio 2017 (I'm using Version 15.7.1) but it is not appearing on either the project context menu or the Project menu.
I have tried various web projects but I can't see it for any of them. The only project type I haven't tried is ASP.NET Core 2.1 (I don't have the preview installed) but I can't find any docs that say it only works with ASP.NET Core 2.1
Here is a screenshot to prove it's not there:
had the same issue. I found the answer two it on another site, but for the life of me cannot find it for reference right now. The easiest thing to do is to build it yourself and install it. Works perfectly fine, I did it and now have the Manage Client Side libraries showing up.
Clone / download the Library Manager from GitHub. (https://github.com/aspnet/LibraryManager/)
Build it in Visual Studio 2017
Run the .Vsix installer
Begin to use the Manage Client Side Libraries from the context menu or project menu.
Hope this helps.
For me, in VS 2022 the context menu option appears but the dialog doesn't show. I found out that instead of right-clicking on project item i have to right-click on wwwroot item and then the dialog is shown
Even though Visual Studio Community 15.7.5 references the "Library Manager" it looks like it is still in Preview and to be released with VS 15.8.
If you would like to use the Library Manager now it is fairly easy but there are a few work arounds right now to get it to install, probably a reason it is still in Preview.
Clone or Download the source code
Note: This requires the Visual Studio extension development Workload to be installed (Tools -> Get Tools and Features under "Other Toolsets").
According to this issue on GitHub it will not install, before compiling the Extension open the project file for the LibraryManager.Vsix project
[LibraryManagerDir]\src\LibraryManager.Vsix\Microsoft.Web.LibraryManager.Vsix.csproj
and update (line #30)
<IsProductComponent>false</IsProductComponent>
After 15.8 comes out this needs to be reset back to true to be able to install it.
Open the LibraryManager.sln and make sure to change the Configuration to Release and Build the Solution.
This will create a .vsix install file:
[LibraryManagerDir]\src\LibraryManager.Vsix\bin\Release\Microsoft.Web.LibraryManager.vsix
Open Microsoft.Web.LibraryManager.vsix to launch the Visual Studio Installer.
Then you will have the Add->Client Side Library in your Context Menu.

Deploy app, C++, Visual Studio 2015 community version

I'm trying to deploy a C++ app for use on multiple systems. I've already gotten everything to work in the release configuration. Now since i don't have any experience with deploys at all, i'd like to ask - what's the simplest way to deploy it from Visual Studio 2015 community, so that it could be installed as a portable app on flash drives and similar?
I've checked out google, but with no luck so far all of the solutions i checked require some sort of additional software that is only available for the pro version of VS.
The simplest possible answer would be: compile without dependency on VC++ runtime libraries (select this in the project properties -> C++ -> code generation) and choose the oldest Windows version it should run on (in project properties -> general). Maybe even select Windows XP compatibility.
This should be enough, unless your program depends on other libraries or optional Windows features that may be not present.
And test a lot :)
-- dd
You should be able to go to your project's Properties (right click on your project) then under C/C++ and Code Generation switch your Runtime Library from Multi-threaded DLL (/MD) to Multi-threaded (/MT).
This way your dependencies to the runtime library will be statically linked and not require you to have any of them installed at the target system.

How to move old VC6 project to VS2010 using Daffodil

I've been interested in this project lately.
I have an old legacy project made in VC6, which I hear is a great IDE but doesn't run smoothly on my machine. I also don't know how to work with it. A full blown move to a 2010/12 project is a big time spent so I wonder:
Can someone share some basic information on how to use this tool? I've been searching a lot and couldn't find anything more comprehensive than the site.
Which specific old VC6 tools do I need to make sure to have working for Daffodil? (compiler, linker, etc) where are they located on the installed machine?
To build your project in VS 2010:
Make sure the VC 6 build tools are installed and working.
Make sure VS 2010 and Daffodil are installed and working.
Open your VS 6 workspace in VS 2010.
A. In Explorer, right-click on your VS 6 workspace (*.dsw) file.
B. Choose Open With -> Microsoft Visual Studio 2010.
C. Perform the migration when prompted.
Change the Platform Toolset to v60.
A. Right click on the project(s) and select Properties.
B. On the General page, set Platform Toolset to v60.
Build.
A quick read tells me that the concept of "Daffodil" is to use the VC6 compiler with the VS2010 IDE. Therefore, you wouldn't run VS6 on your machine. You just need the VC6 compiler and linker.
Start by letting Vs2012 migrate the project and see what doesn't work properly. The newer compilers are much better -once you've gone through the pain of the conversion.

"There's no Qt version assigned to this project for platform Win32" - visual studio plugin for Qt

I have a Qt project I am working on in Visual Studio 2010, with the Qt Visual Studio Add-in (for Qt 4.8). The project is running fine on my work machine, and I am trying to run it on my home machine. When I try to build, I get the following error:
There's no Qt version assigned to this project for platform Win32.
Please use the 'change Qt version' feature and choose a valid Qt
version for this platform.
However, it's set up to use a valid Qt version (another project I'm working on at home uses this plugin as well). Why is this occurring? When I got to Qt -> Qt Options, I see a valid version (4.8.0). Thanks
Did you select a proper Qt version in the Qt settings of your project?
More detailed:
If you right-click on the project there should be a "Qt Project Settings" option (or similar - I use the german version) near the end of the context menu. In there you can set the Qt version that this specific project uses. Is this one possibly not set correctly?
Solution:
Right click your project;
Qt Project Settings;
Under the Properties tab, you will find the option Version;
change it to a proper value;
Now, go ahead with your project.
Hope to help
Had the same problem with a x64 Visual Studio 2019 solution on Windows using Qt 5.15.0. Based on the answer from #Fabian and the excellent comment from #sitting-duck:
Install the Qt VS Tools extension
Select Extensions > Qt VS Tools > Qt Options
On the Qt Versions tab click Add
Set "Version Name" to something like "Qt-5.15.0"
Set "Path" to "[QT-PATH]\5.15.0\msvc2019_64"
Open Project Properties > Qt Project Settings > General > Qt Installation
Ensure this is set to "Qt-5.15.0" and close Project Properties
Right-click the solution (in the Solution Explorer tab) and select Change Solution's Qt Version
Ensure Qt-5.15.0 is selected
You should be good to go.
Open vcxproj file in a notepad, look for QtVersion...something=...
Ensure that the version value is really 4.8.0 (or whatever is your actual QT SDK version).
I found this issue too. and I found the solution .
you must keep the Qt version name is exactly same with the project create using.
which you think u can change freely,but actually not.
If you want to move Qt project between different computers, it's a good idea to use the qt project file, and not the MSVC (.vcxproj) one. So when you move from your work machine home, create a .pro file (in the Qt menu, you find the neccessary options to do that), and then load the .pro file at home, again using the Qt menu inside MSVC.
Another thing this could be is the platform being used is not the platform you think it is. In MSVC right-click on project, select properties, and then press configuration manager. Then check that all configurations and platforms are as you expect them to be.
I got the same problem during migration from Qt5.9 to Qt5.10.
We have a solution (Visual Studio) which consists of many projects. Some of them have QtVersion = "Qt5.9" and others have QtVersion = "Qt5.7" (yes, it were inaccurate project settings)
So, after I change all Qt project's settings from 5.9 to 5.10 automatically and remove Qt5.7 from versions list - I got the same error. This error was fixed trivially - I just add back Qt5.7 to the versions list (temporary until ALL projects' Qt version was not changed to 5.10).
In my case, I ported a Visual Studio project, with all its files (including .sln, .vcxproj, etc) to another computer using git. When I set everything up on the new computer, I accidentally selected a different folder for the Qt executables in VS (I selected C:\Qt\5.9.9\winrt_x86_msvc2017 instead of C:\Qt\5.9.9\msvc2017_64). When I double-checked which I had selected on the original computer, and then selected the same on the new computer, all was good.
To select a Qt folder: Extensions -> Qt VS Tools -> Qt Options -> Add -> Path (Version Name is auto-filled once you select the path).
This all describes the process using Visual Studio 2019, with the Qt plugin found here.
You could follow AlainD's instruction.
It work for me.
Just Right-click on Solution -> Change Solution's Qt Version
It will make change for its all projects.

VS2008: No option to convert Win32 C++ project to x64?

I am running VS Team System 2008 on WinXP. I make a new Win32 C++ project (Empty project). I go to Build Configuration to add a configuration for x64.
The only options I have are:
- Pocket PC 2003 (ARMV4)
- Smartphone 2003 (ARMV4)
I have no option for x64 (or Itanium). However, if I make a C# project within the same solution, I can create and select an x64 option for that project with no issues. But even then, when the x64 build configuration has been created, I still cannot select it for the C++ project - only for the C# project.
I have done this before on another system - creating an x64 config for a Win32 C++ project. But I can't do it now. Any ideas why? Something small/obvious no doubt, since google has offered no help. Thanks!
Maybe you didn't install the native x64 compiler.
Try to run setup again, and look if you selected the native x64 C++ compiler.