source: CMT/v1r10p20011126/src/cmt_parser.h @ 1

Last change on this file since 1 was 1, checked in by arnault, 19 years ago

Import all tags

File size: 6.4 KB
Line 
1#ifndef __cmt_parser_h__
2#define __cmt_parser_h__
3
4/*
5  Generation of shell scripts :
6  We consider for the moment only csh and sh
7  */
8typedef enum
9{
10  Csh,
11  Sh,
12  Bat,
13  Make
14} PrintMode;
15
16typedef enum
17{
18  mgr_style,
19  cmt_style,
20  none_style
21} CmtDirStyle;
22
23/*
24  Commands correspond to keywords in the requirements file.
25  */
26typedef enum
27{
28  CommandNone,
29  CommandAlias,            /* alias            */
30  CommandApplication,      /* application      */
31  CommandApplyPattern,     /* apply_pattern    */
32  CommandAuthor,           /* author           */
33  CommandBranches,         /* branch           */
34  CommandBuildStrategy,    /* build strategy   */
35  CommandCleanupScript,    /* user script      */
36  CommandDocument,         /* document         */
37  CommandIgnorePattern,    /* ignore_pattern   */
38  CommandIncludeDirs,      /* include_dirs     */
39  CommandIncludePath,      /* include_path     */
40  CommandLanguage,         /* language         */
41  CommandLibrary,          /* library          */
42  CommandMacro,            /* macro            */
43  CommandMacroPrepend,     /* +macro           */
44  CommandMacroAppend,      /* macro+           */
45  CommandMacroRemove,      /* macro-           */
46  CommandMacroRemoveAll,   /* macro--          */
47  CommandMakeFragment,     /* make_fragment    */
48  CommandManager,          /* package manager  */
49  CommandPackage,          /* package name     */
50  CommandPath,             /* package path     */
51  CommandPathAppend,       /* path             */
52  CommandPathPrepend,      /* path             */
53  CommandPathRemove,       /* path             */
54  CommandPattern,          /* pattern          */
55  CommandPrivate,          /* private          */
56  CommandPublic,           /* public           */
57  CommandSet,              /* set              */
58  CommandSetAppend,        /* set_append       */
59  CommandSetPrepend,       /* set_prepend      */
60  CommandSetRemove,        /* set_remove       */
61  CommandSetupScript,      /* user script      */
62  CommandTag,              /* tag              */
63  CommandTagExclude,       /* tag_exclude      */
64  CommandUse,              /* use              */
65  CommandVersion,          /* package version  */
66  CommandVersionStrategy,  /* version strategy */
67  Commands
68} CommandType;
69
70/*
71  The scope is modified while the requirements file is read
72  when the keywords public or private are met.
73  It is also set to public when a used requirements file is read.
74  */
75
76typedef enum
77{
78  DeveloperMode,
79  UserMode
80} AccessMode;
81
82typedef enum
83{
84  ScopeUnspecified,
85  ScopePublic,
86  ScopePrivate
87} ScopeType;
88
89typedef enum
90{
91  PriorityLowest = 0,
92  PriorityDefault = 1,
93  PriorityUname = 2,
94  PrioritySite = 3,
95  PriorityUserTag = 4,
96  PriorityTag = 5,
97  PriorityConfig = 6,
98  PriorityArgument = 7
99} Priority;
100
101typedef enum
102{
103  SetupScript,
104  CleanupScript
105} ScriptType;
106
107typedef enum
108{
109  BestFit,            // The current default
110  BestFitNoCheck,     // The current default without compatibility check
111  FirstChoice,        // The first reference will not be overridden
112  LastChoice,         // The last reference wins
113  KeepAll,            // Keep all uses
114
115  Strategies
116} VersionStrategy;
117
118//
119// Build strategy is a mix of various options
120//  + predefined values should be multiples of 2^n
121//  + effective value is an OR of these options
122//  + all options should be specified inthis enum as pairs
123//    of <option> - no<option>. One of them being preset to zero
124//    (which represents the default) the other being set to a unique 2^n value.
125//
126typedef enum
127{
128  PrototypesMask = 0x1,
129  Prototypes = 0x0,
130  NoPrototypes = PrototypesMask,
131
132  KeepMakefilesMask = 0x2,
133  RebuildMakefiles = 0x0,
134  KeepMakefiles = KeepMakefilesMask,
135
136  DefaultBuildStrategy = Prototypes | RebuildMakefiles
137} BuildStrategy;
138
139typedef enum
140{
141  Application,
142  Library,
143  Document
144} ConstituentType;
145
146/*
147  Command line action
148  */
149typedef enum
150{
151  action_none,
152  action_broadcast,
153
154  action_build_constituent_makefile,
155  action_build_constituents_makefile,
156  action_build_dependencies,
157  action_build_library_links,
158  action_build_make_setup,
159  action_build_msdev,
160  action_build_os9_makefile,
161  action_build_prototype,
162  action_build_readme,
163  action_build_tag_makefile,
164  action_build_temporary_name,
165  action_build_triggers,
166  action_build_windefs,
167
168  action_check_configuration,
169  action_check_files,
170  action_check_version,
171  action_checkout,          // HSG - add to handle the checkout command
172  action_cleanup,
173  action_config,
174  action_create,
175  action_cvsbranches,
176  action_cvssubpackages,
177  action_cvstags,
178  action_expand_model,
179  action_filter,            // CA  - handle free text filtering
180  action_help,
181  action_load,
182  action_lock,
183  action_remove,
184  action_remove_library_links,
185  action_run,
186  action_setup,
187
188  action_show_author,                // s a
189  action_show_branches,              // s b
190  action_show_clients,               // s cl
191  action_show_constituent,
192  action_show_constituent_names,     // s c...
193  action_show_constituents,          // s c...
194  action_show_fragment,              // s f
195  action_show_fragments,             // s fragments
196  action_show_groups,                // s groups
197  action_show_include_dirs,
198  action_show_language,              // s l
199  action_show_languages,             // s languages
200  action_show_macro,                 // s m
201  action_show_macro_value,           // s macro_value
202  action_show_macros,                // s macros
203  action_show_manager,               // s manager
204  action_show_packages,              // s packages
205  action_show_path,                  // s path
206  action_show_pattern,
207  action_show_pattern_names,
208  action_show_patterns,
209  action_show_pwd,                   // s pwd
210  action_show_set,                   // s s
211  action_show_set_value,             // s set_value
212  action_show_sets,                  // s sets
213  action_show_strategies,            // s strategies
214  action_show_tags,                  // s tags
215  action_show_uses,                  // s u
216  action_show_version,               // s version
217  action_show_versions,              // s versions
218
219  action_system,
220  action_unlock,
221  action_version
222} ActionType;
223
224#define SLASH '/'
225
226class Use;
227typedef Use* UseRef;
228
229#include "cmt_std.h"
230#include "cmt_string.h"
231#include "cmt_vector.h"
232#include "cmt.h"
233
234#endif
Note: See TracBrowser for help on using the repository browser.