VirtualBox

source: kBuild/trunk/src/kmk/dep.h@ 1223

Last change on this file since 1223 was 903, checked in by bird, 18 years ago

Merged with the 2007-05-23 CVS. Added rsort and fixed a couple of windows build issues.

  • Property svn:eol-style set to native
File size: 2.9 KB
Line 
1/* Definitions of dependency data structures for GNU Make.
2Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
31998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software
4Foundation, Inc.
5This file is part of GNU Make.
6
7GNU Make is free software; you can redistribute it and/or modify it under the
8terms of the GNU General Public License as published by the Free Software
9Foundation; either version 2, or (at your option) any later version.
10
11GNU Make is distributed in the hope that it will be useful, but WITHOUT ANY
12WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
13A PARTICULAR PURPOSE. See the GNU General Public License for more details.
14
15You should have received a copy of the GNU General Public License along with
16GNU Make; see the file COPYING. If not, write to the Free Software
17Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. */
18
19/* Flag bits for the second argument to `read_makefile'.
20 These flags are saved in the `changed' field of each
21 `struct dep' in the chain returned by `read_all_makefiles'. */
22
23#define RM_NO_DEFAULT_GOAL (1 << 0) /* Do not set default goal. */
24#define RM_INCLUDED (1 << 1) /* Search makefile search path. */
25#define RM_DONTCARE (1 << 2) /* No error if it doesn't exist. */
26#define RM_NO_TILDE (1 << 3) /* Don't expand ~ in file name. */
27#define RM_NOFLAG 0
28
29/* Structure representing one dependency of a file.
30 Each struct file's `deps' points to a chain of these,
31 chained through the `next'. `stem' is the stem for this
32 dep line of static pattern rule or NULL.
33
34 Note that the first two words of this match a struct nameseq. */
35
36struct dep
37 {
38 struct dep *next;
39 const char *name;
40 const char *stem;
41 struct file *file;
42 unsigned int changed : 8;
43 unsigned int ignore_mtime : 1;
44 unsigned int staticpattern : 1;
45 unsigned int need_2nd_expansion : 1;
46 };
47
48
49/* Structure used in chains of names, for parsing and globbing. */
50
51struct nameseq
52 {
53 struct nameseq *next;
54 const char *name;
55 };
56
57
58struct nameseq *multi_glob (struct nameseq *chain, unsigned int size);
59#ifdef VMS
60struct nameseq *parse_file_seq ();
61#else
62struct nameseq *parse_file_seq (char **stringp, int stopchar, unsigned int size, int strip);
63#endif
64char *tilde_expand (const char *name);
65
66#ifndef NO_ARCHIVES
67struct nameseq *ar_glob (const char *arname, const char *member_pattern, unsigned int size);
68#endif
69
70#define dep_name(d) ((d)->name == 0 ? (d)->file->name : (d)->name)
71
72struct dep *alloc_dep (void);
73void free_dep (struct dep *d);
74struct dep *copy_dep_chain (const struct dep *d);
75void free_dep_chain (struct dep *d);
76void free_ns_chain (struct nameseq *n);
77struct dep *read_all_makefiles (const char **makefiles);
78int eval_buffer (char *buffer);
79int update_goal_chain (struct dep *goals);
80void uniquize_deps (struct dep *);
81
82#ifdef CONFIG_WITH_INCLUDEDEP
83void eval_include_dep (const char *name, struct floc *f);
84#endif
85
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette