Windows System Software -- Consulting, Training, Development -- Unique Expertise, Guaranteed Results
The free OSR Learning Library has more than 50 articles on a wide variety of topics about writing and debugging device drivers and Minifilters. From introductory level to advanced. All the articles have been recently reviewed and updated, and are written using the clear and definitive style you've come to expect from OSR over the years.
Check out The OSR Learning Library at: https://www.osr.com/osr-learning-library/
Upcoming OSR Seminars | ||
---|---|---|
OSR has suspended in-person seminars due to the Covid-19 outbreak. But, don't miss your training! Attend via the internet instead! | ||
Writing WDF Drivers | 7 Dec 2020 | LIVE ONLINE |
Internals & Software Drivers | 25 Jan 2021 | LIVE ONLINE |
Developing Minifilters | 8 March 2021 | LIVE ONLINE |
Comments
I have nmake in %ProgramFiles(x86)\Microsoft Visual Studio 12.0\VC\bin\amd64.
mm
From: [email protected] [mailto:[email protected]] On Behalf Of Suresh Chepuri
Sent: Wednesday, September 24, 2014 9:54 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] integrating wdk 7.1 based osr scripts into VS2013?
Hi guys,
We have migrated to visual studio 2013+WDK 8.1 recently. We are using wdk 7.1 for building drivers for vista and 2003 with the help of OSR script. Can we integrate these scripts into vs 2013 project configuration to build all platforms.I don't see NMAKE tool with .vcxproj. Could you please advice?
thanks,
suresh
--- 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
From: [email protected] [mailto:[email protected]] On Behalf Of Suresh Chepuri
Sent: Wednesday, September 24, 2014 9:54 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] integrating wdk 7.1 based osr scripts into VS2013?
Hi guys,
We have migrated to visual studio 2013+WDK 8.1 recently. We are using wdk 7.1 for building drivers for vista and 2003 with the help of OSR script. Can we integrate these scripts into vs 2013 project configuration to build all platforms.I don't see NMAKE tool with .vcxproj. Could you please advice?
thanks,
suresh
--- 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
>
> We have migrated to visual studio 2013+WDK 8.1 recently. We are using
> wdk 7.1 for building drivers for vista and 2003 with the help of OSR
> script. Can we integrate these scripts into vs 2013 project
> configuration to build all platforms.I don't see NMAKE tool with
> .vcxproj. Could you please advice?
>
I'm not sure what you're asking. Are you saying you just want to be
able to build all of your configurations from a command line? I use
batch files:
msbuild /p:Configuration="Win7 Debug",Platform=Win32
msbuild /p:Configuration="Win7 Release",Platform=Win32
msbuild /p:Configuration="Win7 Debug",Platform=x64
msbuild /p:Configuration="Win7 Release",Platform=x64
Actually, I'm a bit lazier than that. I wrote a Python script that
reads the current vcxproj file, and calls msbuild for each
configuration/platform combination it finds. Very handy.
--
Tim Roberts, [email protected]
Providenza & Boekelheide, Inc.
Tim Roberts, [email protected]
Providenza & Boekelheide, Inc.
> I wrote a Python script that
> reads the current vcxproj file, and calls msbuild for each
> configuration/platform combination it finds. Very handy.
>
We did something different for integration of pre-win8 WDK
into VS solutions with application or other usermode components.
We had basically a chain of three small batch files:
The 1st script maps VC++ project configuration to WDK configuration(s)
and calls ddkbuild or its analog.
This allows things like building several driver binaries for one
solution configuration. Developer can mix and match drivers with
usermode stuff in any combination.
For example, a certain configuration builds single set of usermode
binaries with three driver binaries for winxp, 2k and win7. Or, one can
choose to build x86 and x64 drivers at once, debug and release.
So the build command in the vcproj is:
<Tool Name="VCNMakeTool"
BuildCommandLine="$(BLDCMD) $(ConfigurationName) $(PlatformName)"
.......
where BLDCMD is the 1st script.
The 2nd script is some kind of ddkbuild.bat; a wrapper around the WDK
build, in one given WDK config.
The 3rd script is a kind of binplace, it copies the build products to
the output directory of the solution and does any needed postprocessing
(signing, storing the PDBs with the package...)
The 1st script looks like this:
set a_conf=%1
set a_platf=%2
goto LABEL_%a_conf%%a_platf%
...
:LABEL_DEBUGX64
call :ddkbld WIN7 X64 CHK
call :filecopy WIN7 X64 CHK
goto :EOF
rem Subroutine to call ddkbuild.bat:
:ddkbld
......
rem Subroutine to move build products
:filecopy
......
Oh and we've put all this in a VS property sheet (.vspropt or .props)
for easy cloning projects.
These were the gloomy days before the new, VS-encumbered kit
Regards,
-- pa
Doron : Yes, We have to use either makefile (OSR script) or default
configuration(WDK 8.1) to build either of the targeted WDK platforms.
Pavel : I am asking about how to build drivers starting form windows 2003
to windows 8.1 from VS 2013 along with other user applications. Like
choosing configuration "release | win32" would build all 32-bit
applications and "release" command for driver project would expand to all
supported platforms.
Thanks,
Suresh
On Thu, Sep 25, 2014 at 2:22 AM, Pavel A. wrote:
> On 24-Sep-2014 20:25, Tim Roberts wrote:
>
>> I wrote a Python script that
>> reads the current vcxproj file, and calls msbuild for each
>> configuration/platform combination it finds. Very handy.
>>
>>
> We did something different for integration of pre-win8 WDK
> into VS solutions with application or other usermode components.
> We had basically a chain of three small batch files:
>
> The 1st script maps VC++ project configuration to WDK configuration(s)
> and calls ddkbuild or its analog.
> This allows things like building several driver binaries for one
> solution configuration. Developer can mix and match drivers with usermode
> stuff in any combination.
> For example, a certain configuration builds single set of usermode
> binaries with three driver binaries for winxp, 2k and win7. Or, one can
> choose to build x86 and x64 drivers at once, debug and release.
>
> So the build command in the vcproj is:
>
> BuildCommandLine="$(BLDCMD) $(ConfigurationName) $(PlatformName)"
> .......
>
> where BLDCMD is the 1st script.
>
> The 2nd script is some kind of ddkbuild.bat; a wrapper around the WDK
> build, in one given WDK config.
>
> The 3rd script is a kind of binplace, it copies the build products to the
> output directory of the solution and does any needed postprocessing
> (signing, storing the PDBs with the package...)
>
>
> The 1st script looks like this:
>
> set a_conf=%1
> set a_platf=%2
> goto LABEL_%a_conf%%a_platf%
> ...
>
> :LABEL_DEBUGX64
> call :ddkbld WIN7 X64 CHK
> call :filecopy WIN7 X64 CHK
> goto :EOF
>
> rem Subroutine to call ddkbuild.bat:
> :ddkbld
> ......
>
> rem Subroutine to move build products
> :filecopy
> ......
>
>
> Oh and we've put all this in a VS property sheet (.vspropt or .props) for
> easy cloning projects.
> These were the gloomy days before the new, VS-encumbered kit
>
> Regards,
> -- pa
>
>
>
> ---
> 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
>
> Pavel : I am asking about how to build drivers starting form windows
> 2003 to windows 8.1 from VS 2013 along with other user applications.
> Like choosing configuration "release | win32" would build all 32-bit
> applications and "release" command for driver project would expand to
> all supported platforms.
Yes, this is exactly the kind of scenario that I've tried to describe.
-- pa
anything to continue to build WD7 based projects for platforms unsupported
by WDk8.1. So our developer solutions run a mix of VS WDK8.1 projects and
nmake ddkbuild projects. Our build system does everything from a batch
file, as others have indicated, running either ddkbuild or an equivalent
script to do msbuilld for WDK8.1 projects.
It would have been a bit less trouble if WDK8.1 supported XP->Win8.1.
Despite rumors to the contrary, XP lives on.
Mark Roddy
On Thu, Sep 25, 2014 at 11:36 AM, Suresh Chepuri
wrote:
> Thanks Doron, MM, Tim and Pavel for your response.
>
> Doron : Yes, We have to use either makefile (OSR script) or default
> configuration(WDK 8.1) to build either of the targeted WDK platforms.
> Pavel : I am asking about how to build drivers starting form windows 2003
> to windows 8.1 from VS 2013 along with other user applications. Like
> choosing configuration "release | win32" would build all 32-bit
> applications and "release" command for driver project would expand to all
> supported platforms.
>
> Thanks,
> Suresh
>
>
> On Thu, Sep 25, 2014 at 2:22 AM, Pavel A. wrote:
>
>> On 24-Sep-2014 20:25, Tim Roberts wrote:
>>
>>> I wrote a Python script that
>>> reads the current vcxproj file, and calls msbuild for each
>>> configuration/platform combination it finds. Very handy.
>>>
>>>
>> We did something different for integration of pre-win8 WDK
>> into VS solutions with application or other usermode components.
>> We had basically a chain of three small batch files:
>>
>> The 1st script maps VC++ project configuration to WDK configuration(s)
>> and calls ddkbuild or its analog.
>> This allows things like building several driver binaries for one
>> solution configuration. Developer can mix and match drivers with usermode
>> stuff in any combination.
>> For example, a certain configuration builds single set of usermode
>> binaries with three driver binaries for winxp, 2k and win7. Or, one can
>> choose to build x86 and x64 drivers at once, debug and release.
>>
>> So the build command in the vcproj is:
>>
>> > BuildCommandLine="$(BLDCMD) $(ConfigurationName) $(PlatformName)"
>> .......
>>
>> where BLDCMD is the 1st script.
>>
>> The 2nd script is some kind of ddkbuild.bat; a wrapper around the WDK
>> build, in one given WDK config.
>>
>> The 3rd script is a kind of binplace, it copies the build products to the
>> output directory of the solution and does any needed postprocessing
>> (signing, storing the PDBs with the package...)
>>
>>
>> The 1st script looks like this:
>>
>> set a_conf=%1
>> set a_platf=%2
>> goto LABEL_%a_conf%%a_platf%
>> ...
>>
>> :LABEL_DEBUGX64
>> call :ddkbld WIN7 X64 CHK
>> call :filecopy WIN7 X64 CHK
>> goto :EOF
>>
>> rem Subroutine to call ddkbuild.bat:
>> :ddkbld
>> ......
>>
>> rem Subroutine to move build products
>> :filecopy
>> ......
>>
>>
>> Oh and we've put all this in a VS property sheet (.vspropt or .props) for
>> easy cloning projects.
>> These were the gloomy days before the new, VS-encumbered kit
>>
>> Regards,
>> -- pa
>>
>>
>>
>> ---
>> 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
>>
>
> --- 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
>