* Makefile.in: added coff-h8300
[deliverable/binutils-gdb.git] / DOC.Sanitize
CommitLineData
8d91aae6
RP
1
2
3 The Sanitization Process
4
5
6Usage:
7
8To sanitize a directory or subtree, foo:
9
10cd foo ; /usr/unsupported/bin/Sanitize
11
12and you should be left with source code free of any distribution
13restrictions.
14
15
16Configuration:
17
18Each directory to be kept in a release should have a .Sanitize file in
19cvs. See devo/.Sanitize for a more or less self describing template.
20
21The default action is to remove all files and directories not
22explicitly listed in the .Sanitize file as being "Things-to-keep:".
23Directories that are kept will have Sanitize called on their own
24.Sanitize files.
25
26For other than default action, there are three hooks.
27
28The "Do-first:" section of .Sanitize should be a shell script
29fragment. It will be sourced by the Sanitize shell script after
30verifying that the .Sanitize file looks reasonable but before taking
31any other action. The arguments to Sanitize are passed to this
32fragment so that you can take conditional action. For an example of
33it's use, see devo/gcc/config/.Sanitize.
34
35If the "Do-first:" section sets the local shell variable
36"keep_these_too", the files and/or directories listed there will be
37kept in addition to any files listed in "Things-to-keep:". For an
38example of it's use, see devo/gcc/config/.Sanitize.
39
40The "Do-last:" section of .Sanitize should be a shell script fragment.
41It will be sourced by Sanitize after all other action is taken for
42this directory. This section is intended to be used to strip code out
43of source files. For an example of grep'ing out specific lines, see
44devo/include/.Sanitize. For an example of sed'ing out sections of
45code, see devo/gas/config/.Sanitize.
46
47Command line options are extremely free form. The Sanitize script
48itself only knows about keep-cvs. All arguments to Sanitize are
49passed to the "Do-first:" and "Do-last:" fragments. Feel free to add
50new options as you see fit so long as you list them here.
51
52Defined options:
53
54keep-cvs avoids removing CVS.adm directories. This option is
55 actually recognized and handled by the Sanitize shell
56 script.
57
58keep-v9 avoids removing the v9 stuff.
59keep-life avoids removing the life stuff.
60keep-cri avoids removing the cray research inc changes to emacs.
61for-intel builds a distribution in the style that Intel likes.
62for-fsf builds a distribution in the style that the FSF likes.
63
64test instead of removing dirty files, cache them away in a
65 .Recover directory
66recover intended to undo the effects of a "Sanitize test".
This page took 0.031924 seconds and 4 git commands to generate.