Thread: LINK2001 Error? VS 2008 C++

  1. #1
    Registered User
    Join Date
    Nov 2009
    Posts
    3

    LINK2001 Error? VS 2008 C++

    Well I am trying to compile the source code for a mod for a game, and although I was able to compile it on another machine with windows XP, I have attempted to do so on this machine and now getting errors? I do not believe it has to do with the code itself but pherhaps I need something else to ensure it can compile this for C++?
    Code:
    Linking...
       Creating library Debug/cgame_mp_x86.lib and object Debug/cgame_mp_x86.exp
    cg_draw.obj : error LNK2001: unresolved external symbol _CG_DrawFloatingStrings
    cg_ents.obj : error LNK2001: unresolved external symbol _CG_DrawLandmine
    cg_ents.obj : error LNK2001: unresolved external symbol _CG_AddFloatingString
    cg_players.obj : error LNK2001: unresolved external symbol _CG_AddFloatingString
    cg_main.obj : error LNK2001: unresolved external symbol _DisableStackTrace
    cg_main.obj : error LNK2001: unresolved external symbol _EnableStackTrace
    ..\Debug/cgame_mp_x86.dll : fatal error LNK1120: 5 unresolved externals
    Error executing link.exe.
    I am quite new to C++ however, I can't see why it would compile fine on one machine and yet not another with the same software.

    If anyone is particularly interested the game is Wolfenstein: Enemy Territory the mod is etpub.

    As I said, other poepole can also compile this error free, I have not edited the source at all. I have tried using VS 6 and VS 2008 C++ (both windows).

    Any help would be awesome, noone else seems to have this problem either on the site supporting the mod, so im assuming its something to do with a framework or something I may need..

    Kind Regards, Kazzal

  2. #2
    Jack of many languages Dino's Avatar
    Join Date
    Nov 2007
    Location
    Chappell Hill, Texas
    Posts
    2,332
    You are not getting compile errors, you are getting LINK errors - they are quite different.

    It seems you need to add the mod's lib to your build settings.
    Mainframe assembler programmer by trade. C coder when I can.

  3. #3
    Registered User
    Join Date
    Nov 2009
    Posts
    3
    Could you please tell me how I would go about doing such a thing?

  4. #4
    Registered User
    Join Date
    Nov 2009
    Posts
    3
    Dw, I resolved this, therew as a solution file for visual studio 2008 c++, mnust have been a directory location issue with the new VS.

    All fixed. Kind Regards

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. C & visual studio 2008
    By Red Maw in forum C Programming
    Replies: 2
    Last Post: 04-02-2009, 09:06 PM
  2. Visual C++ 2008 Express questions...
    By edomingox in forum C++ Programming
    Replies: 4
    Last Post: 10-03-2008, 08:35 AM
  3. Visual 2008 proffesional acting up??
    By fenx591 in forum C++ Programming
    Replies: 3
    Last Post: 09-06-2008, 07:06 PM