Discussion:
Why do I need 'libc.lib' when I compile my program that uses Switch Executive's API in Visual studio 2005?
(too old to reply)
Eric Pope
2008-08-15 17:10:14 UTC
Permalink
Hi there, I'm just getting started with learning Switch Executive's API. I followed the "Getting Started->Using NI Switch Executive in Visual C++" instructions in the documentation, but when I tried to compile my simple C++/CLI program: #include "stdafx.h"
#include "nise.h"

using namespace System;

int main(array<System::String ^> ^args)
{
    NISESession mySess;
    niSE_OpenSession("myDevice", "",  &mySess);
    return 0;
}  I get a linker error: fatal error LNK1104: cannot open file 'libc.lib'  I looked up the error and the file and it turns out libc.lib is an older runtime library from visual studio 2003. And it is no longer used in VS2005 projects.  I checked my project settings and they are all set to use the /MDd "Multi-threaded Debug DLL runtime library. I don't think I even have a copy of libc.lib on my computer. Do I need to go and download it from somewhere in order to link with NISE? Thanks for the help,Eric 
Eric Pope
2008-08-15 17:10:14 UTC
Permalink
Aha, I think I found a workaround: add "libc.lib" to the ignore specific library property under Project Proeprties->Linker->Input->IgnoreSpecific Library. Hope this helps someone else. Eric 
Loading...