Commit | Line | Data |
---|---|---|
764eb349 | 1 | # .Sanitize for devo/ld. |
86e4d6e4 | 2 | |
747a47f2 | 3 | # Each directory to survive its way into a release will need a file |
86e4d6e4 RP |
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 | |
747a47f2 | 14 | # done in this directory. |
86e4d6e4 RP |
15 | |
16 | Do-first: | |
17 | ||
2b510738 | 18 | mpw_files="mpw-make.in mpw-config.in mpw-em.c ChangeLog.mpw" |
10f1b597 | 19 | |
747a47f2 | 20 | if ( echo $* | grep keep\-mpw > /dev/null ) ; then |
10f1b597 | 21 | keep_these_too="${mpw_files} ${keep_these_too}" |
747a47f2 | 22 | else |
10f1b597 | 23 | lose_these_too="${mpw_files} ${lose_these_too}" |
747a47f2 SS |
24 | fi |
25 | ||
86e4d6e4 RP |
26 | # All files listed between the "Things-to-keep:" line and the |
27 | # "Files-to-sed:" line will be kept. All other files will be removed. | |
28 | # Directories listed in this section will have their own Sanitize | |
29 | # called. Directories not listed will be removed in their entirety | |
30 | # with rm -rf. | |
31 | ||
32 | Things-to-keep: | |
87756e15 | 33 | |
5784123f | 34 | ChangeLog |
86e4d6e4 | 35 | Makefile.in |
bc3b479c | 36 | NEWS |
c3d97ef6 | 37 | README |
fbd74d07 | 38 | TODO |
86e4d6e4 | 39 | config |
5f1fec76 | 40 | config.h |
65aa3724 | 41 | configure.bat |
86e4d6e4 | 42 | configure.in |
f8083739 | 43 | dep-in.sed |
2b63dbfe DM |
44 | emulparams |
45 | emultempl | |
c3d97ef6 | 46 | genscripts.sh |
2412a768 | 47 | h8-doc.texi |
40ab8532 | 48 | ld.1 |
2412a768 | 49 | gen-doc.texi |
5f1fec76 SC |
50 | ld.h |
51 | ld.texinfo | |
ffa057ee | 52 | ldctor.c |
1cc27b5e | 53 | ldctor.h |
c3d97ef6 PB |
54 | ldemul.c |
55 | ldemul.h | |
5f1fec76 SC |
56 | ldexp.c |
57 | ldexp.h | |
58 | ldfile.c | |
5f1fec76 | 59 | ldfile.h |
5f1fec76 | 60 | ldgram.y |
4b91c519 | 61 | ldint.texinfo |
5f1fec76 SC |
62 | ldlang.c |
63 | ldlang.h | |
64 | ldlex.h | |
65 | ldlex.l | |
5f1fec76 SC |
66 | ldmain.c |
67 | ldmain.h | |
68 | ldmisc.c | |
69 | ldmisc.h | |
5f1fec76 SC |
70 | ldver.c |
71 | ldver.h | |
5f1fec76 SC |
72 | ldwrite.c |
73 | ldwrite.h | |
0cc6a796 | 74 | lexsup.c |
b11a9b28 | 75 | mri.c |
a586b5bc | 76 | mri.h |
2b63dbfe | 77 | scripttempl |
e2f9f0f6 | 78 | testsuite |
86e4d6e4 | 79 | |
87756e15 RP |
80 | Things-to-lose: |
81 | ||
86e4d6e4 RP |
82 | Do-last: |
83 | ||
747a47f2 SS |
84 | echo Looking for traces of \"mpw\"... |
85 | ||
86 | # Don't try to clean directories here, as the 'mv' command will fail. | |
87 | # Also, grep fails on NFS mounted directories. | |
88 | if ( echo $* | grep keep\-mpw > /dev/null ) ; then | |
89 | for i in * ; do | |
90 | if test ! -d $i && (grep sanitize-mpw $i > /dev/null) ; then | |
91 | echo Keeping mpw traces in $i | |
92 | fi | |
93 | done | |
94 | else | |
95 | for i in * ; do | |
96 | if test ! -d $i && (grep sanitize-mpw $i > /dev/null) ; then | |
97 | echo Removing traces of \"mpw\" out of $i... | |
98 | cp $i new | |
99 | sed '/start\-sanitize\-mpw/,/end-\sanitize\-mpw/d' < $i > new | |
100 | if [ -n "${safe}" -a ! -f .Recover/$i ] ; then | |
101 | echo Caching $i in .Recover... | |
102 | mv $i .Recover | |
103 | fi | |
104 | mv new $i | |
105 | fi | |
106 | done | |
107 | fi | |
108 | ||
86e4d6e4 | 109 | # End of file. |