Lnk1104: cannot open file 'libc. lib' 2009-05-23
If a project developed with a lower version of VC is obtained to a later version of VC development environment for compilation, the lnk1104 error may be triggered during the link. The solution is to ignore this library when linking. There are two solutions: Project | properties | configuration properties | linker | Input Ignore specific Library: libc. Lib Or # Pragma comment (linker, "/nodefaultlib: libc. lib ") |
• Run-time Library is the standard library provided by the compiler and provides some basic library functions and system calls.
The run-time library we generally use is C run-time libraries. Standard C ++ libraries is also available.
C run-time libraries implements the ansi c standard library. The CRT directory of the VC installation directory contains most of the source code of the C run-time library. C run-time libraries has a static library version, a dynamic link library version, a single-thread version, a multi-thread version, and a debug and non-debug version. • Dynamic Link Library version:
/MD multithreaded DLL import database msvcrt. Lib
/MDD debug multithreaded DLL use the import library msvcrtd. Lib • static library version:
/Ml single-threaded uses static library libc. Lib
/MLD debug single-threaded use static library libcd. Lib
/MT multithreaded uses the static library libcmt. Lib
/MTD debug multithreaded uses the static library libcmtd. Lib
To use this Runtime Library |
Ignore these libraries |
Single thread (libc. Lib) |
Libcmt. Lib, msvcrt. Lib, libcd. Lib, libcmtd. Lib, and msvcrtd. Lib |
Multithreading (libcmt. Lib) |
Libc. Lib, msvcrt. Lib, libcd. Lib, libcmtd. Lib, and msvcrtd. Lib |
Multiple Threads Using DLL (msvcrt. Lib) |
Libc. Lib, libcmt. Lib, libcd. Lib, libcmtd. Lib, and msvcrtd. Lib |
Debug a single thread (libcd. Lib) |
Libc. Lib, libcmt. Lib, msvcrt. Lib, libcmtd. Lib, and msvcrtd. Lib |
Debug multiple threads (libcmtd. Lib) |
Libc. Lib, libcmt. Lib, msvcrt. Lib, libcd. Lib, and msvcrtd. Lib |
Multi-thread Debugging Using DLL (msvcrtd. Lib) |
Libc. Lib, libcmt. Lib, msvcrt. Lib, libcd. Lib, libcmtd. Lib |