Results 1 to 5 of 5

Thread: Linker errors under win2k...

  1. #1

    Thread Starter
    Frenzied Member CyberCarsten's Avatar
    Join Date
    Sep 1999
    Location
    Aalborg Ø, Denmark
    Posts
    1,544

    Linker errors under win2k...

    Ok, I get this nasty error every time I try to compile a windows app under win2k:

    --------------------Configuration: PROG3_2 - Win32 Debug--------------------
    Linking...
    LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
    Debug/PROG3_2.exe : fatal error LNK1120: 1 unresolved externals
    Error executing link.exe.

    PROG3_2.exe - 2 error(s), 0 warning(s)


    I have tried uninstalling/reinstalling VS...without luck....

    Have any of you experienced this error before???
    razor
    Software Engineer Student, Aalborg University, Denmark
    http://www.cs.auc.dk

    My email at AUC: will get a new email soon
    My website: http://www.razorsoftware.net


    Windows XP Pro/ Gentoo Linux (Laptop)
    Windows XP Pro (Home PC)

  2. #2
    Frenzied Member Vlatko's Avatar
    Join Date
    Aug 2000
    Location
    Skopje, Macedonia
    Posts
    1,409
    Are you making a console app. If so then make sure you haven't chosen win32 app.
    I am become death, the destroyer of worlds.
    mail:[email protected]

    • Visual Basic 6.0 & .NET
    • Visual C++ 6.0 & .NET
    • ASP
    • LISP
    • PROLOG
    • C
    • Pascal

  3. #3

    Thread Starter
    Frenzied Member CyberCarsten's Avatar
    Join Date
    Sep 1999
    Location
    Aalborg Ø, Denmark
    Posts
    1,544
    I'm creating a win32 app, and I have also selected that type...
    Last edited by CyberCarsten; Jul 15th, 2001 at 05:44 AM.
    razor
    Software Engineer Student, Aalborg University, Denmark
    http://www.cs.auc.dk

    My email at AUC: will get a new email soon
    My website: http://www.razorsoftware.net


    Windows XP Pro/ Gentoo Linux (Laptop)
    Windows XP Pro (Home PC)

  4. #4

    Thread Starter
    Frenzied Member CyberCarsten's Avatar
    Join Date
    Sep 1999
    Location
    Aalborg Ø, Denmark
    Posts
    1,544
    I have found another problem...I get these errors when I compile DirectX apps....

    --------------------Configuration: PROG9_1 - Win32 Debug--------------------
    Linking...
    PROG9_1.OBJ : error LNK2001: unresolved external symbol _DirectDrawCreate@12
    LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
    Debug/PROG9_1.exe : fatal error LNK1120: 2 unresolved externals
    Error executing link.exe.

    PROG9_1.exe - 3 error(s), 0 warning(s)
    razor
    Software Engineer Student, Aalborg University, Denmark
    http://www.cs.auc.dk

    My email at AUC: will get a new email soon
    My website: http://www.razorsoftware.net


    Windows XP Pro/ Gentoo Linux (Laptop)
    Windows XP Pro (Home PC)

  5. #5
    Frenzied Member Technocrat's Avatar
    Join Date
    Jan 2000
    Location
    I live in the 1s and 0s of everyones data streams
    Posts
    1,024
    PROG9_1.OBJ : error LNK2001: unresolved external symbol _DirectDrawCreate@12
    ----As I stated in the other Post You do not have the direct draw libs linked (See Bottom For A Quick Way To Link)

    LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
    ----Vlatko must be right, you must not have made a Win32 App because I have never seen this error on a Win32 App

    Here is how to setup Direct X links:

    PHP Code:

    #define WIN32_LEAN_AND_MEAN
    #include <windows.h>
    #include <D3DX8.h>
    #include <DDraw.h>

    // This is causes the DX .libs to be linked in, the same thing can be accomplished by
    // adding it to your compiler's link list (Project->Settings->Link in VC++),
    // but I prefer this method.
    #pragma comment(lib,"d3d8.lib")     //DirectX 3D
    #pragma comment(lib,"d3dx8.lib")   //DirectX 3D
    #pragma comment(lib,"dxguid.lib")  //Needed For DirectDraw
    #pragma comment(lib,"ddraw.lib")  //Needed For DirectDraw 
    MSVS 6, .NET & .NET 2003 Pro
    I HATE MSDN with .NET & .NET 2003!!!

    Check out my sites:
    http://www.filthyhands.com
    http://www.techno-coding.com


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width