copy_files

The copy_files and copy_files# stanzas specify that files from another directory could be copied to the current directory, if needed.

The syntax is as follows:

(copy_files
 <optional-fields>
 (files <glob>))

<glob> represents the set of files to copy. See the glob for details.

<optional-fields> are:

  • (alias <alias-name>) specifies an alias to which to attach the targets.

  • (mode <mode>) specifies how to handle the targets. See Modes for details.

  • (enabled_if <blang expression>) conditionally disables this stanza. The condition is specified using the Boolean Language.

  • (only_sources <blang expression>) specifies that the glob in files gets applied over the source tree, and not the build tree.

The short form:

(copy_files <glob>)

is equivalent to:

(copy_files (files <glob>))

The difference between copy_files and copy_files# is the same as the difference between the copy and copy# actions. See Actions section for more details.