Use C++ in Drivers

Using C++ in drivers are doable and quite easy actually, if you go with the approach of There is one catch through: you might run into following linking error:

warning LNK4254: section ‘.CRT’ (40000040) merged into ‘.data’ (C0000040) with different attributes

The workaround is change following line in htscppdata.cpp:

#pragma comment(linker, “/”)


#ifdef _WIN64
#pragma comment(linker, “/”)
#pragma comment(linker, “/merge:.CRT=.rdata”)

The change is required with WDK 7600.16385.1.


Posted on April 27, 2011, in Uncategorized. Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: