[Cmake] FIND_FILE

Andy Cedilnik andy . cedilnik at kitware . com
25 Jun 2003 07:13:37 -0400


Hi Neil,


On Wed, 2003-06-25 at 00:42, Neil Killeen wrote:
> 1) Only those paths which are specified with an absolute path work.  This
> is ok as I know where I am in the tree, but I dont see why relative paths
> should not work.

Relative paths from where? Source tree? Binary tree? Toplevel source
tree? Starting source tree?

How about this:

FIND_FILES(MYNAMES foo.latex ${CMAKE_CURRENT_SOURCE_DIR}/something)

> 2) Is it possible to wild card and find reecursively ?  I would really like to find
> the names of ALL files underneath the working directory with the
> given wildcarded name.  E.g.
> 
> FIND_FILES (MYNAMES *.latex .)
> 
> Even with an absolute path e.g.
> 
> FIND_FILE (MYNAME3 *.latex /DATA/ELARA_3/mitk/Source/Code/Composite/Applications)
> 
> (where there are many directories beneath Applications) would be ok.  I
> have tried many syntaxes with no joy.
> 
> What I am trying to do is automatically build an index of application
> documentation.

What you really want is something like 

GIVE_ME_LIST_OF_FILES(FILES expression [ expression ])

I think this will be part of file command and is on the way to be in
1.8.

				Andy