I'm trying to build the Postgresql odbc driver in VS2017.
The existing project and solution is a VS2010 project.
When I re-targeted the solution and project, I have problems:
x64 (Release, Debug) builds ok
x86 (Release, Debug) does not build:
error MSB8013: This project doesn't contain the Configuration and Platform combination of Release|Win32.
But I have checked: not any Win32 in project and solution files, only x86 and x64.
In the VS 2017 solution explorer: when I select the x86 I see the project name as "pgodbc (Visual Studio 2010)", when I select x64 I see "pgodbc".
What do I need to check/change?
Related
A prerequiste of my WPF app is Visual C++ Redistributable 2013 to be installed on the machine.
Instead of having the user have to install the executable below I'd like to just package the binaries along with my App.
How can I get at these DLLs?
I shouldn't have to download/install a copy of VS2013 in order to get at them do I?
https://www.microsoft.com/en-us/download/details.aspx?id=40784)
You're looking for the VC++ 2013 runtime redistributable package. Microsoft publishes these C++ runtime redists explicitly for this purpose.
Bundle the one for your target architecture and run it automatically during installation. It's only a few MB.
I ended up installing the VC++ 2013 runtime redistributable on the machine and searched through c:\windows\system32 for the following binaries:
msvcr120.dll
msvcp120.dll
mfc120.dll
mfc120u.dll
mfcm120.dll
mfcm120u.dll
Including those with my app worked!
I was wondering if anyone was able to successfully create Installer Project for a 64-bit WinForms application on VS2015.
When I try to compile the installer project for simple 64-bit WinForms project that only displays a message box, I get the following:
ERROR: File 'WindowsFormsApplication2.exe' of project output 'Primary
output from WindowsFormsApplication2 (Debug x64)' targeting 'AMD64' is
not compatible with the project's target platform 'x86'
And when opening the installer project properties I don't find any option for changing the installer project to x64.
Edit:
I already tried the project properties:
However while the link provided in Cody Gray's comment is for VS2010, it suggests that "Creating 64-bit MSI packages is not available in Visual Studio Express Edition.
"
And I'm using VS2015 community which is free. Could that be the problem?
I have a custom dll written for MATLAB and it works fine on our development machines. However, when I try it on a clean machine with no development tools, I get the message:
>> loadlibrary CMatLab CMatLab.h
??? Error using ==> loadlibrary at 279
Microsoft Visual C++ 2005 or 2008 is required to use this feature.
After some research it seemed clear that a compiler was required to parse the header file at runtime, so I installed the standard Windows SDK, ran mex -setup to select the compiler but I still get the same error message. This is what I did for select the compiler.
>> mex -setup
Please choose your compiler for building external interface (MEX) files:
Would you like mex to locate installed compilers [y]/n? mex -setup
Select a compiler:
[1] Microsoft Visual C++ 2008 SP1 in C:\Program Files (x86)\Microsoft Visual Studio 9.0
[0] None
Compiler: 1
Please verify your choices:
Compiler: Microsoft Visual C++ 2008 SP1
Location: C:\Program Files (x86)\Microsoft Visual Studio 9.0
Are these correct [y]/n? y
***************************************************************************
Warning: MEX-files generated using Microsoft Visual C++ 2008 require
that Microsoft Visual Studio 2008 run-time libraries be
available on the computer they are run on.
If you plan to redistribute your MEX-files to other MATLAB
users, be sure that they have the run-time libraries.
***************************************************************************
Trying to update options file: C:\Users\adriane\AppData\Roaming\MathWorks\MATLAB\R2010b\mexopts.bat
From template: D:\Matlab\bin\win64\mexopts\msvc90opts.bat
Done . . .
I really do not want to install Visual Studio on this machine as it reduces it's utility as a testbed for release builds of our other tools and software. Any ideas anyone? I see that others have the same problem but I did not see a clear solution. The OS is Windows 7 pro 64 bit. The dll was built with VS2008.
Try using the 'MFILENAME' option to loadlibrary to produce a "protofile", which can be used in the future to load the DLL via the #PROTOFILE syntax. Generate the file on your development machine, and bring it along to the test machine.
So, on the dev machine:
loadlibrary('CMatLab', 'CMatLab.h', 'mfilename', 'cmatlab_proto');
Bring along to the test machine the DLL, the file labelled 'thunk', and cmatlab_proto.m. On the test machine, run:
loadlibrary('CMatLab', #cmatlab_proto)
Executable generated by vc8 C project (in windows 7) is running in all windows machine (both win xp and 7) in which vc8 is installed. But its not running in one win xp machine where vc8 is not installed, but vc6 is installed. Error message is System cannot run the executabe.
Is it happening because my vc8 project is not generating vc6 compatible exe ? Please some one help is there any way to solve this problem.
Note : Creating vc6 project and adding all c files is a complex task, which will take so much time for me.
You don't need to have visual studio installed to run an application on another machine. Compile in release mode and install the redistributable package on the target machine.
For VC8 (2005):
VS 2005 x86
VS 2005 x64
for other versions just search for c++ redistributable package
EDIT:
If you compile in debug mode you need the debug versions of the runtime library etc. However these are not redistributable. For a workaround (for use on testing machines, not for clients) see here for more details.
I was working with visual studio 2012 beta and my desktop (win32) program compiled fine in ARM architecture.
After upgrading to visual studio 2012 RC, the compiler would not work and spews out the following error:
"Compiling Desktop applications for the ARM platform is not supported"
I found a forum post on this
http://connect.microsoft.com/VisualStudio/feedback/details/745580/arm-configuration-doesnt-work
Is it correct that Microsoft is really cutting off win32 development on ARM?
And that compiling in VS2012 beta was just a fluke?
You can edit the file:
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V110\Platforms\ARM\Microsoft.Cpp.ARM.Common.props
In the <PropertyGroup> section add the line:
<WindowsSDKDesktopARMSupport>true</WindowsSDKDesktopARMSupport>
before </PropertyGroup>
And that's all, you can build ARM desktop apps with VS2012.
I was able to get around that error and compile a little "hello world" cpp file for ARM by adding the "/D _ARM_WINAPI_PARTITION_DESKTOP_SDK_AVAILABLE" command-line argument to the ARM version of cl at C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin\x86_arm. I found that #define from sn0w's answer on this question in the crtdefs.h file, without having to modify that file. Now, I can't guarantee that anything more complex will actually work, or that Microsoft hasn't instituted some sort of whitelisting or digital signature verification for Windows RT desktop apps, so even though it may compile, it may not be allowed to run when Windows RT is finally available.
Note that before you can run the ARM version of cl.exe from the command line, you must set the environment variables using this batch file: "C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin\x86_arm\vcvarsx86_arm.bat"
Even if you compile the app, you won't be able to run it on Windows 8 RT as unsigned apps will not start.
I just tested this, and unfortunately it is the case.
You receive the following message:
Windows cannot verify the digital signature of this file
I imagine there is probably a work around for this, but it will never be officially supported.
yes of course. i practised with VS2012 RC.
now i'll explain how to avoid "Compiling Desktop applications for the ARM platform is not supported" and build win32 application.
1st way: fix build tools - the goal is to patch (or try to substitute it with beta's one) MSBuild's lib: Microsoft.Build.CPPTasks.Common.v110.dll
2nd way: run the "VS2012 ARM Cross Tools Command Prompt" from Visual Studio Tools start menu, then execute cl [cl params] myfile1.cpp myfile2.cpp myres.res ... /link [linkparams]
for both this cases you also need to commentout an #error directive in crtdefs.h on line 332. (Microsoft Visual Studio 11.0\VC\include)