Compiler version not supported by Windows DDK.

Hi, Jussi,

With all due respect to Walter’s outstanding presence in the
kernel dev world and his excellent book and software, I really
do believe that if you’re a newbie you should not use wizards to
generate code. Wizards and code generators are more adequate for
senior developers, who can see between the lines and who can
modify the generated code if need be! Moreover, it’s an
invaluable experience to get one’s own code to work, there’s no
replacement for that.

Now, can you use VC6 to do drivers ? Yes you can - and I say
that knowing that many a very senior poster in this list will
frontally disagree with me. I have used VC6 myself over and
again, my code works, and I’ve seen very serious pieces of
driver code built with VC6. However…

That said, I warn you, this is not for newbies. I would stick to
the DDK compiler, not because it’s “safer” or because it’s “the
rule” or any other nonsense in that general direction. My point
is, it’s EASIER, way easier. You avoid having to deal with
issues of code generation, which will on occasion generate
problems that need specialized knowledge to solve. If you’re a
senior hat you will naturally compensate for that when you write
your code, but even then, that may take a level of knowledge of
compiler technology that not everyone may be willing to amass.

And you’re going to bump into issues such as yours: Walter’s
wizard seems to require you to use the DDK compiler, and you may
find yourself into other situations where actions by other
people constrain your power of choice.

What you can do, and it’s a very easy step, is to set up your
VC6 shell to use the DDK compiler. I usually set up a project
with all my driver sources, and if I want to be conservative and
be able to use build.exe to build the driver, this is what I do:

  1. The ddk compiler is at
    %myddkdroot%%myddkversion%\bin%mymachine%. For example,
    c:\winddk\3970.1830\bin\x86. I use my “tools/options” to put
    that directory on the very top of the executable path. I do the
    same for includes and library files. Once I do that, I have a
    setup that will run ddk software when I need it.

  2. I set whatever other non-ddk paths in my project settings.

  3. I invoke the vc6 shell (msdev.exe) from inside one of the ddk
    cmd boxes (checked or free build for %mymachine%). This gives me
    a very nice editing and project management environment. But note
    that even now I cannot build using the VC6 build toolbar,
    because the -D external variables aren’t set. So,

  4. I set up a custom build step to run build.exe. Or else I can
    just have both the VC6 IDE and the DDK cmd box open, and I can
    run build.exe from the cmd box while I edit and manage my
    project from the IDE. This has the added advantage that I can
    use project/settings to point the project to the adequate source
    control, which integrates editing and checking files in or out.
    Furthermore, if my driver is complicated enough that I have a
    component that doesn’t call any OS entry point and that can be
    packaged as a separate library or dll (most of my drivers fell
    under that category, if nothing else because in many occasions I
    have to write them so that most of the code was portable between
    Windows, Linux, and other Unix-like OS’s), that component can be
    built by the IDE and linked into the driver by adding the
    resulting library or libraries to your sources file.

  5. An added benefit is that you can have both the driver and the
    app in the same VC6 workspace, for example, in two separate
    projects. Even if you don’t use the IDE to build your driver,
    you can use it to build the app, and the IDE provides you with a
    very convenient way of sharing common components such as include
    files or even libraries.

Note that this is even more convenient with VS.NET, because it
has a huge amount of programmability and scripting ability:
whatever functionality the IDE lacks you can readily add in by
writing a macro or an addin.

I hope this helps, if not, discard it!

Alberto.

“Jussi Rytilahti” wrote in message
news:xxxxx@hormel8.ieee.org
> Hi,
>
> I am total newbie with drivers. I have one problem. I am
> reading Walter Oneys book “Programming the Microsoft Windows
> Driver Model, Ed2” and now I´d like to try his AppWizard for
> Visual C++ 6.0 (WDMWIZ.AWX). I get every time same error :
> error C1189: #error : Compiler version not supported by
> Windows DDK. I am using DDK 2600.1106 and working OS is XP.
> Documentation of this wizard says that wizard is for VC++6.0
> and XP and .NET DDKs
>
> Do I have any chances to use VC++6.0 with my DDK? (I have also
> .NET, but wizard works only in 6.0)
>
> BR.
> Jussi
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: xxxxx@ieee.org
> To unsubscribe send a blank email to
> xxxxx@lists.osr.com

Just for completeness, remember that it’s very easy to get the
IDE to use the DDK compiler: just point to it in your
Tools/Options/Directories. Two different issues, compiler and
environment. Applies to both VC6 and VS.NET.

And, btw, I have put plenty of drivers into production using
nothing but VC6, or VC1.4 before that.

Alberto.

----- Original Message -----
From: “Don Burn”
Newsgroups: ntdev
To: “Windows System Software Devs Interest List”

Sent: Thursday, July 21, 2005 8:10 AM
Subject: Re:[ntdev] Compiler version not supported by Windows
DDK.

> No, the bottom line is that you should be using the compiler
> from the DDK to build things. Anything else will just cause
> bugs.
>
>
> –
> Don Burn (MVP, Windows DDK)
> Windows 2k/XP/2k3 Filesystem and Driver Consulting
> Remove StopSpam from the email to reply
>
>
> “Jussi Rytilahti” wrote in message
> news:xxxxx@ntdev…
>> Hi,
>>
>> Thanks for you answer.I tried that update, but it did not
>> help me, I am still getting same error.
>>
>> I have tried to open same project in .NET and I dont get that
>> same error.
>>
>> So only VC++6.0 is causing troubles?
>>
>> Jussi
>>
>> “Don Burn” kirjoitti viestissä:xxxxx@ntdev…
>>> With the current versions of the DDK (yours is 3 revs back,
>>> but still in this category), the compiler to use is provided
>>> by the DDK. I don’t know if Walter has a fix for this, have
>>> you downloaded the service pack for his code from
>>> http://www.oneysoft.com/newpack.htm
>>>
>>>
>>>
>>> –
>>> Don Burn (MVP, Windows DDK)
>>> Windows 2k/XP/2k3 Filesystem and Driver Consulting
>>> Remove StopSpam from the email to reply
>>>
>>>
>>> “Jussi Rytilahti” wrote in
>>> message news:xxxxx@ntdev…
>>>> Hi,
>>>>
>>>> I am total newbie with drivers. I have one problem. I am
>>>> reading Walter Oneys book “Programming the Microsoft
>>>> Windows Driver Model, Ed2” and now I´d like to try his
>>>> AppWizard for Visual C++ 6.0 (WDMWIZ.AWX). I get every time
>>>> same error : error C1189: #error : Compiler version not
>>>> supported by Windows DDK. I am using DDK 2600.1106 and
>>>> working OS is XP. Documentation of this wizard says that
>>>> wizard is for VC++6.0 and XP and .NET DDKs
>>>>
>>>> Do I have any chances to use VC++6.0 with my DDK? (I have
>>>> also .NET, but wizard works only in 6.0)
>>>>
>>>> BR.
>>>> Jussi
>>>>
>>>>
>>>
>>>
>>>
>>
>>
>>
>
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: xxxxx@ieee.org
> To unsubscribe send a blank email to
> xxxxx@lists.osr.com

Instead of wasting time mucking around with the IDE, spend your time
developing your driver code. Get DDKBUILD either from www.hollistech.com or
www.osronline.com and use the IDE to create a MAKEFILE project. That will
work across any version of Visual Studio including the 2005 beta 2.


The personal opinion of
Gary G. Little

“Jussi Rytilahti” wrote in message
news:xxxxx@ntdev…
> Hi,
>
> I am total newbie with drivers. I have one problem. I am reading Walter
> Oneys book “Programming the Microsoft Windows Driver Model, Ed2” and now
> I´d like to try his AppWizard for Visual C++ 6.0 (WDMWIZ.AWX). I get every
> time same error : error C1189: #error : Compiler version not supported by
> Windows DDK. I am using DDK 2600.1106 and working OS is XP. Documentation
> of this wizard says that wizard is for VC++6.0 and XP and .NET DDKs
>
> Do I have any chances to use VC++6.0 with my DDK? (I have also .NET, but
> wizard works only in 6.0)
>
> BR.
> Jussi
>
>

DDKBUILD does ALL of that for you and you can migrate the project from VS
version to VS version with little or no heartburn. Migrating a DSW to a .NET
2003 SLN to a 2005 SLN is going to induce multiple errors that are a pain in
the ass with which to deal. It is so very very simple to remove all the if’s
and’s or but’s here. Use DDKBUILD and create a makefile IDE project. THAT
will migrate to any version of VS and you can do what you are paid to do:
develop driver code, NOT muck around with silly ass settings in the IDE.

I feel like Obi Wan … “Use DDKBUILD Luke”


The personal opinion of
Gary G. Little

“Alberto Moreira” wrote in message news:xxxxx@ntdev…
> Hi, Jussi,
>
> With all due respect to Walter’s outstanding presence in the kernel dev
> world and his excellent book and software, I really do believe that if
> you’re a newbie you should not use wizards to generate code. Wizards and
> code generators are more adequate for senior developers, who can see
> between the lines and who can modify the generated code if need be!
> Moreover, it’s an invaluable experience to get one’s own code to work,
> there’s no replacement for that.
>
> Now, can you use VC6 to do drivers ? Yes you can - and I say that knowing
> that many a very senior poster in this list will frontally disagree with
> me. I have used VC6 myself over and again, my code works, and I’ve seen
> very serious pieces of driver code built with VC6. However…
>
> That said, I warn you, this is not for newbies. I would stick to the DDK
> compiler, not because it’s “safer” or because it’s “the rule” or any other
> nonsense in that general direction. My point is, it’s EASIER, way easier.
> You avoid having to deal with issues of code generation, which will on
> occasion generate problems that need specialized knowledge to solve. If
> you’re a senior hat you will naturally compensate for that when you write
> your code, but even then, that may take a level of knowledge of compiler
> technology that not everyone may be willing to amass.
>
> And you’re going to bump into issues such as yours: Walter’s wizard seems
> to require you to use the DDK compiler, and you may find yourself into
> other situations where actions by other people constrain your power of
> choice.
>
> What you can do, and it’s a very easy step, is to set up your VC6 shell to
> use the DDK compiler. I usually set up a project with all my driver
> sources, and if I want to be conservative and be able to use build.exe to
> build the driver, this is what I do:
>
> 1. The ddk compiler is at %myddkdroot%%myddkversion%\bin%mymachine%. For
> example, c:\winddk\3970.1830\bin\x86. I use my “tools/options” to put that
> directory on the very top of the executable path. I do the same for
> includes and library files. Once I do that, I have a setup that will run
> ddk software when I need it.
>
> 2. I set whatever other non-ddk paths in my project settings.
>
> 3. I invoke the vc6 shell (msdev.exe) from inside one of the ddk cmd boxes
> (checked or free build for %mymachine%). This gives me a very nice editing
> and project management environment. But note that even now I cannot build
> using the VC6 build toolbar, because the -D external variables aren’t set.
> So,
>
> 4. I set up a custom build step to run build.exe. Or else I can just have
> both the VC6 IDE and the DDK cmd box open, and I can run build.exe from
> the cmd box while I edit and manage my project from the IDE. This has the
> added advantage that I can use project/settings to point the project to
> the adequate source control, which integrates editing and checking files
> in or out. Furthermore, if my driver is complicated enough that I have a
> component that doesn’t call any OS entry point and that can be packaged as
> a separate library or dll (most of my drivers fell under that category, if
> nothing else because in many occasions I have to write them so that most
> of the code was portable between Windows, Linux, and other Unix-like
> OS’s), that component can be built by the IDE and linked into the driver
> by adding the resulting library or libraries to your sources file.
>
> 5. An added benefit is that you can have both the driver and the app in
> the same VC6 workspace, for example, in two separate projects. Even if you
> don’t use the IDE to build your driver, you can use it to build the app,
> and the IDE provides you with a very convenient way of sharing common
> components such as include files or even libraries.
>
> Note that this is even more convenient with VS.NET, because it has a huge
> amount of programmability and scripting ability: whatever functionality
> the IDE lacks you can readily add in by writing a macro or an addin.
>
> I hope this helps, if not, discard it!
>
> Alberto.
>
>
>
> “Jussi Rytilahti” wrote in message
> news:xxxxx@hormel8.ieee.org
>> Hi,
>>
>> I am total newbie with drivers. I have one problem. I am reading Walter
>> Oneys book “Programming the Microsoft Windows Driver Model, Ed2” and now
>> I´d like to try his AppWizard for Visual C++ 6.0 (WDMWIZ.AWX). I get
>> every time same error : error C1189: #error : Compiler version not
>> supported by Windows DDK. I am using DDK 2600.1106 and working OS is XP.
>> Documentation of this wizard says that wizard is for VC++6.0 and XP and
>> .NET DDKs
>>
>> Do I have any chances to use VC++6.0 with my DDK? (I have also .NET, but
>> wizard works only in 6.0)
>>
>> BR.
>> Jussi
>>
>>
>> —
>> Questions? First check the Kernel Driver FAQ at
>> http://www.osronline.com/article.cfm?id=256
>>
>> You are currently subscribed to ntdev as: xxxxx@ieee.org
>> To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>

Jussi Rytilahti wrote:

Do I have any chances to use VC++6.0 with my DDK? (I have also .NET, but
wizard works only in 6.0)

Zzzzzzzzzzzz…

Instead of spending time with new posts, or causing us all to repeat
positions we’ve posted, oh, eight or ten thousand times before, please
read the archives and the FAQ: www.osronline.com

Peter
OSR

With all due respect to Hollistech and to OSR, you need zero
third party software here.

Point your IDE to the DDK compiler, setup a project for your
driver - the settings are irrelevant - setup a custom build step
that invokes build.exe (or set it up so that you can reach it
from tools/external tools, or if you’re really fastidious set up
a build button on a toolbar), and setup an icon on your desktop
to run DEVENV.EXE from inside a checked or free build cmd
prompt: done. Takes what, five minutes work ?

Also, no driver lives alone: one often needs applications, and
it’s nice to have both projects under the same IDE workspace so
that if nothing else they can share include files and the like.
And if you really want to pig out, you can write a ten-line
script that runs build.exe to build your driver but the full IDE
build to make the app, link it to your build button, again,
done.

Use the IDE, dude.

Alberto.

----- Original Message -----
From: “Gary G. Little”
Newsgroups: ntdev
To: “Windows System Software Devs Interest List”

Sent: Thursday, July 21, 2005 10:18 AM
Subject: Re:[ntdev] Compiler version not supported by Windows
DDK.

> Instead of wasting time mucking around with the IDE, spend
> your time developing your driver code. Get DDKBUILD either
> from www.hollistech.com or www.osronline.com and use the IDE
> to create a MAKEFILE project. That will work across any
> version of Visual Studio including the 2005 beta 2.
>
> –
> The personal opinion of
> Gary G. Little
>
> “Jussi Rytilahti” wrote in message
> news:xxxxx@ntdev…
>> Hi,
>>
>> I am total newbie with drivers. I have one problem. I am
>> reading Walter Oneys book “Programming the Microsoft Windows
>> Driver Model, Ed2” and now I´d like to try his AppWizard for
>> Visual C++ 6.0 (WDMWIZ.AWX). I get every time same error :
>> error C1189: #error : Compiler version not supported by
>> Windows DDK. I am using DDK 2600.1106 and working OS is XP.
>> Documentation of this wizard says that wizard is for VC++6.0
>> and XP and .NET DDKs
>>
>> Do I have any chances to use VC++6.0 with my DDK? (I have
>> also .NET, but wizard works only in 6.0)
>>
>> BR.
>> Jussi
>>
>>
>
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: xxxxx@ieee.org
> To unsubscribe send a blank email to
> xxxxx@lists.osr.com

Hi,

Thanks again.

VC ++ is linked to DDK already, I think? The spot where VC++ 6.0 is stoping
is:

#if _MSC_VER < 1300
#error Compiler version not supported by Windows DDK
#endif

And .NET won´t stop to that same spot.

So what this “if” is checking?

Jussi

“Don Burn” kirjoitti viestissä:xxxxx@ntdev…
> No, the bottom line is that you should be using the compiler from the DDK
> to build things. Anything else will just cause bugs.
>
>
> –
> Don Burn (MVP, Windows DDK)
> Windows 2k/XP/2k3 Filesystem and Driver Consulting
> Remove StopSpam from the email to reply
>
>
> “Jussi Rytilahti” wrote in message
> news:xxxxx@ntdev…
>> Hi,
>>
>> Thanks for you answer.I tried that update, but it did not help me, I am
>> still getting same error.
>>
>> I have tried to open same project in .NET and I dont get that same error.
>>
>> So only VC++6.0 is causing troubles?
>>
>> Jussi
>>
>> “Don Burn” kirjoitti viestissä:xxxxx@ntdev…
>>> With the current versions of the DDK (yours is 3 revs back, but still in
>>> this category), the compiler to use is provided by the DDK. I don’t
>>> know if Walter has a fix for this, have you downloaded the service pack
>>> for his code from http://www.oneysoft.com/newpack.htm
>>>
>>>
>>>
>>> –
>>> Don Burn (MVP, Windows DDK)
>>> Windows 2k/XP/2k3 Filesystem and Driver Consulting
>>> Remove StopSpam from the email to reply
>>>
>>>
>>> “Jussi Rytilahti” wrote in message
>>> news:xxxxx@ntdev…
>>>> Hi,
>>>>
>>>> I am total newbie with drivers. I have one problem. I am reading Walter
>>>> Oneys book “Programming the Microsoft Windows Driver Model, Ed2” and
>>>> now I´d like to try his AppWizard for Visual C++ 6.0 (WDMWIZ.AWX). I
>>>> get every time same error : error C1189: #error : Compiler version not
>>>> supported by Windows DDK. I am using DDK 2600.1106 and working OS is
>>>> XP. Documentation of this wizard says that wizard is for VC++6.0 and XP
>>>> and .NET DDKs
>>>>
>>>> Do I have any chances to use VC++6.0 with my DDK? (I have also .NET,
>>>> but wizard works only in 6.0)
>>>>
>>>> BR.
>>>> Jussi
>>>>
>>>>
>>>
>>>
>>>
>>
>>
>>
>
>
>

Thanks all!

I have already tested “ddkbuild”-tool and original “build” also.

@Gary:And I like this ddkbuild and I am using it in my “training project” in
.NET 2003 and it seems to work very fine.

@Alberto:Your absolutelly right with this “try+success=learn” (Or something
like that). I will test your way also.

@PeterGV: I have tried look answer from you pages but I have not successed
with this problem: Why I get this error in VC6 but not .NET and Is that
possible to try this wizard in VC6 with my DDK.

So, question is :can I even try this wizard? Becource .AWX it is only
working in VC6, but I get that error. If I take all files which wizard has
created and build them in .NET (in project which uses ddkbuild) I will
succeed…Is the only way out: Create files in vc6 with wizard and then
build them in .NET?

Jussi

“Jussi Rytilahti” kirjoitti
viestissä:xxxxx@ntdev…
> Hi,
>
> I am total newbie with drivers. I have one problem. I am reading Walter
> Oneys book “Programming the Microsoft Windows Driver Model, Ed2” and now
> I´d like to try his AppWizard for Visual C++ 6.0 (WDMWIZ.AWX). I get every
> time same error : error C1189: #error : Compiler version not supported by
> Windows DDK. I am using DDK 2600.1106 and working OS is XP. Documentation
> of this wizard says that wizard is for VC++6.0 and XP and .NET DDKs
>
> Do I have any chances to use VC++6.0 with my DDK? (I have also .NET, but
> wizard works only in 6.0)
>
> BR.
> Jussi
>
>

This is checking that the version of the compiler is new enough for
constructs in the file. Since you are trying to use an old version of the
compiler, instead of the one in the DDK you are hitting this.

But even if you found a Visual Studio with the correct version, trying to
compile with it directly (versus using the BUILD tool from the DDK) will
cause bugs, even if it appears to work it is likely to have problems. At
best using anything other than the supplied tools is stupid, and worst it is
unprofessional and criminally negligent.


Don Burn (MVP, Windows DDK)
Windows 2k/XP/2k3 Filesystem and Driver Consulting
Remove StopSpam from the email to reply

“Jussi Rytilahti” wrote in message
news:xxxxx@ntdev…
> Hi,
>
> Thanks again.
>
> VC ++ is linked to DDK already, I think? The spot where VC++ 6.0 is
> stoping is:
>
> #if _MSC_VER < 1300
> #error Compiler version not supported by Windows DDK
> #endif
>
> And .NET won´t stop to that same spot.
>
> So what this “if” is checking?
>
> Jussi
>
> “Don Burn” kirjoitti viestissä:xxxxx@ntdev…
>> No, the bottom line is that you should be using the compiler from the DDK
>> to build things. Anything else will just cause bugs.
>>
>>
>> –
>> Don Burn (MVP, Windows DDK)
>> Windows 2k/XP/2k3 Filesystem and Driver Consulting
>> Remove StopSpam from the email to reply
>>
>>
>> “Jussi Rytilahti” wrote in message
>> news:xxxxx@ntdev…
>>> Hi,
>>>
>>> Thanks for you answer.I tried that update, but it did not help me, I am
>>> still getting same error.
>>>
>>> I have tried to open same project in .NET and I dont get that same
>>> error.
>>>
>>> So only VC++6.0 is causing troubles?
>>>
>>> Jussi
>>>
>>> “Don Burn” kirjoitti viestissä:xxxxx@ntdev…
>>>> With the current versions of the DDK (yours is 3 revs back, but still
>>>> in this category), the compiler to use is provided by the DDK. I don’t
>>>> know if Walter has a fix for this, have you downloaded the service pack
>>>> for his code from http://www.oneysoft.com/newpack.htm
>>>>
>>>>
>>>>
>>>> –
>>>> Don Burn (MVP, Windows DDK)
>>>> Windows 2k/XP/2k3 Filesystem and Driver Consulting
>>>> Remove StopSpam from the email to reply
>>>>
>>>>
>>>> “Jussi Rytilahti” wrote in message
>>>> news:xxxxx@ntdev…
>>>>> Hi,
>>>>>
>>>>> I am total newbie with drivers. I have one problem. I am reading
>>>>> Walter Oneys book “Programming the Microsoft Windows Driver Model,
>>>>> Ed2” and now I´d like to try his AppWizard for Visual C++ 6.0
>>>>> (WDMWIZ.AWX). I get every time same error : error C1189: #error :
>>>>> Compiler version not supported by Windows DDK. I am using DDK
>>>>> 2600.1106 and working OS is XP. Documentation of this wizard says that
>>>>> wizard is for VC++6.0 and XP and .NET DDKs
>>>>>
>>>>> Do I have any chances to use VC++6.0 with my DDK? (I have also .NET,
>>>>> but wizard works only in 6.0)
>>>>>
>>>>> BR.
>>>>> Jussi
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>
>>>
>>>
>>
>>
>>
>
>
>

Do not use the wizard. Do not folllow Alberto’s advice, since the learing
you mention will probably be at the cost of subtle bugs that appear in your
code, that may impact other peoples systems.

Playing is fine, but the bottom line is that driver development is hard
work. Adding to the work by using non-standard unreliable practices is
stupidity of the worst kind.


Don Burn (MVP, Windows DDK)
Windows 2k/XP/2k3 Filesystem and Driver Consulting
Remove StopSpam from the email to reply

“Jussi Rytilahti” wrote in message
news:xxxxx@ntdev…
> Thanks all!
>
> I have already tested “ddkbuild”-tool and original “build” also.
>
> @Gary:And I like this ddkbuild and I am using it in my “training project”
> in .NET 2003 and it seems to work very fine.
>
> @Alberto:Your absolutelly right with this “try+success=learn” (Or
> something like that). I will test your way also.
>
> @PeterGV: I have tried look answer from you pages but I have not successed
> with this problem: Why I get this error in VC6 but not .NET and Is that
> possible to try this wizard in VC6 with my DDK.
>
> So, question is :can I even try this wizard? Becource .AWX it is only
> working in VC6, but I get that error. If I take all files which wizard has
> created and build them in .NET (in project which uses ddkbuild) I will
> succeed…Is the only way out: Create files in vc6 with wizard and then
> build them in .NET?
>
> Jussi
>
> “Jussi Rytilahti” kirjoitti
> viestissä:xxxxx@ntdev…
>> Hi,
>>
>> I am total newbie with drivers. I have one problem. I am reading Walter
>> Oneys book “Programming the Microsoft Windows Driver Model, Ed2” and now
>> I´d like to try his AppWizard for Visual C++ 6.0 (WDMWIZ.AWX). I get
>> every time same error : error C1189: #error : Compiler version not
>> supported by Windows DDK. I am using DDK 2600.1106 and working OS is XP.
>> Documentation of this wizard says that wizard is for VC++6.0 and XP and
>> .NET DDKs
>>
>> Do I have any chances to use VC++6.0 with my DDK? (I have also .NET, but
>> wizard works only in 6.0)
>>
>> BR.
>> Jussi
>>
>>
>
>
>

Invoking build.exe directly is insufficient as build.exe depends on the
environment set up by the setenv.bat script that comes with the ddk. That
script in turn requires specific command line arguments. The appropriate
command line arguments to setenv.bat change from release to release. The ‘10
line shell script’, done correctly is more like 100-200 lines. Thus the
venerable ddkbuild.bat, which has managed to do this correctly (more or
less, your mileage may vary) since 1996.

=====================
Mark Roddy DDK MVP
Windows 2003/XP/2000 Consulting
Hollis Technology Solutions 603-321-1032
www.hollistech.com

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Alberto Moreira
Sent: Thursday, July 21, 2005 10:47 PM
To: Windows System Software Devs Interest List
Subject: Re: Re:[ntdev] Compiler version not supported by Windows DDK.

With all due respect to Hollistech and to OSR, you need zero
third party software here.

Point your IDE to the DDK compiler, setup a project for your
driver - the settings are irrelevant - setup a custom build
step that invokes build.exe (or set it up so that you can
reach it from tools/external tools, or if you’re really
fastidious set up a build button on a toolbar), and setup an
icon on your desktop to run DEVENV.EXE from inside a checked
or free build cmd
prompt: done. Takes what, five minutes work ?

Also, no driver lives alone: one often needs applications,
and it’s nice to have both projects under the same IDE
workspace so that if nothing else they can share include
files and the like.
And if you really want to pig out, you can write a ten-line
script that runs build.exe to build your driver but the full
IDE build to make the app, link it to your build button, again, done.

Use the IDE, dude.

Alberto.

----- Original Message -----
From: “Gary G. Little”
> Newsgroups: ntdev
> To: “Windows System Software Devs Interest List”
>
> Sent: Thursday, July 21, 2005 10:18 AM
> Subject: Re:[ntdev] Compiler version not supported by Windows DDK.
>
>
> > Instead of wasting time mucking around with the IDE, spend
> your time
> > developing your driver code. Get DDKBUILD either from
> > www.hollistech.com or www.osronline.com and use the IDE to create a
> > MAKEFILE project. That will work across any version of
> Visual Studio
> > including the 2005 beta 2.
> >
> > –
> > The personal opinion of
> > Gary G. Little
> >
> > “Jussi Rytilahti” wrote in message
> > news:xxxxx@ntdev…
> >> Hi,
> >>
> >> I am total newbie with drivers. I have one problem. I am reading
> >> Walter Oneys book “Programming the Microsoft Windows Driver Model,
> >> Ed2” and now I?d like to try his AppWizard for Visual C++ 6.0
> >> (WDMWIZ.AWX). I get every time same error :
> >> error C1189: #error : Compiler version not supported by
> Windows DDK.
> >> I am using DDK 2600.1106 and working OS is XP.
> >> Documentation of this wizard says that wizard is for
> VC++6.0 and XP
> >> and .NET DDKs
> >>
> >> Do I have any chances to use VC++6.0 with my DDK? (I have
> also .NET,
> >> but wizard works only in 6.0)
> >>
> >> BR.
> >> Jussi
> >>
> >>
> >
> >
> >
> > —
> > Questions? First check the Kernel Driver FAQ at
> > http://www.osronline.com/article.cfm?id=256
> >
> > You are currently subscribed to ntdev as: xxxxx@ieee.org To
> > unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as:
> xxxxx@hollistech.com To unsubscribe send a blank email to
> xxxxx@lists.osr.com
>

Hi Jussi,

Several months ago when I started to work with drivers I ran into a
similar problem. Please take all of this with a grain of salt, since
the details are fuzzy in my head, but the summary is that my paths were
incorrect / out of order when I tried to build a driver from VC6.

First the setup, I had VC6, VS.NET, and the latest DDK installed. I was
trying to work on building a driver from VC6 and got a “Compiler not
supported” error.

If I look at the C compiler from the 2003DDK, (just open a build
environment and type cl.exe), I get the following:
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 13.10.2179

If I look at the compiler from .NET, I get:
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 13.10.3077

And if I remember correctly, the compiler from VC6 is version
12…something.

So the following will fail if you use the VC6 compiler:

#if _MSC_VER < 1300
#error Compiler version not supported by Windows DDK
#endif

When you try and build from VC6, the IDE is probably finding its
compiler before it finds the DDK one, thus the preprocessor check
fails. And it will work in .NET no matter what the paths because the
.NET compiler is newer than the DDK compiler.

My solution at the time was to go back to using the Build Environment
shortcuts, then later integrate one of the ddkbuild utilities into an
IDE that I liked.

While I’m not sure if this solves any of your problems, maybe it can
give you some more insight into it.

Best Regards,
-Mike

Jussi Rytilahti wrote:

Thanks all!

I have already tested “ddkbuild”-tool and original “build” also.

@Gary:And I like this ddkbuild and I am using it in my “training project” in
.NET 2003 and it seems to work very fine.

@Alberto:Your absolutelly right with this “try+success=learn” (Or something
like that). I will test your way also.

@PeterGV: I have tried look answer from you pages but I have not successed
with this problem: Why I get this error in VC6 but not .NET and Is that
possible to try this wizard in VC6 with my DDK.

So, question is :can I even try this wizard? Becource .AWX it is only
working in VC6, but I get that error. If I take all files which wizard has
created and build them in .NET (in project which uses ddkbuild) I will
succeed…Is the only way out: Create files in vc6 with wizard and then
build them in .NET?

Jussi

“Jussi Rytilahti” kirjoitti
>viestissä:xxxxx@ntdev…
>
>
>>Hi,
>>
>>I am total newbie with drivers. I have one problem. I am reading Walter
>>Oneys book “Programming the Microsoft Windows Driver Model, Ed2” and now
>>I´d like to try his AppWizard for Visual C++ 6.0 (WDMWIZ.AWX). I get every
>>time same error : error C1189: #error : Compiler version not supported by
>>Windows DDK. I am using DDK 2600.1106 and working OS is XP. Documentation
>>of this wizard says that wizard is for VC++6.0 and XP and .NET DDKs
>>
>>Do I have any chances to use VC++6.0 with my DDK? (I have also .NET, but
>>wizard works only in 6.0)
>>
>>BR.
>>Jussi
>>
>>
>>
>>
>
>
>
>—
>Questions? First check the Kernel Driver FAQ at http://www.osronline.com/article.cfm?id=256
>
>You are currently subscribed to ntdev as: xxxxx@hologic.com
>To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
>

Ok, the details.

  1. Set up an auxiliary batch file. Call it drvbuild.bat:

call %winddk%\bin\setenv %winddk% chk wnet
devenv

Of course %winddk% is your ddkroot, say, c:\winddk\3790.1830,
and devenv.exe’s directory is in your path.

  1. Setup a link on your desktop, for properties put something
    like

“%windir%\system32\cmd /k
%yourexecutabledirectory%\drvbuild.bat”

Now every time you click on that icon you get an msvc.net shell
with all the ddk environment set up. Or, if you’re lazy, just
bring up the checked or free cmd window of your preference, type
“devenv” at the prompt and press enter.

  1. Bring up your devenv.exe. Click File/New/Project/Visual C++
    Projects. Choose “Makefile Project”.

  2. Set your path and project name, click “ok”.

  3. Click “Application Settings”.

  4. Enter your settings:

6a. Your build command line is "%windir%\bin\x86\build.
6b. Your output is whatever your driver’s name happens to
be.
6c. Your clean commands are whatever you need to wipe out
your obj files.
6d. Your rebuild command line is “%windir%\bin\x86\build -c”

Note that if you just leave these fields blank you can set them
in your Project/Properties window, which allows you to enter
multiple lines for each command: you can add debugging
information and other stuff if you feel like.

  1. Now your project’s up. Go Tools/Options/Projects/VC++
    Directories and add your %windir%\bin\x86 directory to the top
    of the executable list. That will make sure you use the DDK
    compiler and linker when you build. If you’re supersticious,
    also add %windir%\bin to the executable list.

  2. Now go Project/Properties and tweak your settings. Don’t
    forget to set them up for the Release build too. Also set your
    debugging so that if you press F5 or F10, the debugger goes
    directly to the top of your app (which, of course, you will have
    set up as another project inside the same solution!) Also, at
    this time you will want to add your own include and lib
    directories to the tools/options/projects/VC++ Directories
    lists.

  3. Add your source files to your project as you need them. Add
    your “sources” file to it too, you may need to tweak it here or
    there. Also, consider splitting parts of your driver into a
    DRIVER_LIBRARY component, it often helps.

  4. Now your environment is ready to be tested! Click on your
    “build sys” or “build solution” button, and you will get the IDE
    to build your driver using your sources, your
    makefile/makefile.inc as you feel fit, using build.exe and the
    ddk compiler and linker.

There’s a zillion variations around this theme, and you can set
yourself up with other kinds of projects too, but this one is
very, very easy: it takes about five to ten minutes work to set
yourself up.

I have also done this on occasion: build the driver once with
build.exe, fish out the log, pull out the command line into a
file, and get the shell to use the file as the source of its
command line switches and variables to the C++ compiler. Or you
can set up an utility project, that works too.

I also call your attention to what I call the “asterisk
notation” property of your sources file, where you can have
build.exe automatically insert your architecture string (such as
“i386”, “amd64”, etc.) in your directory and/or file names.
Comes in handy at times!

Alberto.

----- Original Message -----
From: “Mark Roddy”
To: “Windows System Software Devs Interest List”

Sent: Friday, July 22, 2005 7:41 AM
Subject: RE: Re:[ntdev] Compiler version not supported by
Windows DDK.

Invoking build.exe directly is insufficient as build.exe depends
on the
environment set up by the setenv.bat script that comes with the
ddk. That
script in turn requires specific command line arguments. The
appropriate
command line arguments to setenv.bat change from release to
release. The ‘10
line shell script’, done correctly is more like 100-200 lines.
Thus the
venerable ddkbuild.bat, which has managed to do this correctly
(more or
less, your mileage may vary) since 1996.

=====================
Mark Roddy DDK MVP
Windows 2003/XP/2000 Consulting
Hollis Technology Solutions 603-321-1032
www.hollistech.com

> -----Original Message-----
> From: xxxxx@lists.osr.com
> [mailto:xxxxx@lists.osr.com] On Behalf Of Alberto
> Moreira
> Sent: Thursday, July 21, 2005 10:47 PM
> To: Windows System Software Devs Interest List
> Subject: Re: Re:[ntdev] Compiler version not supported by
> Windows DDK.
>
> With all due respect to Hollistech and to OSR, you need zero
> third party software here.
>
> Point your IDE to the DDK compiler, setup a project for your
> driver - the settings are irrelevant - setup a custom build
> step that invokes build.exe (or set it up so that you can
> reach it from tools/external tools, or if you’re really
> fastidious set up a build button on a toolbar), and setup an
> icon on your desktop to run DEVENV.EXE from inside a checked
> or free build cmd
> prompt: done. Takes what, five minutes work ?
>
> Also, no driver lives alone: one often needs applications,
> and it’s nice to have both projects under the same IDE
> workspace so that if nothing else they can share include
> files and the like.
> And if you really want to pig out, you can write a ten-line
> script that runs build.exe to build your driver but the full
> IDE build to make the app, link it to your build button,
> again, done.
>
> Use the IDE, dude.
>
> Alberto.
>
>
>
> ----- Original Message -----
> From: “Gary G. Little”
> Newsgroups: ntdev
> To: “Windows System Software Devs Interest List”
>
> Sent: Thursday, July 21, 2005 10:18 AM
> Subject: Re:[ntdev] Compiler version not supported by Windows
> DDK.
>
>
> > Instead of wasting time mucking around with the IDE, spend
> your time
> > developing your driver code. Get DDKBUILD either from
> > www.hollistech.com or www.osronline.com and use the IDE to
> > create a
> > MAKEFILE project. That will work across any version of
> Visual Studio
> > including the 2005 beta 2.
> >
> > –
> > The personal opinion of
> > Gary G. Little
> >
> > “Jussi Rytilahti” wrote in
> > message
> > news:xxxxx@ntdev…
> >> Hi,
> >>
> >> I am total newbie with drivers. I have one problem. I am
> >> reading
> >> Walter Oneys book “Programming the Microsoft Windows Driver
> >> Model,
> >> Ed2” and now I´d like to try his AppWizard for Visual C++
> >> 6.0
> >> (WDMWIZ.AWX). I get every time same error :
> >> error C1189: #error : Compiler version not supported by
> Windows DDK.
> >> I am using DDK 2600.1106 and working OS is XP.
> >> Documentation of this wizard says that wizard is for
> VC++6.0 and XP
> >> and .NET DDKs
> >>
> >> Do I have any chances to use VC++6.0 with my DDK? (I have
> also .NET,
> >> but wizard works only in 6.0)
> >>
> >> BR.
> >> Jussi
> >>
> >>
> >
> >
> >
> > —
> > Questions? First check the Kernel Driver FAQ at
> > http://www.osronline.com/article.cfm?id=256
> >
> > You are currently subscribed to ntdev as: xxxxx@ieee.org
> > To
> > unsubscribe send a blank email to
> > xxxxx@lists.osr.com
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as:
> xxxxx@hollistech.com To unsubscribe send a blank email to
> xxxxx@lists.osr.com
>


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: unknown lmsubst tag
argument: ‘’
To unsubscribe send a blank email to
xxxxx@lists.osr.com

Yes of course you are right alberto. There couldn’t possibly be anything
else to it.

Have you tried that on an mp machine? Ooops, error linkage in VS won’t work.
Have you tried to get bscmake to run so that you can use source browsing? It
won’t with that ddk, it will with ddkbuild which happens to know about the
undocumented command line argument for turning bscmake support back on.
There is a reason why ddkbuild has been out there for almost 10 years. Is
there some reason why you seem to think it is the wrong way to go?

=====================
Mark Roddy DDK MVP
Windows 2003/XP/2000 Consulting
Hollis Technology Solutions 603-321-1032
www.hollistech.com

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Alberto Moreira
Sent: Friday, July 22, 2005 11:05 PM
To: Windows System Software Devs Interest List
Subject: Re: Re:[ntdev] Compiler version not supported by Windows DDK.

Ok, the details.

  1. Set up an auxiliary batch file. Call it drvbuild.bat:

call %winddk%\bin\setenv %winddk% chk wnet
devenv

Of course %winddk% is your ddkroot, say, c:\winddk\3790.1830,
and devenv.exe’s directory is in your path.

  1. Setup a link on your desktop, for properties put something like

“%windir%\system32\cmd /k
%yourexecutabledirectory%\drvbuild.bat”

Now every time you click on that icon you get an msvc.net
shell with all the ddk environment set up. Or, if you’re
lazy, just bring up the checked or free cmd window of your
preference, type “devenv” at the prompt and press enter.

  1. Bring up your devenv.exe. Click File/New/Project/Visual
    C++ Projects. Choose “Makefile Project”.

  2. Set your path and project name, click “ok”.

  3. Click “Application Settings”.

  4. Enter your settings:

6a. Your build command line is "%windir%\bin\x86\build.
6b. Your output is whatever your driver’s name happens to be.
6c. Your clean commands are whatever you need to wipe out
your obj files.
6d. Your rebuild command line is “%windir%\bin\x86\build -c”

Note that if you just leave these fields blank you can set
them in your Project/Properties window, which allows you to
enter multiple lines for each command: you can add debugging
information and other stuff if you feel like.

  1. Now your project’s up. Go Tools/Options/Projects/VC++
    Directories and add your %windir%\bin\x86 directory to the
    top of the executable list. That will make sure you use the
    DDK compiler and linker when you build. If you’re
    supersticious, also add %windir%\bin to the executable list.

  2. Now go Project/Properties and tweak your settings. Don’t
    forget to set them up for the Release build too. Also set
    your debugging so that if you press F5 or F10, the debugger
    goes directly to the top of your app (which, of course, you
    will have set up as another project inside the same
    solution!) Also, at this time you will want to add your own
    include and lib directories to the
    tools/options/projects/VC++ Directories lists.

  3. Add your source files to your project as you need them.
    Add your “sources” file to it too, you may need to tweak it
    here or there. Also, consider splitting parts of your driver
    into a DRIVER_LIBRARY component, it often helps.

  4. Now your environment is ready to be tested! Click on your
    “build sys” or “build solution” button, and you will get the
    IDE to build your driver using your sources, your
    makefile/makefile.inc as you feel fit, using build.exe and
    the ddk compiler and linker.

There’s a zillion variations around this theme, and you can
set yourself up with other kinds of projects too, but this
one is very, very easy: it takes about five to ten minutes
work to set yourself up.

I have also done this on occasion: build the driver once with
build.exe, fish out the log, pull out the command line into a
file, and get the shell to use the file as the source of its
command line switches and variables to the C++ compiler. Or
you can set up an utility project, that works too.

I also call your attention to what I call the “asterisk
notation” property of your sources file, where you can have
build.exe automatically insert your architecture string (such
as “i386”, “amd64”, etc.) in your directory and/or file names.
Comes in handy at times!

Alberto.

----- Original Message -----
From: “Mark Roddy”
> To: “Windows System Software Devs Interest List”
>
> Sent: Friday, July 22, 2005 7:41 AM
> Subject: RE: Re:[ntdev] Compiler version not supported by Windows DDK.
>
>
> Invoking build.exe directly is insufficient as build.exe
> depends on the environment set up by the setenv.bat script
> that comes with the ddk. That script in turn requires
> specific command line arguments. The appropriate command line
> arguments to setenv.bat change from release to release. The
> ‘10 line shell script’, done correctly is more like 100-200 lines.
> Thus the
> venerable ddkbuild.bat, which has managed to do this
> correctly (more or less, your mileage may vary) since 1996.
>
> =====================
> Mark Roddy DDK MVP
> Windows 2003/XP/2000 Consulting
> Hollis Technology Solutions 603-321-1032 www.hollistech.com
>
> > -----Original Message-----
> > From: xxxxx@lists.osr.com
> > [mailto:xxxxx@lists.osr.com] On Behalf Of
> Alberto Moreira
> > Sent: Thursday, July 21, 2005 10:47 PM
> > To: Windows System Software Devs Interest List
> > Subject: Re: Re:[ntdev] Compiler version not supported by
> Windows DDK.
> >
> > With all due respect to Hollistech and to OSR, you need zero third
> > party software here.
> >
> > Point your IDE to the DDK compiler, setup a project for
> your driver -
> > the settings are irrelevant - setup a custom build step
> that invokes
> > build.exe (or set it up so that you can reach it from
> tools/external
> > tools, or if you’re really fastidious set up a build button on a
> > toolbar), and setup an icon on your desktop to run DEVENV.EXE from
> > inside a checked or free build cmd
> > prompt: done. Takes what, five minutes work ?
> >
> > Also, no driver lives alone: one often needs applications, and it’s
> > nice to have both projects under the same IDE workspace so that if
> > nothing else they can share include files and the like.
> > And if you really want to pig out, you can write a ten-line script
> > that runs build.exe to build your driver but the full IDE build to
> > make the app, link it to your build button, again, done.
> >
> > Use the IDE, dude.
> >
> > Alberto.
> >
> >
> >
> > ----- Original Message -----
> > From: “Gary G. Little”
> > Newsgroups: ntdev
> > To: “Windows System Software Devs Interest List”
> >
> > Sent: Thursday, July 21, 2005 10:18 AM
> > Subject: Re:[ntdev] Compiler version not supported by Windows DDK.
> >
> >
> > > Instead of wasting time mucking around with the IDE, spend
> > your time
> > > developing your driver code. Get DDKBUILD either from
> > > www.hollistech.com or www.osronline.com and use the IDE
> to create a
> > > MAKEFILE project. That will work across any version of
> > Visual Studio
> > > including the 2005 beta 2.
> > >
> > > –
> > > The personal opinion of
> > > Gary G. Little
> > >
> > > “Jussi Rytilahti” wrote in message
> > > news:xxxxx@ntdev…
> > >> Hi,
> > >>
> > >> I am total newbie with drivers. I have one problem. I am reading
> > >> Walter Oneys book “Programming the Microsoft Windows
> Driver Model,
> > >> Ed2” and now I?d like to try his AppWizard for Visual C++ 6.0
> > >> (WDMWIZ.AWX). I get every time same error :
> > >> error C1189: #error : Compiler version not supported by
> > Windows DDK.
> > >> I am using DDK 2600.1106 and working OS is XP.
> > >> Documentation of this wizard says that wizard is for
> > VC++6.0 and XP
> > >> and .NET DDKs
> > >>
> > >> Do I have any chances to use VC++6.0 with my DDK? (I have
> > also .NET,
> > >> but wizard works only in 6.0)
> > >>
> > >> BR.
> > >> Jussi
> > >>
> > >>
> > >
> > >
> > >
> > > —
> > > Questions? First check the Kernel Driver FAQ at
> > > http://www.osronline.com/article.cfm?id=256
> > >
> > > You are currently subscribed to ntdev as: xxxxx@ieee.org To
> > > unsubscribe send a blank email to xxxxx@lists.osr.com
> >
> >
> > —
> > Questions? First check the Kernel Driver FAQ at
> > http://www.osronline.com/article.cfm?id=256
> >
> > You are currently subscribed to ntdev as:
> > xxxxx@hollistech.com To unsubscribe send a blank email to
> > xxxxx@lists.osr.com
> >
>
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: unknown lmsubst tag
> argument: ‘’
> To unsubscribe send a blank email to
> xxxxx@lists.osr.com
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as:
> xxxxx@hollistech.com To unsubscribe send a blank email to
> xxxxx@lists.osr.com
>

Why people are spending this much time in building serious projects from
IDE?
Why not type BUILD and forget all these annoyances?

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com

----- Original Message -----
From: “Michael Becker”
To: “Windows System Software Devs Interest List”
Sent: Friday, July 22, 2005 10:19 PM
Subject: Re: [ntdev] Compiler version not supported by Windows DDK.

> Hi Jussi,
>
> Several months ago when I started to work with drivers I ran into a
> similar problem. Please take all of this with a grain of salt, since
> the details are fuzzy in my head, but the summary is that my paths were
> incorrect / out of order when I tried to build a driver from VC6.
>
> First the setup, I had VC6, VS.NET, and the latest DDK installed. I was
> trying to work on building a driver from VC6 and got a “Compiler not
> supported” error.
>
> If I look at the C compiler from the 2003DDK, (just open a build
> environment and type cl.exe), I get the following:
> Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 13.10.2179
>
> If I look at the compiler from .NET, I get:
> Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 13.10.3077
>
> And if I remember correctly, the compiler from VC6 is version
> 12…something.
>
> So the following will fail if you use the VC6 compiler:
>
> #if _MSC_VER < 1300
> #error Compiler version not supported by Windows DDK
> #endif
>
>
> When you try and build from VC6, the IDE is probably finding its
> compiler before it finds the DDK one, thus the preprocessor check
> fails. And it will work in .NET no matter what the paths because the
> .NET compiler is newer than the DDK compiler.
>
> My solution at the time was to go back to using the Build Environment
> shortcuts, then later integrate one of the ddkbuild utilities into an
> IDE that I liked.
>
> While I’m not sure if this solves any of your problems, maybe it can
> give you some more insight into it.
>
> Best Regards,
> -Mike
>
>
>
> Jussi Rytilahti wrote:
>
> >Thanks all!
> >
> >I have already tested “ddkbuild”-tool and original “build” also.
> >
> >@Gary:And I like this ddkbuild and I am using it in my “training project” in
> >.NET 2003 and it seems to work very fine.
> >
> >@Alberto:Your absolutelly right with this “try+success=learn” (Or something
> >like that). I will test your way also.
> >
> >@PeterGV: I have tried look answer from you pages but I have not successed
> >with this problem: Why I get this error in VC6 but not .NET and Is that
> >possible to try this wizard in VC6 with my DDK.
> >
> >So, question is :can I even try this wizard? Becource .AWX it is only
> >working in VC6, but I get that error. If I take all files which wizard has
> >created and build them in .NET (in project which uses ddkbuild) I will
> >succeed…Is the only way out: Create files in vc6 with wizard and then
> >build them in .NET?
> >
> >Jussi
> >
> >“Jussi Rytilahti” kirjoitti
> >viestissä:xxxxx@ntdev…
> >
> >
> >>Hi,
> >>
> >>I am total newbie with drivers. I have one problem. I am reading Walter
> >>Oneys book “Programming the Microsoft Windows Driver Model, Ed2” and now
> >>I´d like to try his AppWizard for Visual C++ 6.0 (WDMWIZ.AWX). I get every
> >>time same error : error C1189: #error : Compiler version not supported by
> >>Windows DDK. I am using DDK 2600.1106 and working OS is XP. Documentation
> >>of this wizard says that wizard is for VC++6.0 and XP and .NET DDKs
> >>
> >>Do I have any chances to use VC++6.0 with my DDK? (I have also .NET, but
> >>wizard works only in 6.0)
> >>
> >>BR.
> >>Jussi
> >>
> >>
> >>
> >>
> >
> >
> >
> >—
> >Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256
> >
> >You are currently subscribed to ntdev as: xxxxx@hologic.com
> >To unsubscribe send a blank email to xxxxx@lists.osr.com
> >
> >
> >
>
> —
> Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: xxxxx@storagecraft.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com

Mark,

Mark, I’m not criticizing ddkbuild! It’s obviously a nice piece
of software, because lots of people use it and are happy with
it.

I’m just saying that VS.NET brings in new features that make
things easy if they’re well used. And I’m also making the point
that it is perfectly possible to use the VS.NET IDE and still do
it so that what really happens is precisely the same that
happens when you run from a CMD box: you set up your sources
file, make your makefile point to makefile.def, run build.exe to
cause compiling and linking to be done with the DDK tools.
VS.NET ends up doing exactly the same thing we do on the command
line, but it adds the wealth of choices and nice features of the
IDE.

My machine at work is an SMP and this stuff works, remember, I’m
using build.exe and the DDK compiler and linker just like
everyone else. I’m still running build.exe on a cmd box to cause
the DDK compiler and linker to build my drivers, the only
difference is that I set up VS.NET between myself and the cmd
box so that I never have to type commands into the box: I use
the IDE instead and if bad comes to worse I can always resort to
the command window. VS.NET has extensive source browsing, I just
tried it on one of my Makefile Projects and it seems to work
fine, and I can use Whole Tomato on top of it.

Actually, in that line, there’s something I don’t quite
understand. I have looked at the C compiler versions for the
DDKs and IDEs I have installed in my machine at home, and this
is what I found:

DDK 2260: CL Version 13.00.9176
VC7 2002: CL Version 13.00.9466
VC7 2003: CL Version 13.10.3077
DDK 3790.1830: CL Version 13.10.4035

I don’t have VC7 2005 installed nor do I use the other DDKs, so,
I couldn’t check their compiler versions. Now, about “old
compilers”, note that DDK 2260 uses a 13.00 compiler, which I
must believe is older than the 13.10.3077 compiler used in VC7
2003. My naive conclusion is that anything that compiles fine
under 13.00.9176 should compile fine under 13.10.3077, no ? Now,
one could argue that the 13.10.4035 compiler that ships with the
current Win2k3 SP1 DDK is newer than the VC7 2003 compiler, but
I may bet that VC7 2005 ships with a compiler that’s even newer
than the 13.10.4035 version. Which will mean that there should
be no problem using VS.NET 2005 to compile and link drivers.
Unless of course Microsoft’s compiler group generates special
compilers and linkers with special features to make driver
builds work, but do they really do that ? It doesn’t quite make
sense from a compiler writing standpoint, nor does it make much
business sense to allow such a small target market such as
driver writing demand special compiler features that could
easily be avoided by taking a little bit more care in specifying
one’s APIs and libraries. But hey, anything’s possible.

In fact, I found through personal experience that the correct
compiler/linker/lib pairing is way more important than the
compiler level, but hey, I could be wrong because most of the
drivers I worked with were either display/graphics/3D drivers or
down-at-the-machine-level stuff such as BoundsChecker and
TrueCoverage, and those aren’t quite your off-the-shelf WDM
drivers that a lot of ntdev posters write for a living.

Last but not least, again, I’m not criticizing ddkbuild! A lot
of people use it and they’re happy with it, so, it must be a
good tool. All I’m saying is that phrases such as “you must use
the ddk compiler” or “if you don’t use build.exe you insert
subtle errors” are no excuse for not using the IDE. Also, I make
a point of trying to never criticize a colleague’s software, so,
forgive me if I gave you that impression - and I apologize to
you if that’s what happened!

Alberto.

----- Original Message -----
From: “Mark Roddy”
To: “Windows System Software Devs Interest List”

Sent: Saturday, July 23, 2005 10:12 PM
Subject: RE: Re:[ntdev] Compiler version not supported by
Windows DDK.

Yes of course you are right alberto. There couldn’t possibly be
anything
else to it.

Have you tried that on an mp machine? Ooops, error linkage in VS
won’t work.
Have you tried to get bscmake to run so that you can use source
browsing? It
won’t with that ddk, it will with ddkbuild which happens to know
about the
undocumented command line argument for turning bscmake support
back on.
There is a reason why ddkbuild has been out there for almost 10
years. Is
there some reason why you seem to think it is the wrong way to
go?

=====================
Mark Roddy DDK MVP
Windows 2003/XP/2000 Consulting
Hollis Technology Solutions 603-321-1032
www.hollistech.com

> -----Original Message-----
> From: xxxxx@lists.osr.com
> [mailto:xxxxx@lists.osr.com] On Behalf Of Alberto
> Moreira
> Sent: Friday, July 22, 2005 11:05 PM
> To: Windows System Software Devs Interest List
> Subject: Re: Re:[ntdev] Compiler version not supported by
> Windows DDK.
>
> Ok, the details.
>
> 1. Set up an auxiliary batch file. Call it drvbuild.bat:
>
> call %winddk%\bin\setenv %winddk% chk wnet
> devenv
>
> Of course %winddk% is your ddkroot, say, c:\winddk\3790.1830,
> and devenv.exe’s directory is in your path.
>
> 2. Setup a link on your desktop, for properties put something
> like
>
> “%windir%\system32\cmd /k
> %yourexecutabledirectory%\drvbuild.bat”
>
> Now every time you click on that icon you get an msvc.net
> shell with all the ddk environment set up. Or, if you’re
> lazy, just bring up the checked or free cmd window of your
> preference, type “devenv” at the prompt and press enter.
>
> 3. Bring up your devenv.exe. Click File/New/Project/Visual
> C++ Projects. Choose “Makefile Project”.
>
> 4. Set your path and project name, click “ok”.
>
> 5. Click “Application Settings”.
>
> 6. Enter your settings:
>
> 6a. Your build command line is "%windir%\bin\x86\build.
> 6b. Your output is whatever your driver’s name happens to
> be.
> 6c. Your clean commands are whatever you need to wipe out
> your obj files.
> 6d. Your rebuild command line is
> “%windir%\bin\x86\build -c”
>
> Note that if you just leave these fields blank you can set
> them in your Project/Properties window, which allows you to
> enter multiple lines for each command: you can add debugging
> information and other stuff if you feel like.
>
> 7. Now your project’s up. Go Tools/Options/Projects/VC++
> Directories and add your %windir%\bin\x86 directory to the
> top of the executable list. That will make sure you use the
> DDK compiler and linker when you build. If you’re
> supersticious, also add %windir%\bin to the executable list.
>
> 8. Now go Project/Properties and tweak your settings. Don’t
> forget to set them up for the Release build too. Also set
> your debugging so that if you press F5 or F10, the debugger
> goes directly to the top of your app (which, of course, you
> will have set up as another project inside the same
> solution!) Also, at this time you will want to add your own
> include and lib directories to the
> tools/options/projects/VC++ Directories lists.
>
> 9. Add your source files to your project as you need them.
> Add your “sources” file to it too, you may need to tweak it
> here or there. Also, consider splitting parts of your driver
> into a DRIVER_LIBRARY component, it often helps.
>
> 10. Now your environment is ready to be tested! Click on your
> “build sys” or “build solution” button, and you will get the
> IDE to build your driver using your sources, your
> makefile/makefile.inc as you feel fit, using build.exe and
> the ddk compiler and linker.
>
> There’s a zillion variations around this theme, and you can
> set yourself up with other kinds of projects too, but this
> one is very, very easy: it takes about five to ten minutes
> work to set yourself up.
>
> I have also done this on occasion: build the driver once with
> build.exe, fish out the log, pull out the command line into a
> file, and get the shell to use the file as the source of its
> command line switches and variables to the C++ compiler. Or
> you can set up an utility project, that works too.
>
> I also call your attention to what I call the “asterisk
> notation” property of your sources file, where you can have
> build.exe automatically insert your architecture string (such
> as “i386”, “amd64”, etc.) in your directory and/or file names.
> Comes in handy at times!
>
> Alberto.
>
>
>
>
>
> ----- Original Message -----
> From: “Mark Roddy”
> To: “Windows System Software Devs Interest List”
>
> Sent: Friday, July 22, 2005 7:41 AM
> Subject: RE: Re:[ntdev] Compiler version not supported by
> Windows DDK.
>
>
> Invoking build.exe directly is insufficient as build.exe
> depends on the environment set up by the setenv.bat script
> that comes with the ddk. That script in turn requires
> specific command line arguments. The appropriate command line
> arguments to setenv.bat change from release to release. The
> ‘10 line shell script’, done correctly is more like 100-200
> lines.
> Thus the
> venerable ddkbuild.bat, which has managed to do this
> correctly (more or less, your mileage may vary) since 1996.
>
> =====================
> Mark Roddy DDK MVP
> Windows 2003/XP/2000 Consulting
> Hollis Technology Solutions 603-321-1032 www.hollistech.com
>
> > -----Original Message-----
> > From: xxxxx@lists.osr.com
> > [mailto:xxxxx@lists.osr.com] On Behalf Of
> Alberto Moreira
> > Sent: Thursday, July 21, 2005 10:47 PM
> > To: Windows System Software Devs Interest List
> > Subject: Re: Re:[ntdev] Compiler version not supported by
> Windows DDK.
> >
> > With all due respect to Hollistech and to OSR, you need zero
> > third
> > party software here.
> >
> > Point your IDE to the DDK compiler, setup a project for
> your driver -
> > the settings are irrelevant - setup a custom build step
> that invokes
> > build.exe (or set it up so that you can reach it from
> tools/external
> > tools, or if you’re really fastidious set up a build button
> > on a
> > toolbar), and setup an icon on your desktop to run
> > DEVENV.EXE from
> > inside a checked or free build cmd
> > prompt: done. Takes what, five minutes work ?
> >
> > Also, no driver lives alone: one often needs applications,
> > and it’s
> > nice to have both projects under the same IDE workspace so
> > that if
> > nothing else they can share include files and the like.
> > And if you really want to pig out, you can write a ten-line
> > script
> > that runs build.exe to build your driver but the full IDE
> > build to
> > make the app, link it to your build button, again, done.
> >
> > Use the IDE, dude.
> >
> > Alberto.
> >
> >
> >
> > ----- Original Message -----
> > From: “Gary G. Little”
> > Newsgroups: ntdev
> > To: “Windows System Software Devs Interest List”
> >
> > Sent: Thursday, July 21, 2005 10:18 AM
> > Subject: Re:[ntdev] Compiler version not supported by
> > Windows DDK.
> >
> >
> > > Instead of wasting time mucking around with the IDE, spend
> > your time
> > > developing your driver code. Get DDKBUILD either from
> > > www.hollistech.com or www.osronline.com and use the IDE
> to create a
> > > MAKEFILE project. That will work across any version of
> > Visual Studio
> > > including the 2005 beta 2.
> > >
> > > –
> > > The personal opinion of
> > > Gary G. Little
> > >
> > > “Jussi Rytilahti” wrote in
> > > message
> > > news:xxxxx@ntdev…
> > >> Hi,
> > >>
> > >> I am total newbie with drivers. I have one problem. I am
> > >> reading
> > >> Walter Oneys book “Programming the Microsoft Windows
> Driver Model,
> > >> Ed2” and now I´d like to try his AppWizard for Visual C++
> > >> 6.0
> > >> (WDMWIZ.AWX). I get every time same error :
> > >> error C1189: #error : Compiler version not supported by
> > Windows DDK.
> > >> I am using DDK 2600.1106 and working OS is XP.
> > >> Documentation of this wizard says that wizard is for
> > VC++6.0 and XP
> > >> and .NET DDKs
> > >>
> > >> Do I have any chances to use VC++6.0 with my DDK? (I have
> > also .NET,
> > >> but wizard works only in 6.0)
> > >>
> > >> BR.
> > >> Jussi
> > >>
> > >>
> > >
> > >
> > >
> > > —
> > > Questions? First check the Kernel Driver FAQ at
> > > http://www.osronline.com/article.cfm?id=256
> > >
> > > You are currently subscribed to ntdev as:
> > > xxxxx@ieee.org To
> > > unsubscribe send a blank email to
> > > xxxxx@lists.osr.com
> >
> >
> > —
> > Questions? First check the Kernel Driver FAQ at
> > http://www.osronline.com/article.cfm?id=256
> >
> > You are currently subscribed to ntdev as:
> > xxxxx@hollistech.com To unsubscribe send a blank email to
> > xxxxx@lists.osr.com
> >
>
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: unknown lmsubst tag
> argument: ‘’
> To unsubscribe send a blank email to
> xxxxx@lists.osr.com
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as:
> xxxxx@hollistech.com To unsubscribe send a blank email to
> xxxxx@lists.osr.com
>


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: unknown lmsubst tag
argument: ‘’
To unsubscribe send a blank email to
xxxxx@lists.osr.com

Takes longer than clicking on the build button. :slight_smile:

Alberto.

----- Original Message -----
From: “Maxim S. Shatskih”
To: “Windows System Software Devs Interest List”

Sent: Sunday, July 24, 2005 11:29 AM
Subject: Re: [ntdev] Compiler version not supported by Windows
DDK.

> Why people are spending this much time in building serious
> projects from
> IDE?
> Why not type BUILD and forget all these annoyances?
>
> Maxim Shatskih, Windows DDK MVP
> StorageCraft Corporation
> xxxxx@storagecraft.com
> http://www.storagecraft.com
>
> ----- Original Message -----
> From: “Michael Becker”
> To: “Windows System Software Devs Interest List”
>
> Sent: Friday, July 22, 2005 10:19 PM
> Subject: Re: [ntdev] Compiler version not supported by Windows
> DDK.
>
>
>> Hi Jussi,
>>
>> Several months ago when I started to work with drivers I ran
>> into a
>> similar problem. Please take all of this with a grain of
>> salt, since
>> the details are fuzzy in my head, but the summary is that my
>> paths were
>> incorrect / out of order when I tried to build a driver from
>> VC6.
>>
>> First the setup, I had VC6, VS.NET, and the latest DDK
>> installed. I was
>> trying to work on building a driver from VC6 and got a
>> “Compiler not
>> supported” error.
>>
>> If I look at the C compiler from the 2003DDK, (just open a
>> build
>> environment and type cl.exe), I get the following:
>> Microsoft (R) 32-bit C/C++ Optimizing Compiler Version
>> 13.10.2179
>>
>> If I look at the compiler from .NET, I get:
>> Microsoft (R) 32-bit C/C++ Optimizing Compiler Version
>> 13.10.3077
>>
>> And if I remember correctly, the compiler from VC6 is version
>> 12…something.
>>
>> So the following will fail if you use the VC6 compiler:
>>
>> #if _MSC_VER < 1300
>> #error Compiler version not supported by Windows DDK
>> #endif
>>
>>
>> When you try and build from VC6, the IDE is probably finding
>> its
>> compiler before it finds the DDK one, thus the preprocessor
>> check
>> fails. And it will work in .NET no matter what the paths
>> because the
>> .NET compiler is newer than the DDK compiler.
>>
>> My solution at the time was to go back to using the Build
>> Environment
>> shortcuts, then later integrate one of the ddkbuild utilities
>> into an
>> IDE that I liked.
>>
>> While I’m not sure if this solves any of your problems, maybe
>> it can
>> give you some more insight into it.
>>
>> Best Regards,
>> -Mike
>>
>>
>>
>> Jussi Rytilahti wrote:
>>
>> >Thanks all!
>> >
>> >I have already tested “ddkbuild”-tool and original “build”
>> >also.
>> >
>> >@Gary:And I like this ddkbuild and I am using it in my
>> >“training project” in
>> >.NET 2003 and it seems to work very fine.
>> >
>> >@Alberto:Your absolutelly right with this
>> >“try+success=learn” (Or something
>> >like that). I will test your way also.
>> >
>> >@PeterGV: I have tried look answer from you pages but I have
>> >not successed
>> >with this problem: Why I get this error in VC6 but not .NET
>> >and Is that
>> >possible to try this wizard in VC6 with my DDK.
>> >
>> >So, question is :can I even try this wizard? Becource .AWX
>> >it is only
>> >working in VC6, but I get that error. If I take all files
>> >which wizard has
>> >created and build them in .NET (in project which uses
>> >ddkbuild) I will
>> >succeed…Is the only way out: Create files in vc6 with
>> >wizard and then
>> >build them in .NET?
>> >
>> >Jussi
>> >
>> >“Jussi Rytilahti” kirjoitti
>> >viestissä:xxxxx@ntdev…
>> >
>> >
>> >>Hi,
>> >>
>> >>I am total newbie with drivers. I have one problem. I am
>> >>reading Walter
>> >>Oneys book “Programming the Microsoft Windows Driver Model,
>> >>Ed2” and now
>> >>I´d like to try his AppWizard for Visual C++ 6.0
>> >>(WDMWIZ.AWX). I get every
>> >>time same error : error C1189: #error : Compiler version
>> >>not supported by
>> >>Windows DDK. I am using DDK 2600.1106 and working OS is XP.
>> >>Documentation
>> >>of this wizard says that wizard is for VC++6.0 and XP and
>> >>.NET DDKs
>> >>
>> >>Do I have any chances to use VC++6.0 with my DDK? (I have
>> >>also .NET, but
>> >>wizard works only in 6.0)
>> >>
>> >>BR.
>> >>Jussi
>> >>
>> >>
>> >>
>> >>
>> >
>> >
>> >
>> >—
>> >Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>> >
>> >You are currently subscribed to ntdev as:
>> >xxxxx@hologic.com
>> >To unsubscribe send a blank email to
>> >xxxxx@lists.osr.com
>> >
>> >
>> >
>>
>> —
>> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>>
>> You are currently subscribed to ntdev as:
>> xxxxx@storagecraft.com
>> To unsubscribe send a blank email to
>> xxxxx@lists.osr.com
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: xxxxx@ieee.org
> To unsubscribe send a blank email to
> xxxxx@lists.osr.com

“Alberto Moreira” wrote in message news:xxxxx@ntdev…

> Unless of course Microsoft’s compiler group generates special compilers
> and linkers with special features to make driver builds work, but do they
> really do that ? It doesn’t quite make sense from a compiler writing
> standpoint, nor does it make much business sense to allow such a small
> target market such as driver writing demand special compiler features that
> could easily be avoided by taking a little bit more care in specifying
> one’s APIs and libraries. But hey, anything’s possible.
>
Not just driver builds. The entire core OS for Windows is built with that
compiler according to what I understood from PlugFest and others. Microsoft
makes that compiler not for us, but for themselves so that is a completely
different motivation than just a almost free driver kit. Since the DDK also
includes compiler libraries, this also ensures that you are using the same
libraries that the OS uses. It also allows them to fix bugs for the libs
that shipped with a down-level OS’s DDK.

I used to do my own build environment to permit me to write VxDs, NT
drivers, DOS utilities, and libraries for use by all the above. Mark’s is
much easier, but I don’t have the same control. I also avoid the constant
maintenance by using his. It works well and with the use of Visual Studio
.NET 2003 and the batch build capability I can do a driver for the various
CPUs and the application in both checked and free with one (or three)
clicks. I taught a class at work in the use of DDKBUILD for doing PreFast
and CUV in that environment. It also included using a code coverage tool
too.

Well, longer only a bit, and issues with building from VS.NET takes people
days to solve.

Building drivers from VS.NET is not supported by Microsoft. Period. The
rest are on-the-knee made things.

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com

----- Original Message -----
From: “Alberto Moreira”
To: “Windows System Software Devs Interest List”
Sent: Sunday, July 24, 2005 8:01 PM
Subject: Re: [ntdev] Compiler version not supported by Windows DDK.

> Takes longer than clicking on the build button. :slight_smile:
>
> Alberto.
>
>
> ----- Original Message -----
> From: “Maxim S. Shatskih”
> To: “Windows System Software Devs Interest List”
>
> Sent: Sunday, July 24, 2005 11:29 AM
> Subject: Re: [ntdev] Compiler version not supported by Windows
> DDK.
>
>
> > Why people are spending this much time in building serious
> > projects from
> > IDE?
> > Why not type BUILD and forget all these annoyances?
> >
> > Maxim Shatskih, Windows DDK MVP
> > StorageCraft Corporation
> > xxxxx@storagecraft.com
> > http://www.storagecraft.com
> >
> > ----- Original Message -----
> > From: “Michael Becker”
> > To: “Windows System Software Devs Interest List”
> >
> > Sent: Friday, July 22, 2005 10:19 PM
> > Subject: Re: [ntdev] Compiler version not supported by Windows
> > DDK.
> >
> >
> >> Hi Jussi,
> >>
> >> Several months ago when I started to work with drivers I ran
> >> into a
> >> similar problem. Please take all of this with a grain of
> >> salt, since
> >> the details are fuzzy in my head, but the summary is that my
> >> paths were
> >> incorrect / out of order when I tried to build a driver from
> >> VC6.
> >>
> >> First the setup, I had VC6, VS.NET, and the latest DDK
> >> installed. I was
> >> trying to work on building a driver from VC6 and got a
> >> “Compiler not
> >> supported” error.
> >>
> >> If I look at the C compiler from the 2003DDK, (just open a
> >> build
> >> environment and type cl.exe), I get the following:
> >> Microsoft (R) 32-bit C/C++ Optimizing Compiler Version
> >> 13.10.2179
> >>
> >> If I look at the compiler from .NET, I get:
> >> Microsoft (R) 32-bit C/C++ Optimizing Compiler Version
> >> 13.10.3077
> >>
> >> And if I remember correctly, the compiler from VC6 is version
> >> 12…something.
> >>
> >> So the following will fail if you use the VC6 compiler:
> >>
> >> #if _MSC_VER < 1300
> >> #error Compiler version not supported by Windows DDK
> >> #endif
> >>
> >>
> >> When you try and build from VC6, the IDE is probably finding
> >> its
> >> compiler before it finds the DDK one, thus the preprocessor
> >> check
> >> fails. And it will work in .NET no matter what the paths
> >> because the
> >> .NET compiler is newer than the DDK compiler.
> >>
> >> My solution at the time was to go back to using the Build
> >> Environment
> >> shortcuts, then later integrate one of the ddkbuild utilities
> >> into an
> >> IDE that I liked.
> >>
> >> While I’m not sure if this solves any of your problems, maybe
> >> it can
> >> give you some more insight into it.
> >>
> >> Best Regards,
> >> -Mike
> >>
> >>
> >>
> >> Jussi Rytilahti wrote:
> >>
> >> >Thanks all!
> >> >
> >> >I have already tested “ddkbuild”-tool and original “build”
> >> >also.
> >> >
> >> >@Gary:And I like this ddkbuild and I am using it in my
> >> >“training project” in
> >> >.NET 2003 and it seems to work very fine.
> >> >
> >> >@Alberto:Your absolutelly right with this
> >> >“try+success=learn” (Or something
> >> >like that). I will test your way also.
> >> >
> >> >@PeterGV: I have tried look answer from you pages but I have
> >> >not successed
> >> >with this problem: Why I get this error in VC6 but not .NET
> >> >and Is that
> >> >possible to try this wizard in VC6 with my DDK.
> >> >
> >> >So, question is :can I even try this wizard? Becource .AWX
> >> >it is only
> >> >working in VC6, but I get that error. If I take all files
> >> >which wizard has
> >> >created and build them in .NET (in project which uses
> >> >ddkbuild) I will
> >> >succeed…Is the only way out: Create files in vc6 with
> >> >wizard and then
> >> >build them in .NET?
> >> >
> >> >Jussi
> >> >
> >> >“Jussi Rytilahti” kirjoitti
> >> >viestissä:xxxxx@ntdev…
> >> >
> >> >
> >> >>Hi,
> >> >>
> >> >>I am total newbie with drivers. I have one problem. I am
> >> >>reading Walter
> >> >>Oneys book “Programming the Microsoft Windows Driver Model,
> >> >>Ed2” and now
> >> >>I´d like to try his AppWizard for Visual C++ 6.0
> >> >>(WDMWIZ.AWX). I get every
> >> >>time same error : error C1189: #error : Compiler version
> >> >>not supported by
> >> >>Windows DDK. I am using DDK 2600.1106 and working OS is XP.
> >> >>Documentation
> >> >>of this wizard says that wizard is for VC++6.0 and XP and
> >> >>.NET DDKs
> >> >>
> >> >>Do I have any chances to use VC++6.0 with my DDK? (I have
> >> >>also .NET, but
> >> >>wizard works only in 6.0)
> >> >>
> >> >>BR.
> >> >>Jussi
> >> >>
> >> >>
> >> >>
> >> >>
> >> >
> >> >
> >> >
> >> >—
> >> >Questions? First check the Kernel Driver FAQ at
> > http://www.osronline.com/article.cfm?id=256
> >> >
> >> >You are currently subscribed to ntdev as:
> >> >xxxxx@hologic.com
> >> >To unsubscribe send a blank email to
> >> >xxxxx@lists.osr.com
> >> >
> >> >
> >> >
> >>
> >> —
> >> Questions? First check the Kernel Driver FAQ at
> > http://www.osronline.com/article.cfm?id=256
> >>
> >> You are currently subscribed to ntdev as:
> >> xxxxx@storagecraft.com
> >> To unsubscribe send a blank email to
> >> xxxxx@lists.osr.com
> >
> >
> > —
> > Questions? First check the Kernel Driver FAQ at
> > http://www.osronline.com/article.cfm?id=256
> >
> > You are currently subscribed to ntdev as: xxxxx@ieee.org
> > To unsubscribe send a blank email to
> > xxxxx@lists.osr.com
>
>
> —
> Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: xxxxx@storagecraft.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com

I don’t know about everyone else, but I started with the VC6 IDE
because there was a lot of reference to it in the book, “Programming
the Windows Driver Model”, so being new I attempted to repeat what was
done there first before venturing into uncharted waters.

Soon after that, I found I personally prefer build.exe at a command
line.  Sometimes I may add a button or two to an IDE which ties into
build.exe via ddkbuild.bat, but only because I can follow what ddkbuild
does.

But let me emphasis the word personally.  IDE vs. CLI seems to be one
of those preferences that border on a religion (like what’s the correct
way to put braces in an if statement).  I see pros and cons to both, it
just depends on what you are more comfortable with.  What I think is
more important than IDE / CLI is repeatability, that no matter what you
use, you use the same thing the same way every time.

Just my opinion,

-Mike

Maxim S. Shatskih wrote:

Why people are spending this much time in building serious projects from
IDE?
Why not type BUILD and forget all these annoyances?

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com

----- Original Message -----
From: “Michael Becker”
To: “Windows System Software Devs Interest List”
Sent: Friday, July 22, 2005 10:19 PM
Subject: Re: [ntdev] Compiler version not supported by Windows DDK.

Hi Jussi,

Several months ago when I started to work with drivers I ran into a
similar problem. Please take all of this with a grain of salt, since
the details are fuzzy in my head, but the summary is that my paths were
incorrect / out of order when I tried to build a driver from VC6.

First the setup, I had VC6, VS.NET, and the latest DDK installed. I was
trying to work on building a driver from VC6 and got a “Compiler not
supported” error.

If I look at the C compiler from the 2003DDK, (just open a build
environment and type cl.exe), I get the following:
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 13.10.2179

If I look at the compiler from .NET, I get:
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 13.10.3077

And if I remember correctly, the compiler from VC6 is version
12…something.

So the following will fail if you use the VC6 compiler:

#if _MSC_VER < 1300
#error Compiler version not supported by Windows DDK
#endif

When you try and build from VC6, the IDE is probably finding its
compiler before it finds the DDK one, thus the preprocessor check
fails. And it will work in .NET no matter what the paths because the
.NET compiler is newer than the DDK compiler.

My solution at the time was to go back to using the Build Environment
shortcuts, then later integrate one of the ddkbuild utilities into an
IDE that I liked.

While I’m not sure if this solves any of your problems, maybe it can
give you some more insight into it.

Best Regards,
-Mike

Jussi Rytilahti wrote:

Thanks all!

I have already tested “ddkbuild”-tool and original “build” also.

@Gary:And I like this ddkbuild and I am using it in my “training project” in
.NET 2003 and it seems to work very fine.

@Alberto:Your absolutelly right with this “try+success=learn” (Or something
like that). I will test your way also.

@PeterGV: I have tried look answer from you pages but I have not successed
with this problem: Why I get this error in VC6 but not .NET and Is that
possible to try this wizard in VC6 with my DDK.

So, question is :can I even try this wizard? Becource .AWX it is only
working in VC6, but I get that error. If I take all files which wizard has
created and build them in .NET (in project which uses ddkbuild) I will
succeed…Is the only way out: Create files in vc6 with wizard and then
build them in .NET?

Jussi

“Jussi Rytilahti”kirjoitti
viestissä:xxxxx@ntdev…

Hi,

I am total newbie with drivers. I have one problem. I am reading Walter
Oneys book “Programming the Microsoft Windows Driver Model, Ed2” and now
I´d like to try his AppWizard for Visual C++ 6.0 (WDMWIZ.AWX). I get every
time same error : error C1189: #error : Compiler version not supported by
Windows DDK. I am using DDK 2600.1106 and working OS is XP. Documentation
of this wizard says that wizard is for VC++6.0 and XP and .NET DDKs

Do I have any chances to use VC++6.0 with my DDK? (I have also .NET, but
wizard works only in 6.0)

BR.
Jussi


Questions? First check the Kernel Driver FAQ at

[http://www.osronline.com/article.cfm?id=256](http://www.osronline.com/article.cfm?id=256)

You are currently subscribed to ntdev as:xxxxx@hologic.com
To unsubscribe send a blank email toxxxxx@lists.osr.com


Questions? First check the Kernel Driver FAQ at

[http://www.osronline.com/article.cfm?id=256](http://www.osronline.com/article.cfm?id=256)

You are currently subscribed to ntdev as:xxxxx@storagecraft.com
To unsubscribe send a blank email toxxxxx@lists.osr.com


Questions? First check the Kernel Driver FAQ athttp://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as:xxxxx@hologic.com
To unsubscribe send a blank email toxxxxx@lists.osr.com