Visual C++ 2005 linking and file sizes

This is a discussion on Visual C++ 2005 linking and file sizes within the C++ Programming forums, part of the General Programming Boards category; I am using the Visual C++ 2005 Express and when I create a empty project, add a simple .cpp file ...

  1. #1
    Registered User
    Join Date
    Aug 2004
    Posts
    731

    Visual C++ 2005 linking and file sizes

    I am using the Visual C++ 2005 Express and when I create a empty project, add a simple .cpp file to it and compile it, I get this compiler log:

    Code:
    ------ Build started: Project: D3D Engine, Configuration: Release Win32 ------
    Compiling...
    Engine.cpp
    Linking...
    Searching libraries
        Searching C:\Program Files\Microsoft Platform SDK\Lib\kernel32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\user32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\gdi32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\uuid.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\libcpmt.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3d9.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3dx9.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\LIBCMT.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\OLDNAMES.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\kernel32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\user32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\gdi32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\uuid.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\libcpmt.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3d9.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3dx9.lib:
    Finished searching libraries
       Creating library C:\Documents and Settings\Alex\Desktop\D3D Engine\Release\D3D Engine.lib and object C:\Documents and Settings\Alex\Desktop\D3D Engine\Release\D3D Engine.exp
    Searching libraries
        Searching C:\Program Files\Microsoft Platform SDK\Lib\kernel32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\user32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\gdi32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\uuid.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\libcpmt.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3d9.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3dx9.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\LIBCMT.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\OLDNAMES.lib:
    Finished searching libraries
    Searching libraries
        Searching C:\Program Files\Microsoft Platform SDK\Lib\kernel32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\user32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\gdi32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\uuid.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\libcpmt.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3d9.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3dx9.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\LIBCMT.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\OLDNAMES.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\kernel32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\user32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\gdi32.lib:
        Searching C:\Program Files\Microsoft Platform SDK\Lib\uuid.lib:
        Searching C:\Program Files\Microsoft Visual Studio 8\VC\lib\libcpmt.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3d9.lib:
        Searching C:\Program Files\Microsoft DirectX 9.0 SDK (October 2005)\Lib\x86\d3dx9.lib:
    Finished searching libraries
    Build log was saved at "file://c:\Documents and Settings\Alex\Desktop\D3D Engine\Release\BuildLog.htm"
    D3D Engine - 0 error(s), 0 warning(s)
    ========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
    But it is researching or what ever the libaries many times and the output file is 100kb, and that just doesn't seem right. I think the file size is larger than it should be because it is linking the libaries more than once. If I am right how do I stop this, I tried everything?

  2. #2
    Unregistered User
    Join Date
    Sep 2005
    Location
    Antarctica
    Posts
    341
    It's not linking them more than once, if it was, there would be ambiguity to which is the true location of the functions being used.

  3. #3
    Registered User
    Join Date
    Aug 2004
    Posts
    731
    ahh ok well thanks for confirming that.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Visual C++ Linking with mmsystem.h
    By koooee in forum Windows Programming
    Replies: 2
    Last Post: 07-02-2009, 02:43 PM
  2. linking .c's and .h's in a project file
    By dezz101 in forum C Programming
    Replies: 6
    Last Post: 09-12-2008, 08:02 AM
  3. #include header files or .cpp files?
    By DoctorX in forum C++ Programming
    Replies: 3
    Last Post: 12-23-2006, 11:21 AM
  4. C++ std routines
    By siavoshkc in forum C++ Programming
    Replies: 33
    Last Post: 07-28-2006, 12:13 AM
  5. Replies: 4
    Last Post: 07-06-2006, 02:53 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21