error LNK1104: cannot open file 'mfc100d.lib' - visual-studio

I compiled program that made for VS 2010 in VS 2013, I got this error.
I did change the tool to VS 2010 (V100) and add dependencies (both mfc100d.lib and mfc120d.lib).
I also set project defaults > Use of MFC > Use MFC in Shared DLL.
I'm trying to looking for mfc100d.lib but can't find that on my computer, I just have mfc100d.dll.
Do anyone has reference to related website, so I can download mfc100d.lib?
this is my error:
error LNK1104: cannot open file 'mfc100d.lib'
I use OpenCV 3.0 and VS Ultimate 2013.
Please help me.
Thank you.

Related

rt_matrx.c(29): fatal error C1083: Unable to open include file: 'stdlib.h' : No such file or directory

I have an issue during the compilation of a Simulink model, the model worked since I had a change in my Windows professional account, now I can't compile it anymore, and the following error is appearing in the debug window of Simulink:
rt_matrx.c(29): fatal error C1083: Unable to open include file: 'stdlib.h' : No such file or directory
I saw a similar issue on the Mathworks forum, which was resolved by reinstalling MATLAB, I tried to do the same and it didn't work for me.
I checked if the environment variables on my new windows account are the same from the previous one, they didn't change.
I don't have admin rights so I asked to my IT service if I was able to access all the paths I use with MATLAB, and apparently it's not the problem here.
My theory is that there is maybe an issue with how MATLAB and Visual Studio are linked together, that or maybe it comes from how the path is defined.
I'm a little lost for this issue, I would be glad if someone could help me or at least guide me on the origin of my problem, thanks you in advance.
MATLAB version: 2020A
Compiler version: Visual Studio 2019
Hello everyone, for the people in need i found the solution of my problem, it came from two points :
The environment of Visual studio 2019 :
I use Visual Studio 2019 community to compile my projects on MATLAB and SIMULINK, and if you have MSVC and the SDK kits installed at the same time i can create conflicts within your compilation (You can find this specifics add-ons on Visual studio installer > Visual studio 2019 Community > modify > C++ Desktop development).
Be sure when you install VS2019 to only get the strict minimum of add-ons you need to do your project.
My access rights to the MATLAB and Visual studio folders :
Check if you have a total control of your project (Right click on the folder concerned > Properties > Security, choose your user profile and check your rights).
For my part it worked when i changed my access rights of C:\Program Files\MATLAB\R2020a (be sure you have time for that because it took one hour for me, maybe you can only change the right to "toolbox" and it could works but i'm not sure about that) and C:\ProgramData\Speedgoat\speedgoatlib\R2020a
If the last solution doesnt work check the access rights of the other folders that are concerned by Matlab and visual studio.

OpenCV & Microsoft Visual Studio 2012 ( for x64 )

I have been trying to run OpenCV through MVS 2012 with no succeess.
Here is an error i get:
1>LINK : fatal error LNK1104: cannot open file 'opencv_core242d.lib' 1> 1>Build FAILED.
Could someone provide me a tutorial? or how can i solve this problem?
I've written a blog post on Using OpenCV 2.4.2 with Visual Studio 2012 on Windows 7 (64-bit). With the step by step instructions provided, I think it should be pretty easy for you to get it done. Feel free to comment if you have any doubts.
Since OpenCV 2.4 does not work well with Visual Studio 2012. I think that's why you always got problems. Actually, it used me a lot of time to make all things work. So I wrote a very simple tutorial about how to use OpenCV 2.43 in Visual Studio 2012. Please check it. Good luck. If you still have questions, ask me again.
http://answers.opencv.org/question/6495/visual-studio-2012-and-rtlfreeheap-error/#6603
Some basic steps...
use cmake to create the .sln or the solution file ...make sure you choose right the compiler in cmake properly...use the address of the cmake file (CMakelist.txt) in the folder containing opencv files..
click on the .sln file (this will be found in the target folder whose path you have set in cmake to contain the build..) and open with VS2012
VS2012 will build your libraries and dlls...add the path of the dlls to the system variable PATH...put the path of the libs in the IDE..and the include files also..
restart VS2012 to make the changes in PATH variable to reflect
You have 2 options - one is to use the precompiled libraries and link them into your VS2012 projects.
The other is to use CMake to make the the right .SLN and .PRJX files so you can simply open them .SLN in VS2012 and compile everything for yourself.
Both have been discussed here, however, to add to the first option, you need to manually edit the top level CMAKElist.txt file with the following lines
if( MSVC ) # VS2012 doesn't support correctly the tuples yet
add_definitions( /D _VARIADIC_MAX=10 )
endif()
Before generating your solution files. This ensures that you don't have problems with the VARIADIC length issue with :tuple - which Visual studio 2012 has issues with.
there may be 2 option to solve your error:
1) You may use opencv 2.4.2 that may have some problems to connect with visual studio 2012
so use newer version of opencv
2) You need to restart your visual studio 2012 so that it can reconfigure its Setting as per requirements.

Issue converting project visual studio 2008 to 2010

so I have downloaded a template from the tutorial website http://devmaster.net/posts/introduction-to-c-with-game-development-part-2-project-template
however I have a problem because the template was apparently made in Visual Studio 2008, and I have Visual Studio 2010. When I convert the project I get the error "Unable to start program'C:\c++\Debug\Template.exe' The system cannot find the file specified."
I looked in the original file before conversion and the \Debug\Template.exe file does exist, however after converting the file it gets deleted. I had a few warnings on my conversion and I found this:
"MSB8012: $(TargetPath) ('C:\c++\Debug\Template.exe') does not match the Linker's OutputFile property value 'Template_debug.exe' ('C:\c++\Template_debug.exe') in project configuration 'Debug|Win32'."
Any idea how to fix this?
Any help would be very appreciated
How about creating a fresh project in Visual Studio 2010 and adding the source files and dependencies. Then compile and run, always works!

Importing qt application with visual studio-link error

I used to build a Qt application with qmake using command prompt on visual studio 2010. But, I have recently installed Qt Visual Studio add-in and have imported a qt application from .pro file on visual studio, in order to be able to programm with IDE.
However, when I try to build the application, I get the following message:
MSVCRTD.lib(crtexew.obj) : error LNK2019: unresolved external symbol WinMain referenced in function __tmainCRTStartup
I know it has been said that this is a matter of choosing Windows (/SUBSYSTEM:WINDOWS) or Console (/SUBSYSTEM:CONSOLE) in the linker property of the project. However, neither option solves the problem. My Qt application uses GUI and also conole (I set CONFIG += console in .pro file).
I would appreciate if you could give me a suggestion to solve this issue.
Thanks a lot,
Daisuke
The problem is solved. I just needed to get rid of Windows::... additional option in "Linker"-"Command Line" and choose console in "Linker"-"System"

Linkage Error LNK1104 in Visual C++ 2010

Today I fired up Visual Studio 2010 (Visual C++) and started working on a project. The solution contains two projects. One is a static library I am writing, the other is a test application containing unit tests for the library.
Without changing anything from yesterday, the executable no longer links:
LINK : fatal error LNK1104: cannot open file 'mylib.lib'
The static library compiles and links fine. I have not changed the project settings in around a week, and it was linking just fine yesterday.
If I go into the executable project's settings and add a library directory for $(SolutionDir)\debug, I instead get the following link error:
LINK : fatal error LNK1104: cannot open file 'kernel32.lib'
I am not sure what the problem is. I have tried cleaning, rebuilding, and even rebooting my machine. Google turned up some bugs in ancient Visual C++ versions (but I'm using 2010), as well as the possibility that the program is already running. However, it is not running, and a reboot confirms this.
What would cause the linker not to find core libraries such as kernel32.lib, or for that matter, the output directory for my solution?
This is old-fashioned C++, a cross-platform library, not that managed stuff Microsoft added.
I had to check "Inherit from parent or project defaults" in the "Library Directories" dialog. Once I did that, the linker could find all the necessary libraries. I still had to include $(SolutionDir)\debug though.
Include the microsoft SDK directory in project->properties->linker->general->additional library directories.
on my computer it is
D:\Program Files\Microsoft SDKs\Windows\v7.1\Lib
I fixed this problem by disabling "Enable .NET Framework source stepping" (see: "Menu bar / Tools / Options / Debugging / General / Enable .NET Framework source stepping"). Apparently this is a bug in Visual Studio.

Resources