unresolved tokens when migrating from 2003 to 2005

Hello all,

I am writing a utility to programmatically zip and unzip files.  I am using Daniel Godson's C++ wrapper for the Minizip app by Gilles Vollant (which in turn makes use of code written by Jean-loup Gailly and Mark Adler).  See http://www.codeproject.com/cpp/unzip.asp.

Godson's code, as far as I can tell, was written in VS2003, whereas I'm working in VS2005 - beta2.  After dealing with some unicode issues and some deprecated functions, my project finally builds into....

....a giant mess of unresolved token errors.  31 of them, to be exact.  My build log looks like a Baskin-Robbins!

I'm a relatively new coder and am at a loss when it comes to compiler/linker/migration issues.  I've included my log below.  Any help would be most appreciated. 

Thanks,

bubbafett

 

Build Log
   

Build started: Project: RockitZip, Configuration: Debug|Win32

Command Lines
   
Creating temporary file "c:\Documents and Settings\kmp2040\My Documents\Visual Studio 2005\Projects\RockitZip\RockitZip\Debug\RSP0000016363088.rsp" with contents
[
/OUT:"Debug\RockitZip.exe" /INCREMENTAL /MANIFEST /MANIFESTFILE:"Debug\RockitZip.exe.intermediate.manifest" /DEBUG /ASSEMBLYDEBUG /PDB:"c:\Documents and Settings\kmp2040\My Documents\Visual Studio 2005\Projects\RockitZip\RockitZip\Debug\RockitZip.pdb" /SUBSYSTEM:CONSOLE /MACHINE:X86 /FIXED:No kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib

".\Debug\FILEMISC.obj"

".\Debug\RockitZip.obj"

".\Debug\stdafx.obj"

".\Debug\Unzipper.obj"

".\Debug\Zipper.obj"
]
Creating command line "link.exe @"c:\Documents and Settings\kmp2040\My Documents\Visual Studio 2005\Projects\RockitZip\RockitZip\Debug\RSP0000016363088.rsp" /NOLOGO /ERRORREPORT:PROMPT"
Output Window
   
Linking...
Unzipper.obj : error LNK2028: unresolved token (0A00003E) "int __stdcall unzLocateFile(void *,char const *,int)" ( unzLocateFile@@$$J212YGHPAXPBDH@Z) referenced in function "public: bool __thiscall CUnzipper::GotoFile(char const *,bool)" ( GotoFile@CUnzipper@@$$FQAE_NPBD_N@Z)
Unzipper.obj : error LNK2028: unresolved token (0A00003F) "int __stdcall unzGoToNextFile(void *)" ( unzGoToNextFile@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::GotoNextFile(char const *)" ( GotoNextFile@CUnzipper@@$$FQAE_NPBD@Z)
Unzipper.obj : error LNK2028: unresolved token (0A000041) "int __stdcall unzGoToFirstFile(void *)" ( unzGoToFirstFile@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::GotoFile(char const *,bool)" ( GotoFile@CUnzipper@@$$FQAE_NPBD_N@Z)
Unzipper.obj : error LNK2028: unresolved token (0A000044) "void * __stdcall unzOpen(char const *)" ( unzOpen@@$$J14YGPAXPBD@Z) referenced in function "public: bool __thiscall CUnzipper::OpenZip(char const *)" ( OpenZip@CUnzipper@@$$FQAE_NPBD@Z)
Unzipper.obj : error LNK2028: unresolved token (0A000046) "int __stdcall unzClose(void *)" ( unzClose@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::CloseZip(void)" ( CloseZip@CUnzipper@@$$FQAE_NXZ)
Unzipper.obj : error LNK2028: unresolved token (0A000047) "int __stdcall unzCloseCurrentFile(void *)" ( unzCloseCurrentFile@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::CloseZip(void)" ( CloseZip@CUnzipper@@$$FQAE_NXZ)
Unzipper.obj : error LNK2028: unresolved token (0A00004A) "int __stdcall unzReadCurrentFile(void *,void *,unsigned int)" ( unzReadCurrentFile@@$$J212YGHPAX0I@Z) referenced in function "public: bool __thiscall CUnzipper::UnzipFile(char const *,bool)" ( UnzipFile@CUnzipper@@$$FQAE_NPBD_N@Z)
Unzipper.obj : error LNK2028: unresolved token (0A00004B) "int __stdcall unzOpenCurrentFile(void *)" ( unzOpenCurrentFile@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::UnzipFile(char const *,bool)" ( UnzipFile@CUnzipper@@$$FQAE_NPBD_N@Z)
Unzipper.obj : error LNK2028: unresolved token (0A00004F) "int __stdcall unzGetCurrentFileInfo(void *,struct unz_file_info_s *,char *,unsigned long,void *,unsigned long,char *,unsigned long)" ( unzGetCurrentFileInfo@@$$J232YGHPAXPAUunz_file_info_s@@PADK0K2K@Z) referenced in function "public: bool __thiscall CUnzipper::GetFileInfo(struct UZ_FileInfo &)" ( GetFileInfo@CUnzipper@@$$FQAE_NAAUUZ_FileInfo@@@Z)
Unzipper.obj : error LNK2028: unresolved token (0A000051) "int __stdcall unzGetGlobalInfo(void *,struct unz_global_info_s *)" ( unzGetGlobalInfo@@$$J18YGHPAXPAUunz_global_info_s@@@Z) referenced in function "public: int __thiscall CUnzipper::GetFileCount(void)" ( GetFileCount@CUnzipper@@$$FQAEHXZ)
Zipper.obj : error LNK2028: unresolved token (0A000033) "int __stdcall zipCloseFileInZip(void *)" ( zipCloseFileInZip@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CZipper::AddFileToZip(char const *,bool)" ( AddFileToZip@CZipper@@$$FQAE_NPBD_N@Z)
Zipper.obj : error LNK2028: unresolved token (0A000034) "int __stdcall zipWriteInFileInZip(void *,void const *,unsigned int)" ( zipWriteInFileInZip@@$$J212YGHPAXPBXI@Z) referenced in function "public: bool __thiscall CZipper::AddFileToZip(char const *,bool)" ( AddFileToZip@CZipper@@$$FQAE_NPBD_N@Z)
Zipper.obj : error LNK2028: unresolved token (0A000036) "int __stdcall zipOpenNewFileInZip(void *,char const *,struct zip_fileinfo const *,void const *,unsigned int,void const *,unsigned int,char const *,int,int)" ( zipOpenNewFileInZip@@$$J240YGHPAXPBDPBUzip_fileinfo@@PBXI3I1HH@Z) referenced in function "public: bool __thiscall CZipper::AddFileToZip(char const *,bool)" ( AddFileToZip@CZipper@@$$FQAE_NPBD_N@Z)
Zipper.obj : error LNK2028: unresolved token (0A000045) "void * __stdcall zipOpen(char const *,int)" ( zipOpen@@$$J18YGPAXPBDH@Z) referenced in function "public: bool __thiscall CZipper::OpenZip(char const *,char const *,bool)" ( OpenZip@CZipper@@$$FQAE_NPBD0_N@Z)
Zipper.obj : error LNK2028: unresolved token (0A00004B) "int __stdcall zipClose(void *,char const *)" ( zipClose@@$$J18YGHPAXPBD@Z) referenced in function "public: bool __thiscall CZipper::CloseZip(void)" ( CloseZip@CZipper@@$$FQAE_NXZ)
Unzipper.obj : error LNK2019: unresolved external symbol "int __stdcall unzGetGlobalInfo(void *,struct unz_global_info_s *)" ( unzGetGlobalInfo@@$$J18YGHPAXPAUunz_global_info_s@@@Z) referenced in function "public: int __thiscall CUnzipper::GetFileCount(void)" ( GetFileCount@CUnzipper@@$$FQAEHXZ)
Unzipper.obj : error LNK2019: unresolved external symbol "int __stdcall unzGetCurrentFileInfo(void *,struct unz_file_info_s *,char *,unsigned long,void *,unsigned long,char *,unsigned long)" ( unzGetCurrentFileInfo@@$$J232YGHPAXPAUunz_file_info_s@@PADK0K2K@Z) referenced in function "public: bool __thiscall CUnzipper::GetFileInfo(struct UZ_FileInfo &)" ( GetFileInfo@CUnzipper@@$$FQAE_NAAUUZ_FileInfo@@@Z)
Unzipper.obj : error LNK2019: unresolved external symbol "int __stdcall unzClose(void *)" ( unzClose@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::CloseZip(void)" ( CloseZip@CUnzipper@@$$FQAE_NXZ)
Unzipper.obj : error LNK2019: unresolved external symbol "int __stdcall unzCloseCurrentFile(void *)" ( unzCloseCurrentFile@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::CloseZip(void)" ( CloseZip@CUnzipper@@$$FQAE_NXZ)
Unzipper.obj : error LNK2019: unresolved external symbol "int __stdcall unzReadCurrentFile(void *,void *,unsigned int)" ( unzReadCurrentFile@@$$J212YGHPAX0I@Z) referenced in function "public: bool __thiscall CUnzipper::UnzipFile(char const *,bool)" ( UnzipFile@CUnzipper@@$$FQAE_NPBD_N@Z)
Unzipper.obj : error LNK2019: unresolved external symbol "int __stdcall unzOpenCurrentFile(void *)" ( unzOpenCurrentFile@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::UnzipFile(char const *,bool)" ( UnzipFile@CUnzipper@@$$FQAE_NPBD_N@Z)
Unzipper.obj : error LNK2019: unresolved external symbol "void * __stdcall unzOpen(char const *)" ( unzOpen@@$$J14YGPAXPBD@Z) referenced in function "public: bool __thiscall CUnzipper::OpenZip(char const *)" ( OpenZip@CUnzipper@@$$FQAE_NPBD@Z)
Unzipper.obj : error LNK2019: unresolved external symbol "int __stdcall unzGoToNextFile(void *)" ( unzGoToNextFile@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::GotoNextFile(char const *)" ( GotoNextFile@CUnzipper@@$$FQAE_NPBD@Z)
Unzipper.obj : error LNK2019: unresolved external symbol "int __stdcall unzGoToFirstFile(void *)" ( unzGoToFirstFile@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CUnzipper::GotoFile(char const *,bool)" ( GotoFile@CUnzipper@@$$FQAE_NPBD_N@Z)
Unzipper.obj : error LNK2019: unresolved external symbol "int __stdcall unzLocateFile(void *,char const *,int)" ( unzLocateFile@@$$J212YGHPAXPBDH@Z) referenced in function "public: bool __thiscall CUnzipper::GotoFile(char const *,bool)" ( GotoFile@CUnzipper@@$$FQAE_NPBD_N@Z)
Zipper.obj : error LNK2019: unresolved external symbol "int __stdcall zipClose(void *,char const *)" ( zipClose@@$$J18YGHPAXPBD@Z) referenced in function "public: bool __thiscall CZipper::CloseZip(void)" ( CloseZip@CZipper@@$$FQAE_NXZ)
Zipper.obj : error LNK2019: unresolved external symbol "void * __stdcall zipOpen(char const *,int)" ( zipOpen@@$$J18YGPAXPBDH@Z) referenced in function "public: bool __thiscall CZipper::OpenZip(char const *,char const *,bool)" ( OpenZip@CZipper@@$$FQAE_NPBD0_N@Z)
Zipper.obj : error LNK2019: unresolved external symbol "int __stdcall zipCloseFileInZip(void *)" ( zipCloseFileInZip@@$$J14YGHPAX@Z) referenced in function "public: bool __thiscall CZipper::AddFileToZip(char const *,bool)" ( AddFileToZip@CZipper@@$$FQAE_NPBD_N@Z)
Zipper.obj : error LNK2019: unresolved external symbol "int __stdcall zipWriteInFileInZip(void *,void const *,unsigned int)" ( zipWriteInFileInZip@@$$J212YGHPAXPBXI@Z) referenced in function "public: bool __thiscall CZipper::AddFileToZip(char const *,bool)" ( AddFileToZip@CZipper@@$$FQAE_NPBD_N@Z)
Zipper.obj : error LNK2019: unresolved external symbol "int __stdcall zipOpenNewFileInZip(void *,char const *,struct zip_fileinfo const *,void const *,unsigned int,void const *,unsigned int,char const *,int,int)" ( zipOpenNewFileInZip@@$$J240YGHPAXPBDPBUzip_fileinfo@@PBXI3I1HH@Z) referenced in function "public: bool __thiscall CZipper::AddFileToZip(char const *,bool)" ( AddFileToZip@CZipper@@$$FQAE_NPBD_N@Z)
Debug\RockitZip.exe : fatal error LNK1120: 30 unresolved externals
Results
   
Build log was saved at "file://c:\Documents and Settings\kmp2040\My Documents\Visual Studio 2005\Projects\RockitZip\RockitZip\Debug\BuildLog.htm"
RockitZip - 31 error(s), 0 warning(s)

 




Answer this question

unresolved tokens when migrating from 2003 to 2005

  • Cyber Wombat

    These external libraryies don't seem to be in the linker command line, are you sure that you have included them in the additional dependancies.

    Another problem could be that you are trying to reference C functions from a C++ file. In that case you would need the extern"c" to say that its a C extern instead of a C++ extern, but that is usually taken care of in the headers anyway.



  • Labrego

    Looks like you might be missing some libraries to link to. See where such symbols are defined and make sure you link against the needed libs.

    If you can't locate where such symbols are defined then I am sure the folks on codeproject can point you to the correct direction.

    Thanks,
    Ayman Shoukry
    VC++ Team


  • unresolved tokens when migrating from 2003 to 2005