- Rewrite Buffer object to maintain only write pointer. There is no
[dragonfly.git] / usr.bin / make / globals.h
1 #ifndef globals_h_1c1edb96
2 #define globals_h_1c1edb96
3 /*
4  * Copyright (c) 2004, 2005 by Max Okumoto
5  * All rights reserved.
6  *
7  * This code is derived from software contributed to Berkeley by
8  * Adam de Boor.
9  *
10  * Redistribution and use in source and binary forms, with or without
11  * modification, are permitted provided that the following conditions
12  * are met:
13  * 1. Redistributions of source code must retain the above copyright
14  *    notice, this list of conditions and the following disclaimer.
15  * 2. Redistributions in binary form must reproduce the above copyright
16  *    notice, this list of conditions and the following disclaimer in the
17  *    documentation and/or other materials provided with the distribution.
18  * 3. All advertising materials mentioning features or use of this software
19  *    must display the following acknowledgement:
20  *      This product includes software developed by the University of
21  *      California, Berkeley and its contributors.
22  * 4. Neither the name of the University nor the names of its contributors
23  *    may be used to endorse or promote products derived from this software
24  *    without specific prior written permission.
25  *
26  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
27  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
28  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
29  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
30  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
31  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36  * SUCH DAMAGE.
37  *
38  * $DragonFly: src/usr.bin/make/globals.h,v 1.1 2005/01/06 11:41:47 okumoto Exp $
39  */
40
41 /*
42  * Global Variables
43  */
44
45 #include <time.h>
46
47 #include "lst.h"
48 #include "parse.h"
49 #include "sprite.h"
50
51 struct GNode;
52
53 /*
54  * The list of target names specified on the command line.
55  * Used to resolve #if make(...) statements
56  */
57 extern Lst create;
58
59 /* The list of directories to search when looking for targets */
60 extern Lst dirSearchPath;
61
62 extern IFile    curFile;        /* current makefile */
63
64 /* The list of directories to search when looking for includes */
65 extern Lst parseIncPath;
66
67 extern Boolean  jobsRunning;    /* True if jobs are running */
68 extern Boolean  compatMake;     /* True if we are make compatible */
69 extern Boolean  ignoreErrors;   /* True if should ignore all errors */
70 extern Boolean  beSilent;       /* True if should print no commands */
71 extern Boolean  beVerbose;      /* True if should print extra cruft */
72 extern Boolean  noExecute;      /* True if should execute nothing */
73 extern Boolean  allPrecious;    /* True if every target is precious */
74 extern Boolean  keepgoing;      /* True if should continue on unaffected
75                                  * portions of the graph when have an error
76                                  * in one portion */
77 extern Boolean  touchFlag;      /* TRUE if targets should just be 'touched'
78                                  * if out of date. Set by the -t flag */
79 extern Boolean  usePipes;       /* TRUE if should capture the output of
80                                  * subshells by means of pipes. Otherwise it
81                                  * is routed to temporary files from which it
82                                  * is retrieved when the shell exits */
83 extern Boolean  queryFlag;      /* TRUE if we aren't supposed to really make
84                                  * anything, just see if the targets are out-
85                                  * of-date */
86
87 extern Boolean  checkEnvFirst;  /* TRUE if environment should be searched for
88                                  * all variables before the global context */
89
90 /* List of specific variables for which the environment should be
91  * searched before the global context */
92 extern Lst envFirstVars;
93
94 extern struct GNode     *DEFAULT;       /* .DEFAULT rule */
95
96 extern struct GNode     *VAR_GLOBAL;    /* Variables defined in a global context, e.g
97                                          * in the Makefile itself */
98
99 extern struct GNode     *VAR_CMD;       /* Variables defined on the command line */
100
101 extern char     var_Error[];    /* Value returned by Var_Parse when an error
102                                  * is encountered. It actually points to
103                                  * an empty string, so naive callers needn't
104                                  * worry about it. */
105
106 extern time_t   now;            /* The time at the start of this whole
107                                  * process */
108
109 extern Boolean  oldVars;        /* Do old-style variable substitution */
110
111 /* The system include path. */
112 extern Lst      sysIncPath;
113
114 extern int debug;
115
116 #endif /* globals_h_1c1edb96 */