Thrift: Improve cleanup.sh.
Reviewed By: mcslee
Test Plan:
dreiss@dreiss-vmware:cleanup:thrift$ ./bootstrap.sh && ./configure && make -j2 && ./cleanup.sh && git status
# Shows no untracked files.
Revert Plan: ok
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665432 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/cleanup.sh b/cleanup.sh
index b2dcee1..878bf62 100755
--- a/cleanup.sh
+++ b/cleanup.sh
@@ -1,7 +1,6 @@
#!/bin/sh
-subdirs="compiler/cpp lib/cpp lib/py if"
-
+make distclean >/dev/null 2>&1
rm -rf \
AUTHORS \
ChangeLog \
@@ -15,6 +14,7 @@
config.guess \
config.h \
config.hin \
+config.hin~ \
config.log \
config.status \
config.sub \
@@ -28,13 +28,9 @@
ltmain.sh \
missing \
ylwrap \
-if/gen-*
-
-for subdir in ${subdirs}; do
- if [ -x "${subdir}/cleanup.sh" ]; then
- cwd="`pwd`"
- cd "${subdir}"
- ./cleanup.sh
- cd "${cwd}"
- fi
-done
+if/gen-* \
+compiler/cpp/Makefile.in \
+if/Makefile.in \
+lib/Makefile.in \
+lib/cpp/Makefile.in \
+lib/py/Makefile.in