This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH: bin/preprocess
- To: <gcc-patches at gcc dot gnu dot org>
- Subject: Re: PATCH: bin/preprocess
- From: Gerald Pfeifer <pfeifer at dbai dot tuwien dot ac dot at>
- Date: Tue, 13 Feb 2001 01:12:21 +0100 (CET)
Excellent. Not.
The script worked fine on Solaris and FreeBSD, just not on gcc.gnu.org.
In fact, even with the patch below it still does not work completely, but
it's less worse (and no harm is done either way).
Installed.
Gerald
Index: preprocess
===================================================================
RCS file: /cvs/gcc/wwwdocs/bin/preprocess,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -3 -p -r1.15 -r1.16
--- preprocess 2001/02/12 22:29:36 1.15
+++ preprocess 2001/02/13 00:09:53 1.16
@@ -17,7 +17,7 @@ DESTTREE=${DESTTREE-/www/gcc/htdocs}
STYLE=$SOURCETREE/style.mhtml
-EXCLUDE_FROM_REMOVAL='benchresults|testresults'
+DONT_REMOVE='-name onlinedocs -prune -o -name benchresults -prune -o -name testresults -prune -o -name fom_serv -prune'
####
# Various safety check first.
@@ -49,14 +49,14 @@ trap "cleanup; exit 1" 1 2 15
remove_cruft() {
cd $DESTTREE
- for f in `find . -type f \( -name $EXCLUDE_FROM_REMOVAL -prune -o -print \) ` ; do
+ for f in `find . \( $DONT_REMOVE \) -type f` ; do
if [ ! -f $SOURCETREE/$f ]; then
echo "Removing obsolete file $f"
#rm $f
fi
done
- for f in `find . -type d` ; do
+ for f in `find . \( $DONT_REMOVE \) -type d` ; do
if [ ! -d $SOURCETREE/$f ]; then
echo "Removing obsolete directory $f"
#rmdir $f