LNK1104: cannot open file 'LIBC.lib'

A

Amrit Kohli

Hello. I am trying to run the VS C++ compiler from the command line. I
enter the following:

cl -GX prog1.cpp

It compiles the file fine, but then when it goes to link the object file, I
encounter the following error:

LINK : fatal error LNK1104: cannot open file 'LIBC.lib'

I'm sure this has something to do with a path variable that is not set
correctly. What enviornment variable does LINK use to locate the
appropriate library files?

Thanks for any help!

Amrit Kohli
 
D

Doug Harrison [MVP]

Hello. I am trying to run the VS C++ compiler from the command line. I
enter the following:

cl -GX prog1.cpp

It compiles the file fine, but then when it goes to link the object file, I
encounter the following error:

LINK : fatal error LNK1104: cannot open file 'LIBC.lib'

I'm sure this has something to do with a path variable that is not set
correctly. What enviornment variable does LINK use to locate the
appropriate library files?

You should run vsvars32.bat to set up the environment.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top