Building user-mode applications with ddk

Hi,
Browsing the archives, I noticed several threads that discussed building
user-mode applications with the ddk.
I am considering leaving the VC6 build environment and instead using the ddk
build tools to build the application that is accompanied with my driver.
This application is multi-threaded service, and it is I/O intensive (Disk
and socket I/Os). Also, the application is using MSCS API that are wrapped
in a library that comes with the SDK and not in the DDK.
I would have built my app using the SDK, however the SDK doesn’t contain 32
bits compiler.
My question is whether using the DDK to build my user-land APP is good
enough for production binaries and whether there are any known limitation
(For example, is C++ supported). I noticed that using MFC is flaky but my
binary is windowless and doesn’t need it.
Also, is this procedure(Building user-mode app with the DDK) supported by
Microsoft or is it only a hack that is used for private builds and
experiments.
I guess that I can move to Visual studio 2005, but we checked the tool and
found it too cumbersome and expensive to our needs.

Thanks,
Eran.

I was using the DDK build for usermode, but I kept having problems with
C++. After becoming totally
irritated with it, I downloaded 2005 Express Edition (free download).
Once I set up my include and lib
paths, I’ve been building services with it (with no problem).

Then again, I don’t know if this would work for you, I just needed
something that could use the FltMgr
headers (which are versioned) and wouldn’t spit out errors all over the
place like in VC6. There were also
problems with the vc runtime that the ddk build didn’t like. To sum it
up, problem solved; cost = $0.00.

Matt

Eran Borovik wrote:

Hi,
Browsing the archives, I noticed several threads that discussed building
user-mode applications with the ddk.
I am considering leaving the VC6 build environment and instead using the ddk
build tools to build the application that is accompanied with my driver.
This application is multi-threaded service, and it is I/O intensive (Disk
and socket I/Os). Also, the application is using MSCS API that are wrapped
in a library that comes with the SDK and not in the DDK.
I would have built my app using the SDK, however the SDK doesn’t contain 32
bits compiler.
My question is whether using the DDK to build my user-land APP is good
enough for production binaries and whether there are any known limitation
(For example, is C++ supported). I noticed that using MFC is flaky but my
binary is windowless and doesn’t need it.
Also, is this procedure(Building user-mode app with the DDK) supported by
Microsoft or is it only a hack that is used for private builds and
experiments.
I guess that I can move to Visual studio 2005, but we checked the tool and
found it too cumbersome and expensive to our needs.

Thanks,
Eran.


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

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

The user mode libraries in the ddk include a recent and complete platform
sdk but all of the mfc side of things is pretty wretched. If you have a
library dependency that is not in the ddk distribution I say you are just
asking for trouble, as you will be mix and matching build environments.

VS2005 comes with vcbuild which simplifies command line builds for the
visual studio build environment. What I do is build all components from a
top level makefile that knows how to build both ddk based components and VS
based components. This approach lets me use the toolset most appropriate to
each component itself, rather than imposing some arbitrary rule such as
‘everything must be built with the ddk’ and then having to force the
consequent square pegs through that round hole.

=====================
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 Eran Borovik
Sent: Tuesday, April 18, 2006 5:18 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Building user-mode applications with ddk

Hi,
Browsing the archives, I noticed several threads that
discussed building user-mode applications with the ddk.
I am considering leaving the VC6 build environment and
instead using the ddk build tools to build the application
that is accompanied with my driver.
This application is multi-threaded service, and it is I/O
intensive (Disk and socket I/Os). Also, the application is
using MSCS API that are wrapped in a library that comes with
the SDK and not in the DDK.
I would have built my app using the SDK, however the SDK
doesn’t contain 32 bits compiler.
My question is whether using the DDK to build my user-land
APP is good enough for production binaries and whether there
are any known limitation (For example, is C++ supported). I
noticed that using MFC is flaky but my binary is windowless
and doesn’t need it.
Also, is this procedure(Building user-mode app with the DDK)
supported by Microsoft or is it only a hack that is used for
private builds and experiments.
I guess that I can move to Visual studio 2005, but we checked
the tool and found it too cumbersome and expensive to our needs.

Thanks,
Eran.


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

To unsubscribe, visit the List Server section of OSR Online
at http://www.osronline.com/page.cfm?name=ListServer

On 4/18/06 6:31 AM, “Mark Roddy” wrote:

> The user mode libraries in the ddk include a recent and complete platform
> sdk

Well, nearly complete; I’ve found that it’s hit-and-miss if you start
linking in uncommon APIs. It really just depends on the project. I have used
the DDK for building user apps often enough, particularly in the past couple
of years, and it usually works out fine. You’ll just have to decide based on
the APIs you want.

> but all of the mfc side of things is pretty wretched. If you have a
> library dependency that is not in the ddk distribution I say you are just
> asking for trouble, as you will be mix and matching build environments.

Agree 100%. Once you get yourself tied into this sort of franken-kit, you’ll
find that it’s hard to get out. You wind up creating big-time maintenance
problems.

-Steve

Eran Borovik wrote:

My question is whether using the DDK to build my user-land APP is good
enough for production binaries and whether there are any known limitation
(For example, is C++ supported). I noticed that using MFC is flaky but my
binary is windowless and doesn’t need it.

One key problem is that you are stuck with old versions of MFC and ATL.
The ATL thing is a serious issue; the newer versions of ATL are an
incredibly useful tool, and I always feel handicapped when I have to go
back to the version in the DDK.

The MFC isn’t flaky – it’s just older.

I guess that I can move to Visual studio 2005, but we checked the tool and
found it too cumbersome and expensive to our needs.

It is costly, but the cumbersome comment is not real. Visual Studio 98
was cumbersome when you bought it. After a week, you’ll be used to it.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.

> My question is whether using the DDK to build my user-land APP is good

enough for production binaries

It is fine. In fact, it is a better build suite then MSVC.

and whether there are any known limitation
(For example, is C++ supported).

Yes. So are STL and ATL (you need to enable something in SOURCES to use STL).

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

BTW, I heard from coworkers who use Platform SDK it now contains compiler as DDK.

Best regards,

Michal Vodicka
UPEK, Inc.
[xxxxx@upek.com, http://www.upek.com]


From: xxxxx@lists.osr.com[SMTP:xxxxx@lists.osr.com] on behalf of Maxim S. Shatskih[SMTP:xxxxx@storagecraft.com]
Reply To: Windows System Software Devs Interest List
Sent: Wednesday, April 19, 2006 4:06 AM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] Building user-mode applications with ddk

> My question is whether using the DDK to build my user-land APP is good
> enough for production binaries

It is fine. In fact, it is a better build suite then MSVC.

>and whether there are any known limitation
> (For example, is C++ supported).

Yes. So are STL and ATL (you need to enable something in SOURCES to use STL).

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


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

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

Michal Vodicka wrote:

BTW, I heard from coworkers who use Platform SDK it now contains compiler as DDK.

The Platform SDK includes only the 64-bit compilers, and has for quite
some time.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.

I use a somewhat bastardized DDK build process by making use of the /USEENV
switch with VS2003’s DEVENV.EXE. I’m not sure if VC6 supports it but
basically I run a .JS script which asks what build env I want to run (x86
VS2003, x86 DDK, x64 DDK, etc) then launch a batch file to set the proper
environment variables and run DEVENV with the /USEENV switch. After that, I
build as normal in VS and things just work. I even have a completely hacked
environment which uses VS2005 ATL/MFC with the latest DDK+PLATFORMSDK but
for that I had to rebuild ATLS and ATLMINCRT with the DDK first.

The environment variables that VS will pick up and use are PATH, LIB,
LIBPATH, INCLUDE and SOURCE. I can send the scripts off list if you are
interested but you’ll have to modify the paths for your installations.

  • Jeremy Boschen

“Eran Borovik” wrote in message news:xxxxx@ntdev…
> Hi,
> Browsing the archives, I noticed several threads that discussed building
> user-mode applications with the ddk.
> I am considering leaving the VC6 build environment and instead using the
ddk
> build tools to build the application that is accompanied with my driver.
> This application is multi-threaded service, and it is I/O intensive (Disk
> and socket I/Os). Also, the application is using MSCS API that are wrapped
> in a library that comes with the SDK and not in the DDK.
> I would have built my app using the SDK, however the SDK doesn’t contain
32
> bits compiler.
> My question is whether using the DDK to build my user-land APP is good
> enough for production binaries and whether there are any known limitation
> (For example, is C++ supported). I noticed that using MFC is flaky but my
> binary is windowless and doesn’t need it.
> Also, is this procedure(Building user-mode app with the DDK) supported by
> Microsoft or is it only a hack that is used for private builds and
> experiments.
> I guess that I can move to Visual studio 2005, but we checked the tool and
> found it too cumbersome and expensive to our needs.
>
> Thanks,
> Eran.
>
>
>