packaging: Initial packaging
[platform/upstream/cmake.git] / Source / cmSetSourceFilesPropertiesCommand.h
1 /*============================================================================
2   CMake - Cross Platform Makefile Generator
3   Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
4
5   Distributed under the OSI-approved BSD License (the "License");
6   see accompanying file Copyright.txt for details.
7
8   This software is distributed WITHOUT ANY WARRANTY; without even the
9   implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10   See the License for more information.
11 ============================================================================*/
12 #ifndef cmSetSourceFilesPropertiesCommand_h
13 #define cmSetSourceFilesPropertiesCommand_h
14
15 #include "cmCommand.h"
16
17 class cmSetSourceFilesPropertiesCommand : public cmCommand
18 {
19 public:
20   virtual cmCommand* Clone()
21     {
22       return new cmSetSourceFilesPropertiesCommand;
23     }
24
25   /**
26    * This is called when the command is first encountered in
27    * the input file.
28    */
29   virtual bool InitialPass(std::vector<std::string> const& args,
30                            cmExecutionStatus &status);
31
32   /**
33    * The name of the command as specified in CMakeList.txt.
34    */
35   virtual const char* GetName() const { return "set_source_files_properties";}
36
37   /**
38    * Succinct documentation.
39    */
40   virtual const char* GetTerseDocumentation() const
41     {
42     return "Source files can have properties that affect how they are built.";
43     }
44
45   /**
46    * Longer documentation.
47    */
48   virtual const char* GetFullDocumentation() const
49     {
50       return
51         "  set_source_files_properties([file1 [file2 [...]]]\n"
52         "                              PROPERTIES prop1 value1\n"
53         "                              [prop2 value2 [...]])\n"
54         "Set properties associated with source files using a key/value "
55         "paired list.  "
56         "See properties documentation for those known to CMake.  "
57         "Unrecognized properties are ignored.  "
58         "Source file properties are visible only to targets "
59         "added in the same directory (CMakeLists.txt).";
60     }
61
62   cmTypeMacro(cmSetSourceFilesPropertiesCommand, cmCommand);
63
64   static bool RunCommand(cmMakefile *mf,
65                          std::vector<std::string>::const_iterator filebeg,
66                          std::vector<std::string>::const_iterator fileend,
67                          std::vector<std::string>::const_iterator propbeg,
68                          std::vector<std::string>::const_iterator propend,
69                          std::string &errors);
70 };
71
72
73
74 #endif