HighTechTalks DotNet Forums  

Which library do I need to add?

VC++.net Libraries microsoft.public.dotnet.languages.vc.libraries


Discuss Which library do I need to add? in the VC++.net Libraries forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Michael
 
Posts: n/a

Default Which library do I need to add? - 05-21-2010 , 04:35 AM






Hi, I am trying to link a very old console program written in 1992 as I've
got to fix a bug (I haven't made any changes to it yet, just trying to build
the original source). I'm using Visual C++ 6.0 on Windows XP.

I'm getting the following unresolved externals:
--------------------Configuration: make1 - Win32 Debug--------------------
Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
link /RELEASE /NODEFAULTLIB /INCREMENTAL:NO /PDB:NONE /RELEASE /NOLOGO
-subsystem:console,4.0 lpr.obj lp.obj -out:lpr.exe libc.lib oldnames.lib
kernel32.lib wst.lib wsock32.lib advapi32.lib
lpr.obj : error LNK2001: unresolved external symbol __ctime64
lpr.obj : error LNK2001: unresolved external symbol __time64
lpr.obj : error LNK2001: unresolved external symbol ___security_cookie
lpr.obj : error LNK2001: unresolved external symbol @__security_check_cookie@4
lpr.obj : error LNK2001: unresolved external symbol ___iob_func
lpr.obj : error LNK2001: unresolved external symbol __findnext64i32
lpr.obj : error LNK2001: unresolved external symbol __findfirst64i32
lpr.exe : fatal error LNK1120: 7 unresolved externals
NMAKE : fatal error U1077: 'link' : return code '0x460'
Stop.
Error executing NMAKE.

make1.exe - 9 error(s), 0 warning(s)


Any idea what libraries I need to add / change to resolve these? I've tried
internet searches but haven't found anything helpful.

I have compiled and linked this before succesfully, but that was 4 years ago
and an older PC, so something's changed in the mean time. I did try a build
in VS2010 but got *lots* of errors and warnings.

Thanks,

Michael

Reply With Quote
  #2  
Old   
David Lowndes
 
Posts: n/a

Default Re: Which library do I need to add? - 05-21-2010 , 05:19 AM






Quote:
Hi, I am trying to link a very old console program written in 1992 as I've
got to fix a bug (I haven't made any changes to it yet, just trying to build
the original source). I'm using Visual C++ 6.0 on Windows XP.

I'm getting the following unresolved externals:
--------------------Configuration: make1 - Win32 Debug--------------------
Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
link /RELEASE /NODEFAULTLIB /INCREMENTAL:NO /PDB:NONE /RELEASE /NOLOGO
-subsystem:console,4.0 lpr.obj lp.obj -out:lpr.exe libc.lib oldnames.lib
kernel32.lib wst.lib wsock32.lib advapi32.lib
lpr.obj : error LNK2001: unresolved external symbol __ctime64
lpr.obj : error LNK2001: unresolved external symbol __time64
lpr.obj : error LNK2001: unresolved external symbol ___security_cookie
lpr.obj : error LNK2001: unresolved external symbol @__security_check_cookie@4
lpr.obj : error LNK2001: unresolved external symbol ___iob_func
lpr.obj : error LNK2001: unresolved external symbol __findnext64i32
lpr.obj : error LNK2001: unresolved external symbol __findfirst64i32
Michael,

From the presence of those "64" symbols it would appear that something
in your project has perhaps been built with a more recent version of
VS - I don't remember VC6 having the "64" variants of those library
functions.

Dave

Reply With Quote
  #3  
Old   
Michael
 
Posts: n/a

Default Re: Which library do I need to add? - 05-21-2010 , 08:33 AM



You were right, I'd previously attempted a build using a newer version of
Visual Studio and was getting lots of errors + warnings about deprecated
functions. I then remember it was built with the old version so I switched
back. But it had left "new" object files behind and those were failing to
link under the old version, since I hadn't made any changes to the source the
object files hadn't got regenerated. Deleting everything and doing a
Rebuild all has fixed the problem and I'm now able to build the executable.


So now I can go ahead and try and fix the bug that started all this!

Thanks for your help.

Michael
"David Lowndes" wrote:

Quote:
Hi, I am trying to link a very old console program written in 1992 as I've
got to fix a bug (I haven't made any changes to it yet, just trying to build
the original source). I'm using Visual C++ 6.0 on Windows XP.

I'm getting the following unresolved externals:
--------------------Configuration: make1 - Win32 Debug--------------------
Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
link /RELEASE /NODEFAULTLIB /INCREMENTAL:NO /PDB:NONE /RELEASE /NOLOGO
-subsystem:console,4.0 lpr.obj lp.obj -out:lpr.exe libc.lib oldnames.lib
kernel32.lib wst.lib wsock32.lib advapi32.lib
lpr.obj : error LNK2001: unresolved external symbol __ctime64
lpr.obj : error LNK2001: unresolved external symbol __time64
lpr.obj : error LNK2001: unresolved external symbol ___security_cookie
lpr.obj : error LNK2001: unresolved external symbol @__security_check_cookie@4
lpr.obj : error LNK2001: unresolved external symbol ___iob_func
lpr.obj : error LNK2001: unresolved external symbol __findnext64i32
lpr.obj : error LNK2001: unresolved external symbol __findfirst64i32

Michael,

From the presence of those "64" symbols it would appear that something
in your project has perhaps been built with a more recent version of
VS - I don't remember VC6 having the "64" variants of those library
functions.

Dave
.

Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.