1cook_bom(1) General Commands Manual cook_bom(1)
2
3
4
6 cook_bom - bill of materials
7
9 cook_bom [ option... ] dirname [ outfile ]
10 cook_bom -Help
11 cook_bom -VERSion
12
14 The cook_bom program is used to scan a directory and generate a cook‐
15 book fragment containing a bill of materials for that directory. It
16 also includes a recursive reference, via an ``#include-cooked'' direc‐
17 tive, to the bills of materials for nested directories.
18
19 Output is sent to the standard output unless an output filename is
20 specified.
21
23 The following options are understood:
24
25 -DIRectory pathname
26 This option may be used to specify a directory search path,
27 similar to cook(1) [search_list] functionality.
28
29 -Help
30 Provide some help with using the cook_bom program.
31
32 -IGnore string
33 This option may be used to specify filename patterns to be
34 ignored. It may be given as many times as required.
35
36 -PREfix string
37 This option may be manipulate the name of the manifest files.
38 Defaults to the empty string if not set.
39
40 -SUFfix string
41 This option may be manipulate the name of the manifest files.
42 Defaults to ``/manifest.cook if not set.
43
44 -VERSion
45 Print the version of the cook_bom program being executed.
46
47 All other options will produce a diagnostic error.
48
49 All options may be abbreviated; the abbreviation is documented as the
50 upper case letters, all lower case letters and underscores (_) are
51 optional. You must use consecutive sequences of optional letters.
52
53 All options are case insensitive, you may type them in upper case or
54 lower case or a combination of both, case is not important.
55
56 For example: the arguments "-help", "-HEL" and "-h" are all inter‐
57 preted to mean the -Help option. The argument "-hlp" will not be
58 understood, because consecutive optional characters were not supplied.
59
60 Options and other command line arguments may be mixed arbitrarily on
61 the command line.
62
63 The GNU long option names are understood. Since all option names for
64 cook_bom are long, this means ignoring the extra leading '-'. The
65 "--option=value" convention is also understood.
66
68 The cook_bom command will exit with a status of 1 on any error. The
69 cook_bom command will only exit with a status of 0 if there are no
70 errors.
71
73 The intended use of this command is to automatically generate a
74 project file manifest in an efficient way. If you have a cookbook of
75 the form
76 all_files_in_. = ;
77 #include manifest.cook
78 manifest = [all_files_in_.];
79
80 set fingerprint mkdir unlink;
81
82 %0manifest.cook: ["if" [in "%0" ""] "then" "." "else" "%0"]
83 {
84 cook_bom
85 [addprefix '--dir=' [search_list]]
86 "--ignore='*~'"
87 [need]
88 [target]
89 ;
90 }
91 At the end of this fragment, the manifest variable contains a complete
92 list of all files in the directory tree. This variable may then be
93 taken apart with the match_mask function to build ingredients lists.
94
95 The constructed manifest.cook files work for both whole-project and
96 recursive (not recommended) builds.
97
99 cook_bom version 2.30
100 Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996,
101 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Peter
102 Miller; All rights reserved.
103
104 The cook_bom program comes with ABSOLUTELY NO WARRANTY; for details
105 use the 'cook_bom -VERSion License' command. This is free software
106 and you are welcome to redistribute it under certain conditions; for
107 details use the 'cook_bom -VERSion License' command.
108
110 Peter Miller E-Mail: millerp@canb.auug.org.au
111 /\/\* WWW: http://www.canb.auug.org.au/~millerp/
112
113
114
115Reference Manual Cook cook_bom(1)