sources file

Hi ,
If i have source files in multiple directories, can i know how to
add all of them in the *sources *file for building.

Thanks & Regards
ajay kumar v

If you have sources files in different directories, you need to add all the directories in the top level dir file and compile your source code.

If you have more than one folder, you need to mention the directories to be involved in the build and in each directory there should be sources file to mention the files to compile or build.

regards
Nisheedh

ajay kumar v wrote:

If i have source files in multiple directories, can i know how to
add all of them in the *sources *file for building.

You don’t. Each directory gets its own “sources” file, and each one
builds a .lib library. The final “sources” file then links to those
other libraries.


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

A sources file can reference files in the parent directory (i.e., you
can have “…” in the source file’s path). Whether this is of any use
depends on your goal. I have a driver which consists of both system-
dependent and system-independent files. I segregated all of the
system-dependent files into a subdirectory and have that
subdirectory’s sources file reference the system-independent files in
the parent directory.

-John

On Mar 20, 2009, at 9:50 AM, Tim Roberts wrote:

ajay kumar v wrote:
>
> If i have source files in multiple directories, can i know how to
> add all of them in the *sources *file for building.

Indeed. A number of wdk samples use this paradigm. If I recall correctly, it’s common among the
ndis samples.

mm

John Kraft wrote:

A sources file can reference files in the parent directory (i.e., you
can have “…” in the source file’s path). Whether this is of any use
depends on your goal. I have a driver which consists of both
system-dependent and system-independent files. I segregated all of the
system-dependent files into a subdirectory and have that subdirectory’s
sources file reference the system-independent files in the parent
directory.

-John

On Mar 20, 2009, at 9:50 AM, Tim Roberts wrote:

> ajay kumar v wrote:
>>
>> If i have source files in multiple directories, can i know how to
>> add all of them in the *sources *file for building.
>

Thank you guys, it really helped me …

Regards
ajay kumar v

Tim Roberts wrote:

ajay kumar v wrote:

> If i have source files in multiple directories, can i know how to
> add all of them in the *sources *file for building.
>

You don’t. Each directory gets its own “sources” file, and each one
builds a .lib library. The final “sources” file then links to those
other libraries.