Thanks a lot,
Thanks,
You are right, you can use the MSVC IDE for the build.
There are two ways. First there is a tool that creates DSP-files
from the "sources" file but I forgot the url. Maybe someone else
knows it.
The second method is to create a project by hand. To do so
choose an empty project (Win32 EXE or DLL or Console)
in the "Create New Project"-dialog, then add the files (.cpp, .c, .h)
In your main include file place the folowing lines:
#ifdef _M_IX86
#define _X86_ // needed by ntddk.h, for alpha add appropriate lines
#endif
#ifdef _DEBUG // MSVC uses _DEBUG and NDEBUG by default
#define DBG 1
#endif
#include <ntddk.h>
then change your project settings as folows:
- use __stdcall instead of __cdecl which is the default
- the entry point should be DriverEntry
- include hal.lib ntoskrnl.lib int64.lib
- set your includepath for include and lib files
note: set your lib-directoy in the project settings, so
you can use different directories for the debug and
release build)
- you need the following linker settings: /subsystem:native /driver
(in VC5 you must type them by hand. Maybe its the same in VC6)
You should now be able to compile your project. Don't forget
to use extern "C" if you use C++ instead of C. Otherwise you'll
get hundreds of errors when including ntddk.h.
If you prefer the console mode build, then you'll have to set some
additional env variables. I think it is MSTOOLS. This should
point to your Developer Studio directoy.
I hope this helps,
Ingo Blum
> Isn't VC6.0 Win32 SDK?
No. There used to be a time when overlap between the DDK and SDK was
carefully minimized, but alas ...
Anyway, VC6 contains only part of the SDK. But the problem might also be
that the DDK install just cannot find your SDK portions -- for a plain
SDK install, a bunch of environment variables are registered, pointing
to various parts of the SDK.
The srctodsp utility that Ingo referred to is available from the
Compuware web site
http://www.numega.com/drivercentral/tech_tips/srctodsp.shtml -- and
while you are there, buy a copy of SoftICE if you haven't yet -- just my
two cents' worth.
--
Cheers,
Felix.
If you post a reply, kindly refrain from emailing it, too.
Note to spammers: fel...@mvps.org is my real email address.
No anti-spam address here. Just one comment: IN YOUR FACE!
With regards
R.R.Kannan Babu
Research Engineer
C-DOT
Bangalore
India
e-mail :k...@cdotb.ernet.in
kanna...@yahoo.com
Min wrote:
> I'm newbie to DDK programming. Can anybody tell me how
> to compile NT 4.0 DDK in VC 6.0 IDE? I don't think the
> DDK must be compiled under console mode. If possible,
> please give me a step by step sample.
>
> Thanks a lot,
Thanks for your reply. I'm using VC6 and NT DDK4.0. I used the second
method you mentioned
to build the sample project d:\ddk\src\comm\serial in IDE, but met some
problems:
1. precomp.h(16) fatal error C1083: Cannot open include file: 'serlog.h': No
such file or
directory
2. SERIAL.RC(13) : fatal error RC1015: cannot open include file 'serlog.rc'.
What can I do?
Min
Ingo Ralf Blum wrote in message
<#u3l5gxG$GA....@cppssbbsa02.microsoft.com>...
>> I'm newbie to DDK programming. Can anybody tell me how
>> to compile NT 4.0 DDK in VC 6.0 IDE? I don't think the
>> DDK must be compiled under console mode. If possible,
>> please give me a step by step sample.
>
I installed Platform SDK and ran setenv.bat in ddk\bin, but when I tried
to buid the sample
at ddk\src\comm\serial, I met the following problem:
d:\ddk\inc\makefile.def(740) : fatal error U1052: file 'obj\_objects.mac'
not found. Stop.
What's the problem?
Thanks a lot,
Kannan Babu wrote in message <380E95C3...@cdotb.ernet.in>...
>hi min
> ofcourse you can compile NT DDK with the help of VC 6.0 in console
>mode.
> the steps are as follows
>1) select the checked build environment option in NT DDK
>2) In the checked build environment console mode you can go to your
>directory where your files are kept and give build command.
> the requirements are you should have sources file and a makefile..
> these two files you can get it from the sample given in the ddk kit.
>then
> you can modify the sources according to your requirements.
>3) this build uses the cl.exe and link.exe of vc 6.0..
>
>With regards
>R.R.Kannan Babu
>Research Engineer
>C-DOT
>Bangalore
>India
>e-mail :k...@cdotb.ernet.in
> kanna...@yahoo.com
>
>
>Min wrote:
>
>> I'm newbie to DDK programming. Can anybody tell me how
>> to compile NT 4.0 DDK in VC 6.0 IDE? I don't think the
>> DDK must be compiled under console mode. If possible,
>> please give me a step by step sample.
>>
>> Thanks a lot,
>
If possible, would you please tell me the difference among Win32 SDK,
Platform SDK and VC SDK?
Thanks,
Felix Kasza [MVP] wrote in message <38100b2f....@207.46.180.25>...
> If possible, would you please tell me the difference among Win32 SDK,
> Platform SDK and VC SDK?
The Platform SDK is a superset of the old Win32 SDK . VC is not an SDK
at all; it just _contains_ enough parts of the Platform SDK to allow
compiling and linking most vanilla user-mode apps.
Thanks, Merce.
Sent via Deja.com http://www.deja.com/
Before you buy.
> I need a library that I can´t find, wdm.lib.
Odd. It shows up fine here (I have the NT5 RC3 DDK installed).
FYI, I build all my NT4 drivers under VC6 by using the information and batch
file that you can get from http://www.osr.com
Go to their NT Insider newsletter archives and I think it was 1996 issues,
and find the Visual C build info article. Trust me, follow the example and
it works just fine.
Good Luck
Ron
Mercedes Gutierrez <me...@inforg.uniovi.es> wrote in message
news:7v751k$1u7$1...@nnrp1.deja.com...
Hello,
you must insert a custom build step into your project. The serlog.rc file is created by the
message compiler mc.exe, so you have to run mc.exe on serlog.mc. Take a look at
makfile.inc in the directory you mentioned above. It contains the commandline and the
files for the message compiler: insert the commandline "mc -v serlog.mc"
as your build command and the files serlog.h serlog.rc msg00001.bin as the output files.
I cutted an pasted these files, so maybe you have to adjust them by hand depending on your
makefile.inc.
Your project should then compile without errors (I hope so). But try the srctodsp-utility.
The URL was mentioned in another reply to your question. It makes things a bit easyer.
Ingo
> FYI, I build all my NT4 drivers under VC6 by using the information and batch file that you can get from http://www.osr.com
So do I (using VC5).
Aamof I build without having the SDK installed ... adding the
following to my environment variables (control
panel\system\environment):
MSSDK=d:\mssdk.not
MSTOOLS=d:\mssdk.not
was enough to keep the DDK installation program happy (let it think
that the SDK is installed), happy enough that it would actually instal
the DDK. I'm don't know which of the DDK projects (if any) actually
need to have the SDK (whatever that is) installed.
Microsft recommends,
http://support.microsoft.com/support/kb/articles/Q170/5/30.ASP
changing to proper code page in the program? How do I find the proper
code page?
Can u please help?
Regards,
sbs