4.5.1 Finding Files: The glob Method

The glob method can be used to find files matching the patterns specified. It supports a syntax similar to the Ruby Dir.glob method but operates more deterministically (results are ordered based on file names rather than file system directory ordering).

Example use:

env do |env|
  env.Program("mytests", glob("src/**/*.cc", "test/**/*.cc"))
end

This example would build the mytests executable from all .cc source files found recursively under the src or test directory.