Mon Nov 16 19:21:48 1998 Dave Brolley <brolley@cygnus.com>
[deliverable/binutils-gdb.git] / sim / .Sanitize
CommitLineData
b0c9f026
SC
1# .Sanitize for devo/sim.
2
3# Each directory to survive it's way into a release will need a file
4# like this one called "./.Sanitize". All keyword lines must exist,
5# and must exist in the order specified by this file. Each directory
6# in the tree will be processed, top down, in the following order.
7
8# Hash started lines like this one are comments and will be deleted
9# before anything else is done. Blank lines will also be squashed
10# out.
11
12# The lines between the "Do-first:" line and the "Things-to-keep:"
13# line are executed as a /bin/sh shell script before anything else is
14# done in this
15
16Do-first:
17
19a2b300 18tic80_files="tic80"
15c16493 19if ( echo $* | grep keep\-tic80 > /dev/null ) ; then
f13f11b4 20 keep_these_too="${tic80_files} ${keep_these_too}"
15c16493
AC
21else
22 lose_these_too="${tic80_files} ${lose_these_too}"
23fi
24
92fa4579
FCE
25gxsim_files="m32r-gx"
26if ( echo $* | grep keep\-gxsim > /dev/null ) ; then
27 keep_these_too="${gxsim_files} ${keep_these_too}"
28else
29 lose_these_too="${gxsim_files} ${lose_these_too}"
30fi
31
f13f11b4 32lose_these_too="${lose_these_too}"
19a2b300 33
b0c9f026
SC
34# All files listed between the "Things-to-keep:" line and the
35# "Files-to-sed:" line will be kept. All other files will be removed.
36# Directories listed in this section will have their own Sanitize
37# called. Directories not listed will be removed in their entirety
38# with rm -rf.
39
40Things-to-keep:
41
83a4c26f 42ChangeLog
55538130 43Makefile.in
117224ea 44README-HACKING
d32033ad 45arm
1ffd292b 46configure
b0c9f026 47configure.in
60181796 48common
22540e2d 49d10v
965f5327 50d30v
fd58f4b1 51erc32
b0c9f026 52h8300
a66ad4b2 53h8500
f13f11b4 54igen
3990f1cd 55m32r
2f82f755 56mips
c1848bd2 57mn10200
05ccbdfd 58mn10300
cb7a6892 59ppc
594266fc 60sh
f13f11b4 61v850
bfebf1a5 62testsuite
4a5947d0 63w65
b0c9f026
SC
64z8k
65
87756e15
RP
66Things-to-lose:
67
47a21445 68fr30
447a825b 69
b0c9f026
SC
70Do-last:
71
15c16493
AC
72tic80_files="configure configure.in ChangeLog"
73if ( echo $* | grep keep\-tic80 > /dev/null ) ; then
74 for i in $tic80_files ; do
75 if test ! -d $i && (grep sanitize-tic80 $i > /dev/null) ; then
317df3b5 76 if [ -n "${verbose}" ] ; then
15c16493 77 echo Keeping tic80 stuff in $i
317df3b5
AC
78 fi
79 fi
80 done
81else
15c16493
AC
82 for i in $tic80_files ; do
83 if test ! -d $i && (grep sanitize-tic80 $i > /dev/null) ; then
317df3b5 84 if [ -n "${verbose}" ] ; then
15c16493 85 echo Removing traces of \"tic80\" from $i...
317df3b5
AC
86 fi
87 cp $i new
15c16493
AC
88 sed '/start\-sanitize\-tic80/,/end-\sanitize\-tic80/d' < $i > new
89 if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
90 if [ -n "${verbose}" ] ; then
91 echo Caching $i in .Recover...
92 fi
93 mv $i .Recover
94 fi
95 mv new $i
96 fi
97 done
98fi
99
92fa4579
FCE
100gxsim_files="configure configure.in ChangeLog"
101if ( echo $* | grep keep\-gxsim > /dev/null ) ; then
102 for i in $gxsim_files ; do
103 if test ! -d $i && (grep sanitize-gxsim $i > /dev/null) ; then
104 if [ -n "${verbose}" ] ; then
105 echo Keeping gxsim stuff in $i
106 fi
107 fi
108 done
109else
110 for i in $gxsim_files ; do
111 if test ! -d $i && (grep sanitize-gxsim $i > /dev/null) ; then
112 if [ -n "${verbose}" ] ; then
113 echo Removing traces of \"gxsim\" from $i...
114 fi
115 cp $i new
116 sed '/start\-sanitize\-gxsim/,/end-\sanitize\-gxsim/d' < $i > new
117 if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
118 if [ -n "${verbose}" ] ; then
119 echo Caching $i in .Recover...
120 fi
121 mv $i .Recover
122 fi
123 mv new $i
124 fi
125 done
126fi
127
15c16493 128v850_files="configure configure.in ChangeLog"
27161f9e
NC
129if ( echo $* | grep keep\-v850e > /dev/null ) ; then
130 for i in $v850_files ; do
131 if test ! -d $i && (grep sanitize-v850e $i > /dev/null) ; then
132 if [ -n "${verbose}" ] ; then
133 echo Keeping v850e stuff in $i
134 fi
135 fi
136 done
137else
138 for i in $v850_files ; do
139 if test ! -d $i && (grep sanitize-v850e $i > /dev/null) ; then
140 if [ -n "${verbose}" ] ; then
141 echo Removing traces of \"v850e\" from $i...
142 fi
143 cp $i new
144 sed '/start\-sanitize\-v850e/,/end-\sanitize\-v850e/d' < $i > new
145 if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
146 if [ -n "${verbose}" ] ; then
147 echo Caching $i in .Recover...
148 fi
149 mv $i .Recover
150 fi
151 mv new $i
152 fi
153 done
154fi
27161f9e 155
d843d7ca
GRK
156vr4320_files="ChangeLog"
157if ( echo $* | grep keep\-vr4320 > /dev/null ) ; then
158 for i in $vr4320_files ; do
159 if test ! -d $i && (grep sanitize-vr4320 $i > /dev/null) ; then
160 if [ -n "${verbose}" ] ; then
161 echo Keeping vr4320 stuff in $i
162 fi
163 fi
164 done
165else
166 for i in $vr4320_files ; do
167 if test ! -d $i && (grep sanitize-vr4320 $i > /dev/null) ; then
168 if [ -n "${verbose}" ] ; then
169 echo Removing traces of \"vr4320\" from $i...
170 fi
171 cp $i new
172 sed '/start\-sanitize\-vr4320/,/end-\sanitize\-vr4320/d' < $i > new
173 if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
174 if [ -n "${verbose}" ] ; then
175 echo Caching $i in .Recover...
176 fi
177 mv $i .Recover
178 fi
179 mv new $i
180 fi
181 done
182fi
183
745a0437
MH
184for i in * ; do
185 if test ! -d $i && (grep sanitize $i > /dev/null) ; then
186 echo '***' Some mentions of Sanitize are still left in $i! 1>&2
187 fi
188done
189
b0c9f026 190# End of file.
This page took 0.20223 seconds and 4 git commands to generate.