none
LINK : fatal error LNK1104: cannot open file ' '?

    Question

  • I use vs2008 to complie driver code.I have changed some options to adapt the driver programming.But it always display the following error:

    1>Compiling...
    1>cl : Command line warning D4002 : ignoring unknown option '/errorReport:prompt'
    1>cl : Command line warning D4024 : unrecognized source file type '?', object file assumed
    1>LINK : fatal error LNK1104: cannot open file ''

    How can i change the configuration of vs2008 to compile driver code?

    • Moved by Brittany Behrens Monday, August 23, 2010 11:34 PM (From:Visual Studio Editor)
    • Moved by Nancy Shao Wednesday, August 25, 2010 8:28 AM vc question (From:MSBuild)
    Monday, August 23, 2010 7:35 AM

Answers

  • Hi Fengshuiyue,

    As it is known, Microsoft officially doesn't support integration of DDK with Visual Studio. So if we want to use Visual Studio for compiling drivers, we need to configure Visual Studio 2008 for compiling drivers. For details, please refer to CodeProject article:

    How to Configure Visual Studio 2008 for Compiling Drivers

    Hope this helps.

    Best Regards,
    Nancy


    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    • Proposed as answer by Nancy Shao Wednesday, September 08, 2010 6:39 AM
    • Marked as answer by Nancy Shao Thursday, September 09, 2010 3:49 AM
    Monday, September 06, 2010 3:43 AM

All replies

  • Hi Fengshuiyue,

    I guess the problem is that you might be using an earlier version of the compiler (cl.exe) than the one included with VS 2008. Try typing cl.exe into the VS Command prompt and see what you get. If you getting:

    Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 15.00.21022.08 for 80x86
    Copyright (C) Microsoft Corporation.  All rights reserved.

    It means you get right version. If its version is lower than 15, it means you use an earlier version of the compiler, please try to add Driver:\Program Files\Microsoft Visual Studio 9.0\VC\bin to Tools > Options > Projects and Solutions > VC++ Directories > Executable Files ( Show directores for).

    For your reference, please refer to this similar thread in MSDN forum:

    http://social.msdn.microsoft.com/forums/en-US/vcgeneral/thread/861bfad1-e49c-4400-93dd-d21876318d0d/

    And I'm moving this thread to "Visual C++ General" forum, since this issue is more related to Visual C++, and there are lots of Visual C++ experts in "Visual C++ General" forum.

    Best Regards,
    Nancy


    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    • Marked as answer by Nancy Shao Wednesday, September 01, 2010 9:39 AM
    • Unmarked as answer by fengshuiyue Friday, September 03, 2010 12:06 PM
    Wednesday, August 25, 2010 8:26 AM
  •    hello,I am learning driver developling,I want use vs2008 with DDk to complie the code of driver of development,I add D:\WinDDK\3790.1830\bin\x86 to Tools > Options > Projects and Solutions > VC++ Directories > Executable Files ,add D:\WinDDK\3790.1830\inc\wxp,D:\WinDDK\3790.1830\inc\crt,D:\WinDDK\3790.1830\inc\ddk\wxp,D:\WinDDK\3790.1830\inc\wdm\wxp to  Tools > Options > Projects and Solutions > VC++ Directories >Include Files ,and add D:\WinDDK\3790.1830\lib\wxp\i386 to Tools > Options > Projects and Solutions > VC++ Directories >Libary Files.

      Beside,I change the related property in Project > Project Property Page. But I can't compile the program. I want know how to change the related configuration to compile the DDK source code.

    Friday, September 03, 2010 12:24 PM
  • Hi Fengshuiyue,

    As it is known, Microsoft officially doesn't support integration of DDK with Visual Studio. So if we want to use Visual Studio for compiling drivers, we need to configure Visual Studio 2008 for compiling drivers. For details, please refer to CodeProject article:

    How to Configure Visual Studio 2008 for Compiling Drivers

    Hope this helps.

    Best Regards,
    Nancy


    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    • Proposed as answer by Nancy Shao Wednesday, September 08, 2010 6:39 AM
    • Marked as answer by Nancy Shao Thursday, September 09, 2010 3:49 AM
    Monday, September 06, 2010 3:43 AM