File: makeasclean

package info (click to toggle)
afterstep 2.2.12-18.1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 33,184 kB
  • sloc: ansic: 201,695; sh: 5,894; xml: 3,721; makefile: 2,094; perl: 1,558; cpp: 811
file content (47 lines) | stat: -rwxr-xr-x 1,506 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#!/bin/sh
echo "AfterStep distibution cleanup script"
echo "You must run this script in your distribution root dir, like that:"
echo "cd /usr/src/AfterStep/AfterStep-devel && makeasclean" 

# make clean
dirs=`find . -name Makefile | sed 's/Makefile$//'`
for i in $dirs; do
  make -C $i clean
  done

# cleanup autoconf dir
cd autoconf
rm -f Makefile.defines Makefile.common Makefile.common.lib configure
cd ..

# removing all empty files from sources
rm -f `find include libAfterImage libAfterBase libAfterConf libAfterStep src -empty`

# removing some debug leftovers from sources
rm -f `find include libAfterImage libAfterBase libAfterConf libAfterStep src -name "log"`
# removing possibly diff or tmp files from src dir
rm -f `find src -maxdepth 1 -type f`

# remove configure droppings
rm -f `find . -name "config.cache"`
rm -f `find . -name "config.log"`
rm -f `find . -name "config.status"`
rm -f `find . \( -name "*.in" -o -name ".*.in"  \) -a ! -name "configure.in" | sed 's/.in$//'`
rm -rf src/ASDocGen/html src/ASDocGen/man src/ASDocGen/log.*

# remove backups
rm -f `find . -name "*~" -o -name ".*~"`
rm -f `find . -name "*.bak" -o -name ".*.bak"`

# remove object files and libraries
rm -f `find . -name "*.o"`
rm -f `find . -name "*.a"`
rm -f `find . -name "*.so"`
rm -f `find . -name "*.so.*"`

# remove patch droppings
rm -f `find . -name "*.rej" -o -name ".*.rej"`
rm -f `find . -name "*.orig" -o -name ".*.orig"`

# remove profiling information (for gprof)
rm -f `find . -name "gmon.out"`