Commit | Line | Data |
---|---|---|
86e4d6e4 RP |
1 | # Sanitize.in for devo. |
2 | # $Id$ | |
3 | # | |
4 | ||
5 | # Each directory to survive it's way into a release will need a file | |
6 | # like this one called "./.Sanitize". All keyword lines must exist, | |
7 | # and must exist in the order specified by this file. Each directory | |
8 | # in the tree will be processed, top down, in the following order. | |
9 | ||
10 | # Hash started lines like this one are comments and will be deleted | |
11 | # before anything else is done. Blank lines will also be squashed | |
12 | # out. | |
13 | ||
14 | # The lines between the "Do-first:" line and the "Things-to-keep:" | |
15 | # line are executed as a /bin/sh shell script before anything else is | |
16 | # done in this | |
17 | ||
18 | Do-first: | |
19 | ||
20 | echo Sanitizing `pwd`... | |
21 | ||
22 | # All files listed between the "Things-to-keep:" line and the | |
23 | # "Files-to-sed:" line will be kept. All other files will be removed. | |
24 | # Directories listed in this section will have their own Sanitize | |
25 | # called. Directories not listed will be removed in their entirety | |
26 | # with rm -rf. | |
27 | ||
28 | Things-to-keep: | |
29 | ||
30 | ChangeLog | |
0ce51ae9 | 31 | Makefile.dos |
86e4d6e4 | 32 | Makefile.in |
5a77e916 | 33 | README |
86e4d6e4 RP |
34 | TODO |
35 | alloca.c | |
5a77e916 | 36 | am29k-pinsn.c |
05b47bfb | 37 | ar.1 |
5a77e916 | 38 | ar.c |
c83497f5 | 39 | binutils.texi |
86e4d6e4 | 40 | bucomm.c |
5a77e916 | 41 | bucomm.h |
0ce51ae9 | 42 | configure.bat |
86e4d6e4 RP |
43 | configure.in |
44 | copy.c | |
45 | cplus-dem.c | |
46 | filemode.c | |
47 | gmalloc.c | |
48 | i960-pinsn.c | |
5a77e916 SC |
49 | is-ranlib.c |
50 | is-strip.c | |
86e4d6e4 | 51 | m68k-pinsn.c |
5a77e916 SC |
52 | maybe-ranlib.c |
53 | maybe-strip.c | |
54 | nm.1 | |
86e4d6e4 | 55 | nm.c |
5a77e916 SC |
56 | not-ranlib.c |
57 | not-strip.c | |
58 | objdump.1 | |
86e4d6e4 | 59 | objdump.c |
5a77e916 SC |
60 | objdump.h |
61 | ranlib.1 | |
06a97fbd | 62 | ranlib.sh |
5a77e916 | 63 | size.1 |
86e4d6e4 RP |
64 | size.c |
65 | sparc-pinsn.c | |
5a77e916 | 66 | strip.1 |
86e4d6e4 RP |
67 | version.c |
68 | ||
69 | Do-last: | |
70 | ||
5d138676 | 71 | v9dirty="sparc-pinsn.c" |
86e4d6e4 | 72 | |
5d138676 JG |
73 | if ( echo $* | grep keep\-v9 > /dev/null ) ; then |
74 | echo Keeping v9 in ${v9dirty} | |
75 | else | |
76 | for i in ${v9dirty} ; do | |
77 | echo Sanitizing v9 in $i | |
78 | rm -f new | |
79 | sed '/^#ifndef[ ]NO_V9/,/^#endif/d' < $i > new | |
80 | if grep -s -i v9 new ; then | |
81 | echo ***** SANITIZING V9 IN $i FAILED *****\a\a | |
82 | fi | |
83 | if [ -n "${safe}" ] ; then | |
84 | mv $i .Recover | |
85 | else | |
86 | rm $i | |
87 | fi | |
88 | mv new $i | |
89 | done | |
90 | fi |