Don't sanitize out SPARC v9 stuff.
[binutils-gdb.git] / ld / .Sanitize
1 # .Sanitize for devo/ld.
2
3 # Each directory to survive its 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 directory.
15
16 Do-first:
17
18 if ( echo $* | grep keep\-v9 > /dev/null ) ; then
19 keep_these_too=""
20 fi
21
22 if ( echo $* | grep keep\-mpw > /dev/null ) ; then
23 keep_these_too="mpw-config.in mpw-make.in ChangeLog.mpw ${keep_these_too}"
24 else
25 lose_these_too="mpw-config.in mpw-make.in ChangeLog.mpw ${lose_these_too}"
26 fi
27
28 if ( echo $* | grep keep\-gm > /dev/null ) ; then
29 keep_these_too="mpw-xconfig.in mpw-em.c ChangeLog.gm ${keep_these_too}"
30 else
31 lose_these_too="mpw-xconfig.in mpw-em.c ChangeLog.gm ${lose_these_too}"
32 fi
33
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
40 Things-to-keep:
41
42 ChangeLog
43 Makefile.in
44 NEWS
45 README
46 TODO
47 cdtest-foo.cc
48 cdtest-foo.h
49 cdtest-bar.cc
50 cdtest-main.cc
51 cdtest.exp
52 config
53 config.h
54 configure.bat
55 configure.in
56 dep-in.sed
57 emulparams
58 emultempl
59 genscripts.sh
60 h8-doc.texi
61 ld.1
62 gen-doc.texi
63 ld.h
64 ld.texinfo
65 ldctor.c
66 ldctor.h
67 ldemul.c
68 ldemul.h
69 ldexp.c
70 ldexp.h
71 ldfile.c
72 ldfile.h
73 ldgram.y
74 ldint.texinfo
75 ldlang.c
76 ldlang.h
77 ldlex.h
78 ldlex.l
79 ldmain.c
80 ldmain.h
81 ldmisc.c
82 ldmisc.h
83 ldver.c
84 ldver.h
85 ldwrite.c
86 ldwrite.h
87 lexsup.c
88 mri.c
89 mri.h
90 scripttempl
91 testsuite
92
93 Things-to-lose:
94
95 Do-last:
96
97 echo Looking for traces of \"mpw\"...
98
99 # Don't try to clean directories here, as the 'mv' command will fail.
100 # Also, grep fails on NFS mounted directories.
101 if ( echo $* | grep keep\-mpw > /dev/null ) ; then
102 for i in * ; do
103 if test ! -d $i && (grep sanitize-mpw $i > /dev/null) ; then
104 echo Keeping mpw traces in $i
105 fi
106 done
107 else
108 for i in * ; do
109 if test ! -d $i && (grep sanitize-mpw $i > /dev/null) ; then
110 echo Removing traces of \"mpw\" out of $i...
111 cp $i new
112 sed '/start\-sanitize\-mpw/,/end-\sanitize\-mpw/d' < $i > new
113 if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
114 echo Caching $i in .Recover...
115 mv $i .Recover
116 fi
117 mv new $i
118 fi
119 done
120 fi
121
122 # End of file.