Fix minor sanitization problems.
authorFred Fish <fnf@specifix.com>
Mon, 26 Jan 1998 17:14:55 +0000 (17:14 +0000)
committerFred Fish <fnf@specifix.com>
Mon, 26 Jan 1998 17:14:55 +0000 (17:14 +0000)
.Sanitize
gdb/.Sanitize

index 0290dd7455b8cdb14b864febc6118076ce25c4b3..38732e81b6e6c4e34002d244881ee5cbe4e89454 100644 (file)
--- a/.Sanitize
+++ b/.Sanitize
@@ -488,9 +488,20 @@ fi
 
 if ( echo $* | grep lose\-gdbtk > /dev/null ) ; then
        echo Catering to RMS by removing traces of \"gdbtk\"...
-       if [ -n "${verbose}" ] ; then
-               echo Removing traces of \"gdbtk\" from Makefile.in...
-       fi
+       for i in * ; do
+               if test ! -d $i && (grep sanitize-gdbtk $i > /dev/null) ; then
+                       if [ -n "${verbose}" ] ; then
+                               echo Removing traces of \"gdbtk\" from $i...
+                       fi
+                       cp $i new
+                       sed '/start\-sanitize\-gdbtk/,/end-\sanitize\-gdbtk/d' < $i > new
+                       if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
+                               echo Caching $i in .Recover...
+                               mv $i .Recover
+                       fi
+                       mv new $i
+               fi
+       done
        cp Makefile.in new
        sed -e '/GDBTK_SUPPORT_DIRS=/d' -e 's/ $(GDBTK_SUPPORT_DIRS)//' < Makefile.in > new
        if [ -n "${safe}" -a ! -f .Recover/Makefile.in ] ; then
@@ -500,6 +511,22 @@ if ( echo $* | grep lose\-gdbtk > /dev/null ) ; then
                mv Makefile.in .Recover
        fi
        mv new Makefile.in
+else
+       echo Leaving \"gdbtk\" in the sources...
+       for i in * ; do
+               if test ! -d $i && (grep sanitize-gdbtk $i > /dev/null) ; then
+                       if [ -n "${verbose}" ] ; then
+                               echo Keeping \"gdbtk\" stuff in $i, but editing out sanitize lines...
+                       fi
+                       cp $i new
+                       sed -e '/start\-sanitize\-gdbtk/d' -e '/end\-sanitize\-gdbtk/d' < $i > new
+                       if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
+                               echo Caching $i in .Recover...
+                               mv $i .Recover
+                       fi
+                       mv new $i
+               fi
+       done
 fi
 
 vr5400_files="ChangeLog config.sub"
index ce1d063f87e4d496283288e7ea3ff5fd72533f94..907fe7cc67eb6edd96577ebc73258af91a687017 100644 (file)
@@ -780,6 +780,32 @@ else
                fi
        done
 fi
+if ( echo $* | grep keep\-ide > /dev/null ) ; then
+       for i in * ; do
+               if test ! -d $i && (grep sanitize-ide $i > /dev/null) ; then
+                       if [ -n "${verbose}" ] ; then
+                               echo Keeping ide stuff in $i
+                       fi
+               fi
+       done
+else
+       for i in * ; do
+               if test ! -d $i && (grep sanitize-ide $i > /dev/null) ; then
+                       if [ -n "${verbose}" ] ; then
+                               echo Removing traces of \"ide\" from $i...
+                       fi
+                       cp $i new
+                       sed '/start\-sanitize\-ide/,/end-\sanitize\-ide/d' < $i > new
+                       if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
+                               if [ -n "${verbose}" ] ; then
+                                       echo Caching $i in .Recover...
+                               fi
+                               mv $i .Recover
+                       fi
+                       mv new $i
+               fi
+       done
+fi
 
 for i in * ; do
        if test ! -d $i && (grep sanitize $i > /dev/null) ; then