globals.h revision 167330
179265Sdillon/*- 279265Sdillon * Copyright (c) 1988, 1989, 1990, 1993 379265Sdillon * The Regents of the University of California. All rights reserved. 479265Sdillon * Copyright (c) 1989 by Berkeley Softworks 579265Sdillon * All rights reserved. 679265Sdillon * 779265Sdillon * This code is derived from software contributed to Berkeley by 879265Sdillon * Adam de Boor. 979265Sdillon * 1079265Sdillon * Redistribution and use in source and binary forms, with or without 1179265Sdillon * modification, are permitted provided that the following conditions 1279265Sdillon * are met: 1379265Sdillon * 1. Redistributions of source code must retain the above copyright 1479265Sdillon * notice, this list of conditions and the following disclaimer. 1582314Speter * 2. Redistributions in binary form must reproduce the above copyright 1679265Sdillon * notice, this list of conditions and the following disclaimer in the 1782314Speter * documentation and/or other materials provided with the distribution. 1879265Sdillon * 3. All advertising materials mentioning features or use of this software 1982314Speter * must display the following acknowledgement: 2079265Sdillon * This product includes software developed by the University of 2179265Sdillon * California, Berkeley and its contributors. 2282314Speter * 4. Neither the name of the University nor the names of its contributors 2379265Sdillon * may be used to endorse or promote products derived from this software 2479265Sdillon * without specific prior written permission. 2579265Sdillon * 2679265Sdillon * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 2779265Sdillon * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 2879265Sdillon * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 2979265Sdillon * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 3079265Sdillon * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 3179265Sdillon * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 3279265Sdillon * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 3399571Speter * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 3482314Speter * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 3582314Speter * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 3682314Speter * SUCH DAMAGE. 3782314Speter * 3882314Speter * $FreeBSD: head/usr.bin/make/globals.h 167330 2007-03-08 09:16:11Z fjoe $ 3982314Speter */ 4082314Speter 4179265Sdillon#ifndef globals_h_1c1edb96 4279265Sdillon#define globals_h_1c1edb96 4379265Sdillon 4479265Sdillon/* 4579265Sdillon * Global Variables 4679265Sdillon */ 4779265Sdillon 4882314Speter#include <time.h> 4982314Speter#include <stdint.h> 5082314Speter 5182314Speter#include "lst.h" 5279265Sdillon#include "util.h" 5379265Sdillon 5482314Speterstruct GNode; 5582314Speterstruct Path; 5679265Sdillon 5779265Sdillon/* 5879265Sdillon * The list of target names specified on the command line. 5979265Sdillon * Used to resolve #if make(...) statements 6079265Sdillon */ 6179265Sdillonextern Lst create; 6279265Sdillon 6379265Sdillon/* The list of directories to search when looking for targets */ 6479265Sdillonextern struct Path dirSearchPath; 6582314Speter 6679265Sdillon/* The list of directories to search when looking for includes */ 6782314Speterextern struct Path parseIncPath; 6882314Speter 6982314Speter/* The system include path. */ 7079265Sdillonextern struct Path sysIncPath; 7182314Speter 7282314Speterextern int jobLimit; /* -j argument: maximum number of jobs */ 7382314Speterextern Boolean jobsRunning; /* True if jobs are running */ 7482314Speterextern Boolean compatMake; /* True if we are make compatible */ 7582314Speterextern Boolean ignoreErrors; /* True if should ignore all errors */ 7682314Speterextern Boolean beSilent; /* True if should print no commands */ 7799625Speterextern Boolean beVerbose; /* True if should print extra cruft */ 7882314Speterextern Boolean noExecute; /* True if should execute nothing */ 7982314Speterextern Boolean allPrecious; /* True if every target is precious */ 8082314Speterextern Boolean is_posix; /* .POSIX target seen */ 81100193Salc 8299625Speter/* True if should continue on unaffected portions of the graph 8399571Speter * when have an error in one portion */ 8499625Speterextern Boolean keepgoing; 85100331Salc 86100193Salc/* TRUE if targets should just be 'touched'if out of date. Set by the -t flag */ 8782314Speterextern Boolean touchFlag; 8882314Speter 8982314Speter/* TRUE if should capture the output of subshells by means of pipes. 9082314Speter * Otherwise it is routed to temporary files from which it is retrieved 9182314Speter * when the shell exits */ 9282314Speterextern Boolean usePipes; 9399625Speter 9482314Speter/* TRUE if we aren't supposed to really make anything, just see if the 9582314Speter * targets are out-of-date */ 9682314Speterextern Boolean queryFlag; 9782314Speter 9882314Speter/* List of specific variables for which the environment should be 9982314Speter * searched before the global context */ 10082314Speterextern Lst envFirstVars; 10182314Speter 10282314Speterextern struct GNode *DEFAULT; /* .DEFAULT rule */ 10399571Speter 10482314Speter/* The time at the start of this whole process */ 10582314Speterextern time_t now; 10682314Speter 10782314Speterextern int debug; 10882314Speter 10982314Speter/* warning flags */ 110100379Speterextern uint32_t warn_cmd; /* positive warning flags on command line */ 111100379Speterextern uint32_t warn_nocmd; /* negative warning flags on command line */ 11282314Speterextern uint32_t warn_flags; /* current warning flags */ 11382314Speter 11499571Speter#endif /* globals_h_1c1edb96 */ 11582314Speter