| @@ -1,14 +1,14 @@ | | | @@ -1,14 +1,14 @@ |
1 | /* $NetBSD: make.h,v 1.180 2020/11/04 02:57:42 rillig Exp $ */ | | 1 | /* $NetBSD: make.h,v 1.181 2020/11/04 03:13:46 rillig Exp $ */ |
2 | | | 2 | |
3 | /* | | 3 | /* |
4 | * Copyright (c) 1988, 1989, 1990, 1993 | | 4 | * Copyright (c) 1988, 1989, 1990, 1993 |
5 | * The Regents of the University of California. All rights reserved. | | 5 | * The Regents of the University of California. All rights reserved. |
6 | * | | 6 | * |
7 | * This code is derived from software contributed to Berkeley by | | 7 | * This code is derived from software contributed to Berkeley by |
8 | * Adam de Boor. | | 8 | * Adam de Boor. |
9 | * | | 9 | * |
10 | * Redistribution and use in source and binary forms, with or without | | 10 | * Redistribution and use in source and binary forms, with or without |
11 | * modification, are permitted provided that the following conditions | | 11 | * modification, are permitted provided that the following conditions |
12 | * are met: | | 12 | * are met: |
13 | * 1. Redistributions of source code must retain the above copyright | | 13 | * 1. Redistributions of source code must retain the above copyright |
14 | * notice, this list of conditions and the following disclaimer. | | 14 | * notice, this list of conditions and the following disclaimer. |
| @@ -161,27 +161,27 @@ typedef int Boolean; | | | @@ -161,27 +161,27 @@ typedef int Boolean; |
161 | #endif | | 161 | #endif |
162 | #ifndef FALSE | | 162 | #ifndef FALSE |
163 | #define FALSE 0 | | 163 | #define FALSE 0 |
164 | #endif | | 164 | #endif |
165 | #endif | | 165 | #endif |
166 | | | 166 | |
167 | #include "lst.h" | | 167 | #include "lst.h" |
168 | #include "enum.h" | | 168 | #include "enum.h" |
169 | #include "hash.h" | | 169 | #include "hash.h" |
170 | #include "config.h" | | 170 | #include "config.h" |
171 | #include "buf.h" | | 171 | #include "buf.h" |
172 | #include "make_malloc.h" | | 172 | #include "make_malloc.h" |
173 | | | 173 | |
174 | typedef enum { | | 174 | typedef enum GNodeMade { |
175 | UNMADE, /* Not examined yet */ | | 175 | UNMADE, /* Not examined yet */ |
176 | DEFERRED, /* Examined once (building child) */ | | 176 | DEFERRED, /* Examined once (building child) */ |
177 | REQUESTED, /* on toBeMade list */ | | 177 | REQUESTED, /* on toBeMade list */ |
178 | BEINGMADE, /* Target is already being made. | | 178 | BEINGMADE, /* Target is already being made. |
179 | * Indicates a cycle in the graph. */ | | 179 | * Indicates a cycle in the graph. */ |
180 | MADE, /* Was out-of-date and has been made */ | | 180 | MADE, /* Was out-of-date and has been made */ |
181 | UPTODATE, /* Was already up-to-date */ | | 181 | UPTODATE, /* Was already up-to-date */ |
182 | ERROR, /* An error occurred while it was being | | 182 | ERROR, /* An error occurred while it was being |
183 | * made (used only in compat mode) */ | | 183 | * made (used only in compat mode) */ |
184 | ABORTED /* The target was aborted due to an error | | 184 | ABORTED /* The target was aborted due to an error |
185 | * making an inferior (compat). */ | | 185 | * making an inferior (compat). */ |
186 | } GNodeMade; | | 186 | } GNodeMade; |
187 | | | 187 | |
| @@ -446,27 +446,27 @@ extern time_t now; /* The time at the s | | | @@ -446,27 +446,27 @@ extern time_t now; /* The time at the s |
446 | | | 446 | |
447 | /* Do old-style variable substitution. | | 447 | /* Do old-style variable substitution. |
448 | * | | 448 | * |
449 | * The word "old" comes from 1993-03-21 or earlier, so it must be really old. | | 449 | * The word "old" comes from 1993-03-21 or earlier, so it must be really old. |
450 | * TODO: But what does this "old-style" mean? What effects does it have? */ | | 450 | * TODO: But what does this "old-style" mean? What effects does it have? */ |
451 | extern Boolean oldVars; | | 451 | extern Boolean oldVars; |
452 | | | 452 | |
453 | extern SearchPath *sysIncPath; /* The system include path. */ | | 453 | extern SearchPath *sysIncPath; /* The system include path. */ |
454 | extern SearchPath *defSysIncPath; /* The default system include path. */ | | 454 | extern SearchPath *defSysIncPath; /* The default system include path. */ |
455 | | | 455 | |
456 | extern char curdir[]; /* Startup directory */ | | 456 | extern char curdir[]; /* Startup directory */ |
457 | extern char *progname; /* The program name */ | | 457 | extern char *progname; /* The program name */ |
458 | extern char *makeDependfile; /* .depend */ | | 458 | extern char *makeDependfile; /* .depend */ |
459 | extern char **savedEnv; /* if we replaced environ this will be non-NULL */ | | 459 | extern char **savedEnv; /* if we replaced environ this will be non-NULL */ |
460 | | | 460 | |
461 | extern int makelevel; | | 461 | extern int makelevel; |
462 | | | 462 | |
463 | /* | | 463 | /* |
464 | * We cannot vfork() in a child of vfork(). | | 464 | * We cannot vfork() in a child of vfork(). |
465 | * Most systems do not enforce this but some do. | | 465 | * Most systems do not enforce this but some do. |
466 | */ | | 466 | */ |
467 | #define vFork() ((getpid() == myPid) ? vfork() : fork()) | | 467 | #define vFork() ((getpid() == myPid) ? vfork() : fork()) |
468 | extern pid_t myPid; | | 468 | extern pid_t myPid; |
469 | | | 469 | |
470 | #define MAKEFLAGS ".MAKEFLAGS" | | 470 | #define MAKEFLAGS ".MAKEFLAGS" |
471 | #define MAKEOVERRIDES ".MAKEOVERRIDES" | | 471 | #define MAKEOVERRIDES ".MAKEOVERRIDES" |
472 | #define MAKE_JOB_PREFIX ".MAKE.JOB.PREFIX" /* prefix for job target output */ | | 472 | #define MAKE_JOB_PREFIX ".MAKE.JOB.PREFIX" /* prefix for job target output */ |