Urgent: no driver menu in VS2008

dev srini wrote:

Okay, I hope I can run the project file wiht VS 2013.

You won’t be able to run the existing project file, nor should you want
to. The format changed from vcproj to vcxproj in Visual Studio 2010.
The rest depends on what the project file does. There ARE solutions
that have a vcproj file call into a batch file to do the build. The
batch file then sets up the DDK build environment and calls the “build”
command. That method is supported, although you will want to create a
new project file in VS2013.

But if your guy really developed a self-contained vcproj file that
invokes the VS2008 compiler directly, by specifying the include paths
and library paths in the project file, that has NEVER been a supported
method for building drivers. Again, you will have to create a new
project file in VS2013.

The *.vcproj file that I’m using, has been developed 15 yrs back by
someone who is not in our company anymore and he used VS2008 with
WinDDK 7.0,

Your mathematics are a little off. VS2008 came out 7 years ago, and WDK
7 came out 6 years ago.


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

Tim Roberts wrote:

dev srini wrote:
> Okay, I hope I can run the project file wiht VS 2013.

Clearly, I should have waited to read the rest of the thread before
replying…


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

>build commands are using ‘ddkbuild -W7XP checked’ for debug mode and ‘ddkbuild -W7XP free’

for release mode

I just don’t understand why this is worth the time spent.

You can use MSVC editor anyway.

You cannot use MSVC debugger, since 2008 has no kernel debugging support.

And, MSVC’s project mgmt is just plain inferior to SOURCES. The files are more complex, hard to comprehend by human, hard to diff in the source control, hard to copy-paste from another successful project.

Also, I’ve heard that minor change to build options in the MSVC GUI boxes can rearrange the project file totally to the state where diff is not possible.

Also, I don’t think !INCLUDE is supported in these files, which makes them even more primitive.

Most serious software titles do not use GUI-generated build scripts, both in GNU world (autoconf, automake, CMake) and in MS’s world (MS’s internal build system called Razzle, of which BUILD+SOURCES is a subset).


Maxim S. Shatskih
Microsoft MVP on File System And Storage
xxxxx@storagecraft.com
http://www.storagecraft.com

Maxim S. Shatskih wrote:

> build commands are using ‘ddkbuild -W7XP checked’ for debug mode and ‘ddkbuild -W7XP free’
> for release mode
I just don’t understand why this is worth the time spent.

And, MSVC’s project mgmt is just plain inferior to SOURCES. The files are more complex, hard to comprehend by human, hard to diff in the source control, hard to copy-paste from another successful project.

I have to dispute this, for several reasons. It seems to me that your
objections are a result of unfamiliarity, rather than objective
comparison. Really, it is inaccurate to call SOURCES a “project
management” tool. It handles one build project, in one directory.
That’s not project management.

The vcxproj format is certainly more wordy than SOURCES, but it is
vastly more flexible, much more powerful, and obviously more completely
specified. I almost never go into the VS IDE, but I have now become
just as adept at manipulating vcxproj files from vim as I was at
manipulating SOURCES. You have the full power of C# available to you
for string manipulation, something that SOURCES makes virtually
impossible. I far prefer the vcxproj style now.

I have a couple of Python scripts that make some tasks easier. One will
generate a new GUID for a project. That in itself makes the
cut-and-paste task trivial. Copy, set new GUID, edit project name, set
source files, off you go. I have another that will create a .sln file
from an arbitrary set of .vcxprojs, so I can do multiple builds at
once. I have another that does a property sort, to gather the common
settings as much as possible. For example, instead of repeating all of
the settings 12 times (Win 7 Debug 32, Win 7 Release 32, Win 7 Debug 64,
Win 7 Release 64, Win 8 Debug 32, etc.), it collects a “Win 7” section,
a “Win 8.1” section, a “Debug” section, a “Release” section, a “32”
section, and a “64” section. Msbuild handles that just fine, and it’s
much easier to maintain by hand. It’s true that editing the properties
in the IDE will undo my collection, but I can put it all back.

Also, I’ve heard that minor change to build options in the MSVC GUI boxes can rearrange the project file totally to the state where diff is not possible.

In general, this is not the case. The IDE writes the properties in the
same order each time. There are some large operations you can do that
have a global effect, but when you’re making big changes, you have to
expect issues.

One of the tools I haven’t written yet is an XML diff. Since whitespace
is generally insignificant, one could do a much more intelligent job
than just straight character-by-character comparison.

Also, I don’t think !INCLUDE is supported in these files, which makes them even more primitive.

Of course it does. It’s used in virtually every project:

It’s now quite common for a development group to set up a “library” of
targets and options and store that in a local properties file, then
that into the project.

> Most serious software titles do not use GUI-generated build scripts, both in GNU world (autoconf, automake, CMake) and in MS’s world (MS’s internal build system called Razzle, of which BUILD+SOURCES is a subset).

Vcxproj tools do not have to be generated by the GUI. Also, many Gnu
tools are built with Eclipse, which goes generate the build scripts for you.


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

> The vcxproj format is certainly more wordy than SOURCES, but it is

vastly more flexible, much more powerful, and obviously more completely
specified. I almost never go into the VS IDE, but I have now become
just as adept at manipulating vcxproj files from vim as I was at
manipulating SOURCES.

…and using MSBuild? yes, probably good.

Are .vcxproj files generated by the IDE (using GUI build settings editor) compatible with MSBuild?

Can the GUI editor edit any valid .vcxproj file, including the manually written one?


Maxim S. Shatskih
Microsoft MVP on File System And Storage
xxxxx@storagecraft.com
http://www.storagecraft.com

Maxim S. Shatskih wrote:

> The vcxproj format is certainly more wordy than SOURCES, but it is
> vastly more flexible, much more powerful, and obviously more completely
> specified. I almost never go into the VS IDE, but I have now become
> just as adept at manipulating vcxproj files from vim as I was at
> manipulating SOURCES.
…and using MSBuild? yes, probably good.

Are .vcxproj files generated by the IDE (using GUI build settings editor) compatible with MSBuild?

The IDE calls “msbuild” to do its builds. That IS the consumer.

Can the GUI editor edit any valid .vcxproj file, including the manually written one?

If I were honest, I’d say “no”. However, MSBuild is an extremely
general system. You can write trivial vcxproj files that do nothing
more than echo some strings to stdout, and I’ll wager the GUI wouldn’t
like that. It’s looking for trigger words.

However, I would say that the GUI can edit any PRODUCTIVE vcxproj file.
This, by the way, is one of the big differences between the .vcproj and
the .vcxproj. With .vcproj, ordering and even spacing was important.
With .vcxproj, as long as you follow the XML rules, msbuild will consume it.

The same is not true of .sln files. I discovered by painful experience
that even the number of spaces used in indenting is critically important.

If you truly want to become a convert, I strongly recommend the book
“MSBuild Trickery: 99 Ways to Bend the Build Engine to Your Will”. He
walks you through the process of generating simple project files by
hand, and moves from there into the things that the IDE looks for. It’s
filled with great examples. It was really helpful for me:
http://www.amazon.com/MSBuild-Trickery-Ways-Build-Engine/dp/061550907X


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

In general I have found the IDE can handle any manual vcxproj I threw at it. Sometimes it rewrote parts of the file when I messed with a setting, but not wholesale. The one big issue the IDE has is that it requires the configurations (ie x86fre | debug | win7) be in the vcxproj itself, you can’t them and have a single globally shared definition of the configurations. The command line handles this just fine.

d

-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Tim Roberts
Sent: Friday, June 5, 2015 10:58 AM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] Urgent: no driver menu in VS2008

Maxim S. Shatskih wrote:
>> The vcxproj format is certainly more wordy than SOURCES, but it is
>> vastly more flexible, much more powerful, and obviously more
>> completely specified. I almost never go into the VS IDE, but I have
>> now become just as adept at manipulating vcxproj files from vim as I
>> was at manipulating SOURCES.
> …and using MSBuild? yes, probably good.
>
> Are .vcxproj files generated by the IDE (using GUI build settings editor) compatible with MSBuild?

The IDE calls “msbuild” to do its builds. That IS the consumer.

> Can the GUI editor edit any valid .vcxproj file, including the manually written one?

If I were honest, I’d say “no”. However, MSBuild is an extremely general system. You can write trivial vcxproj files that do nothing more than echo some strings to stdout, and I’ll wager the GUI wouldn’t like that. It’s looking for trigger words.

However, I would say that the GUI can edit any PRODUCTIVE vcxproj file.
This, by the way, is one of the big differences between the .vcproj and the .vcxproj. With .vcproj, ordering and even spacing was important.
With .vcxproj, as long as you follow the XML rules, msbuild will consume it.

The same is not true of .sln files. I discovered by painful experience that even the number of spaces used in indenting is critically important.

If you truly want to become a convert, I strongly recommend the book “MSBuild Trickery: 99 Ways to Bend the Build Engine to Your Will”. He walks you through the process of generating simple project files by hand, and moves from there into the things that the IDE looks for. It’s filled with great examples. It was really helpful for me:
http://www.amazon.com/MSBuild-Trickery-Ways-Build-Engine/dp/061550907X


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


NTDEV is sponsored by OSR

Visit the list at: http://www.osronline.com/showlists.cfm?list=ntdev

OSR is HIRING!! See http://www.osr.com/careers

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

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