Vista Problems with Visual Studio?

Hello,

I’m trying to build an application using Visual
Studio 2008 on Vista that
uses the fltUserStructures.h from the ddk6000.

The file contents of fltUserStructures.h differ from
that was XP. I’m having difficulty compiling the
following:

typedef
_struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION) *
InstanceNameLength) struct
_INSTANCE_BASIC_INFORMATION
{
ULONG NextEntryOffset;
USHORT InstanceNameLength;
USHORT InstanceNameBufferOffset;

}INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;

Its stating INSTANCE_BASIC_INFORMATION undeclared.

Any ideas?

Thanks,
Garyc


NTFSD is sponsored by OSR

For our schedule debugging and file system seminars
(including our new fs mini-filter seminar) visit:
http://www.osr.com/seminars

You are currently subscribed to ntfsd as:
xxxxx@yahoo.com
To unsubscribe send a blank email to
xxxxx@lists.osr.com

Are you including specstrings.h before you include fltUserStructures.h?
Additionally, there are sometimes multiple versions of this evil file
lying around, and they can be quite different, so you need to be sure
that you are picking up the right one.

Otherwise, how about posting the actual compiler error.

Good luck,

mm

gary clark wrote:

Hello,

I’m trying to build an application using Visual
Studio 2008 on Vista that
uses the fltUserStructures.h from the ddk6000.

The file contents of fltUserStructures.h differ from
that was XP. I’m having difficulty compiling the
following:

typedef
_struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION) *
InstanceNameLength) struct
_INSTANCE_BASIC_INFORMATION
{
ULONG NextEntryOffset;
USHORT InstanceNameLength;
USHORT InstanceNameBufferOffset;

}INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;

Its stating INSTANCE_BASIC_INFORMATION undeclared.

Any ideas?

Thanks,
Garyc
> —
> NTFSD is sponsored by OSR
>
> For our schedule debugging and file system seminars
> (including our new fs mini-filter seminar) visit:
> http://www.osr.com/seminars
>
> You are currently subscribed to ntfsd as:
> xxxxx@yahoo.com
> To unsubscribe send a blank email to
> xxxxx@lists.osr.com
>

Hello,

I’m getting exactly the same as this guy:

http://www.osronline.com/ShowThread.cfm?link=104885

Its a wee bit unclear on what the exact solution is
and I’m hoping somebody can shed some light on this.

Thanks,
garyc

— Martin O’Brien wrote:

> Are you including specstrings.h before you include
> fltUserStructures.h?
> Additionally, there are sometimes multiple
> versions of this evil file
> lying around, and they can be quite different, so
> you need to be sure
> that you are picking up the right one.
>
> Otherwise, how about posting the actual compiler
> error.
>
> Good luck,
>
> mm
>
>
> gary clark wrote:
> >
> > Hello,
> >
> > I’m trying to build an application using Visual
> > Studio 2008 on Vista that
> > uses the fltUserStructures.h from the ddk6000.
> >
> > The file contents of fltUserStructures.h differ
> from
> > that was XP. I’m having difficulty compiling the
> > following:
> >
> > typedef
> > _struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION)
> *
> > InstanceNameLength) struct
> > _INSTANCE_BASIC_INFORMATION
> > {
> > ULONG NextEntryOffset;
> > USHORT InstanceNameLength;
> > USHORT InstanceNameBufferOffset;
> >
> >
>
}INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;
> >
> > Its stating INSTANCE_BASIC_INFORMATION
> undeclared.
> >
> > Any ideas?
> >
> > Thanks,
> > Garyc
> >> —
> >> NTFSD is sponsored by OSR
> >>
> >> For our schedule debugging and file system
> seminars
> >> (including our new fs mini-filter seminar) visit:
>
> >> http://www.osr.com/seminars
> >>
> >> You are currently subscribed to ntfsd as:
> >> xxxxx@yahoo.com
> >> To unsubscribe send a blank email to
> >> xxxxx@lists.osr.com
> >>
> >
> >
>
> —
> NTFSD is sponsored by OSR
>
> For our schedule debugging and file system seminars
> (including our new fs mini-filter seminar) visit:
> http://www.osr.com/seminars
>
> You are currently subscribed to ntfsd as:
> xxxxx@yahoo.com
> To unsubscribe send a blank email to
> xxxxx@lists.osr.com
>

I’m confused; what does this have to do with INSTANCE_BASIC_INFORMATION?
My guess would be that you don’t have NTDDI_VERSION defined, as you
aren’t using BUILD, or perhaps because you aren’t including the
necessary files before including fltUserStructures.

It’s very hard to say what exactly causes problems like this, as you’re
trying to use these headers with a tool that weren’t designed to be used
with. This will generally results in problems which boil down to just
issues of preprocessor definitions and order of inclusion, but they
nevertheless are very tedious to solve, and unless one has dealt with a
particular problem before, there’s really no other way to solve it than
to plow your way threw it.

In my opinion, the easiest and safest way to get something like this
working is to use BUILD for the parts that use the WDK headers, and then
link your VS product against it.

Good luck,

mm

gary clark wrote:

Hello,

I’m getting exactly the same as this guy:

http://www.osronline.com/ShowThread.cfm?link=104885

Its a wee bit unclear on what the exact solution is
and I’m hoping somebody can shed some light on this.

Thanks,
garyc

— Martin O’Brien wrote:
>
>> Are you including specstrings.h before you include
>> fltUserStructures.h?
>> Additionally, there are sometimes multiple
>> versions of this evil file
>> lying around, and they can be quite different, so
>> you need to be sure
>> that you are picking up the right one.
>>
>> Otherwise, how about posting the actual compiler
>> error.
>>
>> Good luck,
>>
>> mm
>>
>>
>> gary clark wrote:
>>> Hello,
>>>
>>> I’m trying to build an application using Visual
>>> Studio 2008 on Vista that
>>> uses the fltUserStructures.h from the ddk6000.
>>>
>>> The file contents of fltUserStructures.h differ
>> from
>>> that was XP. I’m having difficulty compiling the
>>> following:
>>>
>>> typedef
>>> _struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION)
>> *
>>> InstanceNameLength) struct
>>> _INSTANCE_BASIC_INFORMATION
>>> {
>>> ULONG NextEntryOffset;
>>> USHORT InstanceNameLength;
>>> USHORT InstanceNameBufferOffset;
>>>
>>>
> }INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;
>>>
>>> Its stating INSTANCE_BASIC_INFORMATION
>> undeclared.
>>>
>>> Any ideas?
>>>
>>> Thanks,
>>> Garyc
>>>> —
>>>> NTFSD is sponsored by OSR
>>>>
>>>> For our schedule debugging and file system
>> seminars
>>>> (including our new fs mini-filter seminar) visit:
>>>> http://www.osr.com/seminars
>>>>
>>>> You are currently subscribed to ntfsd as:
>>>> xxxxx@yahoo.com
>>>> To unsubscribe send a blank email to
>>>> xxxxx@lists.osr.com
>>>>
>>>
>> —
>> NTFSD is sponsored by OSR
>>
>> For our schedule debugging and file system seminars
>> (including our new fs mini-filter seminar) visit:
>> http://www.osr.com/seminars
>>
>> You are currently subscribed to ntfsd as:
>> xxxxx@yahoo.com
>> To unsubscribe send a blank email to
>> xxxxx@lists.osr.com
>>
>
>

Hi!

Check the following settings in Visual Studio:

  1. Target platform and OS.
  2. Include directory.
  3. Lib directory.

Regards,
Ayush Gupta

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of gary clark
Sent: Wednesday, December 05, 2007 3:36 AM
To: Windows File Systems Devs Interest List
Subject: [ntfsd] Vista Problems with Visual Studio?

Hello,

I’m trying to build an application using Visual
Studio 2008 on Vista that
uses the fltUserStructures.h from the ddk6000.

The file contents of fltUserStructures.h differ from
that was XP. I’m having difficulty compiling the
following:

typedef
_struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION) *
InstanceNameLength) struct
_INSTANCE_BASIC_INFORMATION
{
ULONG NextEntryOffset;
USHORT InstanceNameLength;
USHORT InstanceNameBufferOffset;

}INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;

Its stating INSTANCE_BASIC_INFORMATION undeclared.

Any ideas?

Thanks,
Garyc


NTFSD is sponsored by OSR

For our schedule debugging and file system seminars
(including our new fs mini-filter seminar) visit:
http://www.osr.com/seminars

You are currently subscribed to ntfsd as:
xxxxx@yahoo.com
To unsubscribe send a blank email to
xxxxx@lists.osr.com


NTFSD is sponsored by OSR

For our schedule debugging and file system seminars
(including our new fs mini-filter seminar) visit:
http://www.osr.com/seminars

You are currently subscribed to ntfsd as: xxxxx@yahoo.co.in
To unsubscribe send a blank email to xxxxx@lists.osr.com

And that thread provided the poster with two ways to get this to work. One
from me:

“In my experience this is just asking for build trouble. To combine
components from the VS build environment and the DDK build environment use a
library and header file of your own built with the DDK and used by VS. The
library uses the DDK headers, the VS components use your header and the
library.”

And another solution from Bill Leimkuehler:

"I have had success using VS .NET 2005 (and I think 2003 as well) to build
our
user-mode service. Also, include only fltuser.h as that also includes
fltuserstructures.h.

Here are the macros I define:

// This is a WIN32 program, in case you didn’t know
#ifndef _WIN32
#define _WIN32
#endif

#define WINVER 0x500
#define _WIN32_WINNT 0x0500
#define NTDDI_VERSION NTDDI_WIN2KSP4"

I’ll stick with my answer: build ddk components using the ddk compiler and
build.exe. Use those tools to build an interface library that you can call
from your visual studio build services and applications. Fewer headaches,
less hackage, everything under your control.

On Dec 4, 2007 7:28 PM, gary clark wrote:

> Hello,
>
> I’m getting exactly the same as this guy:
>
> http://www.osronline.com/ShowThread.cfm?link=104885
>
> Its a wee bit unclear on what the exact solution is
> and I’m hoping somebody can shed some light on this.
>
> Thanks,
> garyc
>
> — Martin O’Brien wrote:
>
> > Are you including specstrings.h before you include
> > fltUserStructures.h?
> > Additionally, there are sometimes multiple
> > versions of this evil file
> > lying around, and they can be quite different, so
> > you need to be sure
> > that you are picking up the right one.
> >
> > Otherwise, how about posting the actual compiler
> > error.
> >
> > Good luck,
> >
> > mm
> >
> >
> > gary clark wrote:
> > >
> > > Hello,
> > >
> > > I’m trying to build an application using Visual
> > > Studio 2008 on Vista that
> > > uses the fltUserStructures.h from the ddk6000.
> > >
> > > The file contents of fltUserStructures.h differ
> > from
> > > that was XP. I’m having difficulty compiling the
> > > following:
> > >
> > > typedef
> > > _struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION)
> > *
> > > InstanceNameLength) struct
> > > _INSTANCE_BASIC_INFORMATION
> > > {
> > > ULONG NextEntryOffset;
> > > USHORT InstanceNameLength;
> > > USHORT InstanceNameBufferOffset;
> > >
> > >
> >
> }INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;
> > >
> > > Its stating INSTANCE_BASIC_INFORMATION
> > undeclared.
> > >
> > > Any ideas?
> > >
> > > Thanks,
> > > Garyc
> > >> —
> > >> NTFSD is sponsored by OSR
> > >>
> > >> For our schedule debugging and file system
> > seminars
> > >> (including our new fs mini-filter seminar) visit:
> >
> > >> http://www.osr.com/seminars
> > >>
> > >> You are currently subscribed to ntfsd as:
> > >> xxxxx@yahoo.com
> > >> To unsubscribe send a blank email to
> > >> xxxxx@lists.osr.com
> > >>
> > >
> > >
> >
> > —
> > NTFSD is sponsored by OSR
> >
> > For our schedule debugging and file system seminars
> > (including our new fs mini-filter seminar) visit:
> > http://www.osr.com/seminars
> >
> > You are currently subscribed to ntfsd as:
> > xxxxx@yahoo.com
> > To unsubscribe send a blank email to
> > xxxxx@lists.osr.com
> >
>
>
> —
> NTFSD is sponsored by OSR
>
> For our schedule debugging and file system seminars
> (including our new fs mini-filter seminar) visit:
> http://www.osr.com/seminars
>
> You are currently subscribed to ntfsd as: xxxxx@hollistech.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com
>


Mark Roddy

Yes Mark. I agree its proving to be cumbersome to
attempt to pull in the DDK headers directly. I’m going
ahead to build my own library within the DDK to wrap
the necessary calls and then pull in that library and
my own header files.

One big qualm is changing apis from versions of ddk.
Not a good policy,confusing and annoying. At least
they should make it transparent so that the previous
application should not have to change instead of
jumping through the hoops.

Thanks,
Garyc
— Mark Roddy wrote:

> And that thread provided the poster with two ways to
> get this to work. One
> from me:
>
> “In my experience this is just asking for build
> trouble. To combine
> components from the VS build environment and the DDK
> build environment use a
> library and header file of your own built with the
> DDK and used by VS. The
> library uses the DDK headers, the VS components use
> your header and the
> library.”
>
> And another solution from Bill Leimkuehler:
>
> “I have had success using VS .NET 2005 (and I think
> 2003 as well) to build
> our
> user-mode service. Also, include only fltuser.h as
> that also includes
> fltuserstructures.h.
>
> Here are the macros I define:
>
> // This is a WIN32 program, in case you didn’t know
> #ifndef _WIN32
> #define _WIN32
> #endif
>
>
> #define WINVER 0x500
> #define _WIN32_WINNT 0x0500
> #define NTDDI_VERSION NTDDI_WIN2KSP4”
>
> I’ll stick with my answer: build ddk components
> using the ddk compiler and
> build.exe. Use those tools to build an interface
> library that you can call
> from your visual studio build services and
> applications. Fewer headaches,
> less hackage, everything under your control.
>
>
>
>
>
> On Dec 4, 2007 7:28 PM, gary clark
> wrote:
>
> > Hello,
> >
> > I’m getting exactly the same as this guy:
> >
> >
> http://www.osronline.com/ShowThread.cfm?link=104885
> >
> > Its a wee bit unclear on what the exact solution
> is
> > and I’m hoping somebody can shed some light on
> this.
> >
> > Thanks,
> > garyc
> >
> > — Martin O’Brien
> wrote:
> >
> > > Are you including specstrings.h before you
> include
> > > fltUserStructures.h?
> > > Additionally, there are sometimes multiple
> > > versions of this evil file
> > > lying around, and they can be quite different,
> so
> > > you need to be sure
> > > that you are picking up the right one.
> > >
> > > Otherwise, how about posting the actual compiler
> > > error.
> > >
> > > Good luck,
> > >
> > > mm
> > >
> > >
> > > gary clark wrote:
> > > >
> > > > Hello,
> > > >
> > > > I’m trying to build an application using
> Visual
> > > > Studio 2008 on Vista that
> > > > uses the fltUserStructures.h from the
> ddk6000.
> > > >
> > > > The file contents of fltUserStructures.h
> differ
> > > from
> > > > that was XP. I’m having difficulty compiling
> the
> > > > following:
> > > >
> > > > typedef
> > > >
> _struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION)
> > > *
> > > > InstanceNameLength) struct
> > > > _INSTANCE_BASIC_INFORMATION
> > > > {
> > > > ULONG NextEntryOffset;
> > > > USHORT InstanceNameLength;
> > > > USHORT InstanceNameBufferOffset;
> > > >
> > > >
> > >
> >
>
}INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;
> > > >
> > > > Its stating INSTANCE_BASIC_INFORMATION
> > > undeclared.
> > > >
> > > > Any ideas?
> > > >
> > > > Thanks,
> > > > Garyc
> > > >> —
> > > >> NTFSD is sponsored by OSR
> > > >>
> > > >> For our schedule debugging and file system
> > > seminars
> > > >> (including our new fs mini-filter seminar)
> visit:
> > >
> > > >> http://www.osr.com/seminars
> > > >>
> > > >> You are currently subscribed to ntfsd as:
> > > >> xxxxx@yahoo.com
> > > >> To unsubscribe send a blank email to
> > > >> xxxxx@lists.osr.com
> > > >>
> > > >
> > > >
> > >
> > > —
> > > NTFSD is sponsored by OSR
> > >
> > > For our schedule debugging and file system
> seminars
> > > (including our new fs mini-filter seminar)
> visit:
> > > http://www.osr.com/seminars
> > >
> > > You are currently subscribed to ntfsd as:
> > > xxxxx@yahoo.com
> > > To unsubscribe send a blank email to
> > > xxxxx@lists.osr.com
> > >
> >
> >
> > —
> > NTFSD is sponsored by OSR
> >
> > For our schedule debugging and file system
> seminars
> > (including our new fs mini-filter seminar) visit:
> > http://www.osr.com/seminars
> >
> > You are currently subscribed to ntfsd as:
> xxxxx@hollistech.com
> > To unsubscribe send a blank email to
> xxxxx@lists.osr.com
> >
>
>
>
> –
> Mark Roddy
>
> —
> NTFSD is sponsored by OSR
>
> For our schedule debugging and file system seminars
> (including our new fs mini-filter seminar) visit:
> http://www.osr.com/seminars
>
> You are currently subscribed to ntfsd as:
> xxxxx@yahoo.com
> To unsubscribe send a blank email to
xxxxx@lists.osr.com

Hello,

I’ve built a library in the ddk that I’m trying to
pull into my Visual Studio project.

I seem to fail to export the functions to the Visual
Studio Project as the application fails to compile due
to undefined function. How do you export functions
from a ddk library to a Visual studio? Or could
somebody be so kind and point me to literature
detailing this.

Thanks,
Garyc
— gary clark wrote:

> Yes Mark. I agree its proving to be cumbersome to
> attempt to pull in the DDK headers directly. I’m
> going
> ahead to build my own library within the DDK to
> wrap
> the necessary calls and then pull in that library
> and
> my own header files.
>
> One big qualm is changing apis from versions of ddk.
> Not a good policy,confusing and annoying. At least
> they should make it transparent so that the previous
> application should not have to change instead of
> jumping through the hoops.
>
> Thanks,
> Garyc
> — Mark Roddy wrote:
>
> > And that thread provided the poster with two ways
> to
> > get this to work. One
> > from me:
> >
> > “In my experience this is just asking for build
> > trouble. To combine
> > components from the VS build environment and the
> DDK
> > build environment use a
> > library and header file of your own built with the
> > DDK and used by VS. The
> > library uses the DDK headers, the VS components
> use
> > your header and the
> > library.”
> >
> > And another solution from Bill Leimkuehler:
> >
> > “I have had success using VS .NET 2005 (and I
> think
> > 2003 as well) to build
> > our
> > user-mode service. Also, include only fltuser.h
> as
> > that also includes
> > fltuserstructures.h.
> >
> > Here are the macros I define:
> >
> > // This is a WIN32 program, in case you didn’t
> know
> > #ifndef _WIN32
> > #define _WIN32
> > #endif
> >
> >
> > #define WINVER 0x500
> > #define _WIN32_WINNT 0x0500
> > #define NTDDI_VERSION NTDDI_WIN2KSP4”
> >
> > I’ll stick with my answer: build ddk components
> > using the ddk compiler and
> > build.exe. Use those tools to build an interface
> > library that you can call
> > from your visual studio build services and
> > applications. Fewer headaches,
> > less hackage, everything under your control.
> >
> >
> >
> >
> >
> > On Dec 4, 2007 7:28 PM, gary clark
> > wrote:
> >
> > > Hello,
> > >
> > > I’m getting exactly the same as this guy:
> > >
> > >
> >
> http://www.osronline.com/ShowThread.cfm?link=104885
> > >
> > > Its a wee bit unclear on what the exact solution
> > is
> > > and I’m hoping somebody can shed some light on
> > this.
> > >
> > > Thanks,
> > > garyc
> > >
> > > — Martin O’Brien
> > wrote:
> > >
> > > > Are you including specstrings.h before you
> > include
> > > > fltUserStructures.h?
> > > > Additionally, there are sometimes multiple
> > > > versions of this evil file
> > > > lying around, and they can be quite different,
> > so
> > > > you need to be sure
> > > > that you are picking up the right one.
> > > >
> > > > Otherwise, how about posting the actual
> compiler
> > > > error.
> > > >
> > > > Good luck,
> > > >
> > > > mm
> > > >
> > > >
> > > > gary clark wrote:
> > > > >
> > > > > Hello,
> > > > >
> > > > > I’m trying to build an application using
> > Visual
> > > > > Studio 2008 on Vista that
> > > > > uses the fltUserStructures.h from the
> > ddk6000.
> > > > >
> > > > > The file contents of fltUserStructures.h
> > differ
> > > > from
> > > > > that was XP. I’m having difficulty
> compiling
> > the
> > > > > following:
> > > > >
> > > > > typedef
> > > > >
> > _struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION)
> > > > *
> > > > > InstanceNameLength) struct
> > > > > _INSTANCE_BASIC_INFORMATION
> > > > > {
> > > > > ULONG NextEntryOffset;
> > > > > USHORT InstanceNameLength;
> > > > > USHORT InstanceNameBufferOffset;
> > > > >
> > > > >
> > > >
> > >
> >
>
}INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;
> > > > >
> > > > > Its stating INSTANCE_BASIC_INFORMATION
> > > > undeclared.
> > > > >
> > > > > Any ideas?
> > > > >
> > > > > Thanks,
> > > > > Garyc
> > > > >> —
> > > > >> NTFSD is sponsored by OSR
> > > > >>
> > > > >> For our schedule debugging and file system
> > > > seminars
> > > > >> (including our new fs mini-filter seminar)
> > visit:
> > > >
> > > > >> http://www.osr.com/seminars
> > > > >>
> > > > >> You are currently subscribed to ntfsd as:
> > > > >> xxxxx@yahoo.com
> > > > >> To unsubscribe send a blank email to
> > > > >> xxxxx@lists.osr.com
> > > > >>
> > > > >
> > > > >
> > > >
> > > > —
> > > > NTFSD is sponsored by OSR
> > > >
> > > > For our schedule debugging and file system
> > seminars
> > > > (including our new fs mini-filter seminar)
> > visit:
> > > > http://www.osr.com/seminars
> > > >
> > > > You are currently subscribed to ntfsd as:
> > > > xxxxx@yahoo.com
> > > > To unsubscribe send a blank email to
> > > > xxxxx@lists.osr.com
> > > >
> > >
> > >
> > > —
> > > NTFSD is sponsored by OSR
> > >
> > > For our schedule debugging and file system
> > seminars
> > > (including our new fs mini-filter seminar)
> visit:
> > > http://www.osr.com/seminars
> > >
> > > You are currently subscribed to ntfsd as:
> > xxxxx@hollistech.com
> > > To unsubscribe send a blank email to
>
=== message truncated ===

What do you mean exactly? A compiler error for an undefined function
means that you need to declare in in a header file and include it. A
linker error for an undefined function could mean that you need to add
the import library to the libraries list in VS, and possibly that you
also need to declare the function as exported (__declspec(dllexport)) if
you’re building a DLL instead of a static library. I don’t use VS, so I
don’t know where to tell you to look to do the former other than the
‘Properties’ tab. As far as the later, if this is the problem, you need
to read about this MSDN.

Good luck,

mm

gary clark wrote:

Hello,

I’ve built a library in the ddk that I’m trying to
pull into my Visual Studio project.

I seem to fail to export the functions to the Visual
Studio Project as the application fails to compile due
to undefined function. How do you export functions
from a ddk library to a Visual studio? Or could
somebody be so kind and point me to literature
detailing this.

Thanks,
Garyc
— gary clark wrote:
>
>> Yes Mark. I agree its proving to be cumbersome to
>> attempt to pull in the DDK headers directly. I’m
>> going
>> ahead to build my own library within the DDK to
>> wrap
>> the necessary calls and then pull in that library
>> and
>> my own header files.
>>
>> One big qualm is changing apis from versions of ddk.
>> Not a good policy,confusing and annoying. At least
>> they should make it transparent so that the previous
>> application should not have to change instead of
>> jumping through the hoops.
>>
>> Thanks,
>> Garyc
>> — Mark Roddy wrote:
>>
>>> And that thread provided the poster with two ways
>> to
>>> get this to work. One
>>> from me:
>>>
>>> “In my experience this is just asking for build
>>> trouble. To combine
>>> components from the VS build environment and the
>> DDK
>>> build environment use a
>>> library and header file of your own built with the
>>> DDK and used by VS. The
>>> library uses the DDK headers, the VS components
>> use
>>> your header and the
>>> library.”
>>>
>>> And another solution from Bill Leimkuehler:
>>>
>>> “I have had success using VS .NET 2005 (and I
>> think
>>> 2003 as well) to build
>>> our
>>> user-mode service. Also, include only fltuser.h
>> as
>>> that also includes
>>> fltuserstructures.h.
>>>
>>> Here are the macros I define:
>>>
>>> // This is a WIN32 program, in case you didn’t
>> know
>>> #ifndef _WIN32
>>> #define _WIN32
>>> #endif
>>>
>>>
>>> #define WINVER 0x500
>>> #define _WIN32_WINNT 0x0500
>>> #define NTDDI_VERSION NTDDI_WIN2KSP4”
>>>
>>> I’ll stick with my answer: build ddk components
>>> using the ddk compiler and
>>> build.exe. Use those tools to build an interface
>>> library that you can call
>>> from your visual studio build services and
>>> applications. Fewer headaches,
>>> less hackage, everything under your control.
>>>
>>>
>>>
>>>
>>>
>>> On Dec 4, 2007 7:28 PM, gary clark
>>> wrote:
>>>
>>>> Hello,
>>>>
>>>> I’m getting exactly the same as this guy:
>>>>
>>>>
>> http://www.osronline.com/ShowThread.cfm?link=104885
>>>> Its a wee bit unclear on what the exact solution
>>> is
>>>> and I’m hoping somebody can shed some light on
>>> this.
>>>> Thanks,
>>>> garyc
>>>>
>>>> — Martin O’Brien
>>> wrote:
>>>>> Are you including specstrings.h before you
>>> include
>>>>> fltUserStructures.h?
>>>>> Additionally, there are sometimes multiple
>>>>> versions of this evil file
>>>>> lying around, and they can be quite different,
>>> so
>>>>> you need to be sure
>>>>> that you are picking up the right one.
>>>>>
>>>>> Otherwise, how about posting the actual
>> compiler
>>>>> error.
>>>>>
>>>>> Good luck,
>>>>>
>>>>> mm
>>>>>
>>>>>
>>>>> gary clark wrote:
>>>>>> Hello,
>>>>>>
>>>>>> I’m trying to build an application using
>>> Visual
>>>>>> Studio 2008 on Vista that
>>>>>> uses the fltUserStructures.h from the
>>> ddk6000.
>>>>>> The file contents of fltUserStructures.h
>>> differ
>>>>> from
>>>>>> that was XP. I’m having difficulty
>> compiling
>>> the
>>>>>> following:
>>>>>>
>>>>>> typedef
>>>>>>
>>> _struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION)
>>>>> *
>>>>>> InstanceNameLength) struct
>>>>>> _INSTANCE_BASIC_INFORMATION
>>>>>> {
>>>>>> ULONG NextEntryOffset;
>>>>>> USHORT InstanceNameLength;
>>>>>> USHORT InstanceNameBufferOffset;
>>>>>>
>>>>>>
> }INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;
>>>>>> Its stating INSTANCE_BASIC_INFORMATION
>>>>> undeclared.
>>>>>> Any ideas?
>>>>>>
>>>>>> Thanks,
>>>>>> Garyc
>>>>>>> —
>>>>>>> NTFSD is sponsored by OSR
>>>>>>>
>>>>>>> For our schedule debugging and file system
>>>>> seminars
>>>>>>> (including our new fs mini-filter seminar)
>>> visit:
>>>>>>> http://www.osr.com/seminars
>>>>>>>
>>>>>>> You are currently subscribed to ntfsd as:
>>>>>>> xxxxx@yahoo.com
>>>>>>> To unsubscribe send a blank email to
>>>>>>> xxxxx@lists.osr.com
>>>>>>>
>>>>>>
>>>>> —
>>>>> NTFSD is sponsored by OSR
>>>>>
>>>>> For our schedule debugging and file system
>>> seminars
>>>>> (including our new fs mini-filter seminar)
>>> visit:
>>>>> http://www.osr.com/seminars
>>>>>
>>>>> You are currently subscribed to ntfsd as:
>>>>> xxxxx@yahoo.com
>>>>> To unsubscribe send a blank email to
>>>>> xxxxx@lists.osr.com
>>>>>
>>>>
>>>> —
>>>> NTFSD is sponsored by OSR
>>>>
>>>> For our schedule debugging and file system
>>> seminars
>>>> (including our new fs mini-filter seminar)
>> visit:
>>>> http://www.osr.com/seminars
>>>>
>>>> You are currently subscribed to ntfsd as:
>>> xxxxx@hollistech.com
>>>> To unsubscribe send a blank email to
> === message truncated ===
>
>

Hi Martin,

I’m building a static library using ddk6000 build.exe
which wraps around the filter drivers calls.

Martin maybe this terminology just including it in the
header file does not mean its “defined”, merely that
its been declared.
When I saw the compiler error it meant that the
function was missing not the function signature.

Thanks,
Garyc

— Martin O’Brien wrote:

> What do you mean exactly? A compiler error for an
> undefined function
> means that you need to declare in in a header file
> and include it. A
> linker error for an undefined function could mean
> that you need to add
> the import library to the libraries list in VS, and
> possibly that you
> also need to declare the function as exported
> (__declspec(dllexport)) if
> you’re building a DLL instead of a static library.
> I don’t use VS, so I
> don’t know where to tell you to look to do the
> former other than the
> ‘Properties’ tab. As far as the later, if this is
> the problem, you need
> to read about this MSDN.
>
> Good luck,
>
> mm
>
> gary clark wrote:
> > Hello,
> >
> > I’ve built a library in the ddk that I’m trying to
> > pull into my Visual Studio project.
> >
> > I seem to fail to export the functions to the
> Visual
> > Studio Project as the application fails to compile
> due
> > to undefined function. How do you export functions
> > from a ddk library to a Visual studio? Or could
> > somebody be so kind and point me to literature
> > detailing this.
> >
> > Thanks,
> > Garyc
> > — gary clark wrote:
> >
> >> Yes Mark. I agree its proving to be cumbersome to
> >> attempt to pull in the DDK headers directly. I’m
> >> going
> >> ahead to build my own library within the DDK to
> >> wrap
> >> the necessary calls and then pull in that library
> >> and
> >> my own header files.
> >>
> >> One big qualm is changing apis from versions of
> ddk.
> >> Not a good policy,confusing and annoying. At
> least
> >> they should make it transparent so that the
> previous
> >> application should not have to change instead of
> >> jumping through the hoops.
> >>
> >> Thanks,
> >> Garyc
> >> — Mark Roddy wrote:
> >>
> >>> And that thread provided the poster with two
> ways
> >> to
> >>> get this to work. One
> >>> from me:
> >>>
> >>> “In my experience this is just asking for build
> >>> trouble. To combine
> >>> components from the VS build environment and the
> >> DDK
> >>> build environment use a
> >>> library and header file of your own built with
> the
> >>> DDK and used by VS. The
> >>> library uses the DDK headers, the VS components
> >> use
> >>> your header and the
> >>> library.”
> >>>
> >>> And another solution from Bill Leimkuehler:
> >>>
> >>> “I have had success using VS .NET 2005 (and I
> >> think
> >>> 2003 as well) to build
> >>> our
> >>> user-mode service. Also, include only fltuser.h
> >> as
> >>> that also includes
> >>> fltuserstructures.h.
> >>>
> >>> Here are the macros I define:
> >>>
> >>> // This is a WIN32 program, in case you didn’t
> >> know
> >>> #ifndef _WIN32
> >>> #define _WIN32
> >>> #endif
> >>>
> >>>
> >>> #define WINVER 0x500
> >>> #define _WIN32_WINNT 0x0500
> >>> #define NTDDI_VERSION NTDDI_WIN2KSP4”
> >>>
> >>> I’ll stick with my answer: build ddk components
> >>> using the ddk compiler and
> >>> build.exe. Use those tools to build an interface
> >>> library that you can call
> >>> from your visual studio build services and
> >>> applications. Fewer headaches,
> >>> less hackage, everything under your control.
> >>>
> >>>
> >>>
> >>>
> >>>
> >>> On Dec 4, 2007 7:28 PM, gary clark
> >>> wrote:
> >>>
> >>>> Hello,
> >>>>
> >>>> I’m getting exactly the same as this guy:
> >>>>
> >>>>
> >>
> http://www.osronline.com/ShowThread.cfm?link=104885
> >>>> Its a wee bit unclear on what the exact
> solution
> >>> is
> >>>> and I’m hoping somebody can shed some light on
> >>> this.
> >>>> Thanks,
> >>>> garyc
> >>>>
> >>>> — Martin O’Brien
> >>> wrote:
> >>>>> Are you including specstrings.h before you
> >>> include
> >>>>> fltUserStructures.h?
> >>>>> Additionally, there are sometimes multiple
> >>>>> versions of this evil file
> >>>>> lying around, and they can be quite different,
> >>> so
> >>>>> you need to be sure
> >>>>> that you are picking up the right one.
> >>>>>
> >>>>> Otherwise, how about posting the actual
> >> compiler
> >>>>> error.
> >>>>>
> >>>>> Good luck,
> >>>>>
> >>>>> mm
> >>>>>
> >>>>>
> >>>>> gary clark wrote:
> >>>>>> Hello,
> >>>>>>
> >>>>>> I’m trying to build an application using
> >>> Visual
> >>>>>> Studio 2008 on Vista that
> >>>>>> uses the fltUserStructures.h from the
> >>> ddk6000.
> >>>>>> The file contents of fltUserStructures.h
> >>> differ
> >>>>> from
> >>>>>> that was XP. I’m having difficulty
> >> compiling
> >>> the
> >>>>>> following:
> >>>>>>
> >>>>>> typedef
> >>>>>>
> >>>
> _struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION)
> >>>>> *
> >>>>>> InstanceNameLength) struct
> >>>>>> _INSTANCE_BASIC_INFORMATION
> >>>>>> {
> >>>>>> ULONG NextEntryOffset;
> >>>>>> USHORT InstanceNameLength;
> >>>>>> USHORT InstanceNameBufferOffset;
> >>>>>>
> >>>>>>
> >
>
}INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;
> >>>>>> Its stating INSTANCE_BASIC_INFORMATION
> >>>>> undeclared.
> >>>>>> Any ideas?
> >>>>>>
> >>>>>> Thanks,
> >>>>>> Garyc
> >>>>>>> —
> >>>>>>> NTFSD is sponsored by OSR
> >>>>>>>
> >>>>>>> For our schedule debugging and file system
> >>>>> seminars
> >>>>>>> (including our new fs mini-filter seminar)
> >>> visit:
>
=== message truncated ===

Linker errors usually indicate that the build system can’t find the
definition. If you’re getting a compiler error, it usually means it’s
not declared. If you posted the actual error message, we’d all be on
the same page and have a better chance of being able to help you. We
don’t need a whole build log, just a representative error from it.

If you could include a prototype from the header file, and a definition
from your library, that might help too. Feel free to take out the body
of the function if you’re worried about people seeing your code. In
fact, do it anyway, it’s probably not where the problem is coming from.

~Eric

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of gary clark
Sent: Wednesday, December 05, 2007 4:13 PM
To: Windows File Systems Devs Interest List
Subject: Re:[ntfsd] Vista Problems with Visual Studio?

Hi Martin,

I’m building a static library using ddk6000 build.exe which wraps around
the filter drivers calls.

Martin maybe this terminology just including it in the header file does
not mean its “defined”, merely that its been declared.
When I saw the compiler error it meant that the function was missing not
the function signature.

Thanks,
Garyc

— Martin O’Brien wrote:

> What do you mean exactly? A compiler error for an undefined function
> means that you need to declare in in a header file and include it. A
> linker error for an undefined function could mean that you need to add

> the import library to the libraries list in VS, and possibly that you
> also need to declare the function as exported
> (__declspec(dllexport)) if
> you’re building a DLL instead of a static library.
> I don’t use VS, so I
> don’t know where to tell you to look to do the former other than the
> ‘Properties’ tab. As far as the later, if this is the problem, you
> need to read about this MSDN.
>
> Good luck,
>
> mm
>
> gary clark wrote:
> > Hello,
> >
> > I’ve built a library in the ddk that I’m trying to pull into my
> > Visual Studio project.
> >
> > I seem to fail to export the functions to the
> Visual
> > Studio Project as the application fails to compile
> due
> > to undefined function. How do you export functions from a ddk
> > library to a Visual studio? Or could somebody be so kind and point
> > me to literature detailing this.
> >
> > Thanks,
> > Garyc
> > — gary clark wrote:
> >
> >> Yes Mark. I agree its proving to be cumbersome to attempt to pull
> >> in the DDK headers directly. I’m going ahead to build my own
> >> library within the DDK to wrap the necessary calls and then pull
> >> in that library and my own header files.
> >>
> >> One big qualm is changing apis from versions of
> ddk.
> >> Not a good policy,confusing and annoying. At
> least
> >> they should make it transparent so that the
> previous
> >> application should not have to change instead of jumping through
> >> the hoops.
> >>
> >> Thanks,
> >> Garyc
> >> — Mark Roddy wrote:
> >>
> >>> And that thread provided the poster with two
> ways
> >> to
> >>> get this to work. One
> >>> from me:
> >>>
> >>> “In my experience this is just asking for build trouble. To
> >>> combine components from the VS build environment and the
> >> DDK
> >>> build environment use a
> >>> library and header file of your own built with
> the
> >>> DDK and used by VS. The
> >>> library uses the DDK headers, the VS components
> >> use
> >>> your header and the
> >>> library.”
> >>>
> >>> And another solution from Bill Leimkuehler:
> >>>
> >>> “I have had success using VS .NET 2005 (and I
> >> think
> >>> 2003 as well) to build
> >>> our
> >>> user-mode service. Also, include only fltuser.h
> >> as
> >>> that also includes
> >>> fltuserstructures.h.
> >>>
> >>> Here are the macros I define:
> >>>
> >>> // This is a WIN32 program, in case you didn’t
> >> know
> >>> #ifndef _WIN32
> >>> #define _WIN32
> >>> #endif
> >>>
> >>>
> >>> #define WINVER 0x500
> >>> #define _WIN32_WINNT 0x0500
> >>> #define NTDDI_VERSION NTDDI_WIN2KSP4”
> >>>
> >>> I’ll stick with my answer: build ddk components using the ddk
> >>> compiler and build.exe. Use those tools to build an interface
> >>> library that you can call from your visual studio build services
> >>> and applications. Fewer headaches, less hackage, everything under
> >>> your control.
> >>>
> >>>
> >>>
> >>>
> >>>
> >>> On Dec 4, 2007 7:28 PM, gary clark wrote:
> >>>
> >>>> Hello,
> >>>>
> >>>> I’m getting exactly the same as this guy:
> >>>>
> >>>>
> >>
> http://www.osronline.com/ShowThread.cfm?link=104885
> >>>> Its a wee bit unclear on what the exact
> solution
> >>> is
> >>>> and I’m hoping somebody can shed some light on
> >>> this.
> >>>> Thanks,
> >>>> garyc
> >>>>
> >>>> — Martin O’Brien
> >>> wrote:
> >>>>> Are you including specstrings.h before you
> >>> include
> >>>>> fltUserStructures.h?
> >>>>> Additionally, there are sometimes multiple versions of this
> >>>>> evil file lying around, and they can be quite different,
> >>> so
> >>>>> you need to be sure
> >>>>> that you are picking up the right one.
> >>>>>
> >>>>> Otherwise, how about posting the actual
> >> compiler
> >>>>> error.
> >>>>>
> >>>>> Good luck,
> >>>>>
> >>>>> mm
> >>>>>
> >>>>>
> >>>>> gary clark wrote:
> >>>>>> Hello,
> >>>>>>
> >>>>>> I’m trying to build an application using
> >>> Visual
> >>>>>> Studio 2008 on Vista that
> >>>>>> uses the fltUserStructures.h from the
> >>> ddk6000.
> >>>>>> The file contents of fltUserStructures.h
> >>> differ
> >>>>> from
> >>>>>> that was XP. I’m having difficulty
> >> compiling
> >>> the
> >>>>>> following:
> >>>>>>
> >>>>>> typedef
> >>>>>>
> >>>
> _struct_bcount(sizeof(INSTANCE_BASIC_INFORMATION)
> >>>>> *
> >>>>>> InstanceNameLength) struct
> >>>>>> _INSTANCE_BASIC_INFORMATION
> >>>>>> {
> >>>>>> ULONG NextEntryOffset;
> >>>>>> USHORT InstanceNameLength;
> >>>>>> USHORT InstanceNameBufferOffset;
> >>>>>>
> >>>>>>
> >
>
}INSTANCE_BASIC_INFORMATION,*PINSTANCE_BASIC_INFORMATION;
> >>>>>> Its stating INSTANCE_BASIC_INFORMATION
> >>>>> undeclared.
> >>>>>> Any ideas?
> >>>>>>
> >>>>>> Thanks,
> >>>>>> Garyc
> >>>>>>> —
> >>>>>>> NTFSD is sponsored by OSR
> >>>>>>>
> >>>>>>> For our schedule debugging and file system
> >>>>> seminars
> >>>>>>> (including our new fs mini-filter seminar)
> >>> visit:
>
=== message truncated ===


NTFSD is sponsored by OSR

For our schedule debugging and file system seminars (including our new
fs mini-filter seminar) visit:
http://www.osr.com/seminars

You are currently subscribed to ntfsd as: xxxxx@edsiohio.com To
unsubscribe send a blank email to xxxxx@lists.osr.com