Last change
on this file was
c5c522c,
checked in by Edwin Eefting <edwin@datux.nl>, 8 years ago
|
initial commit, transferred from cleaned syn3 svn tree
|
-
Property mode set to
100755
|
File size:
1.4 KB
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | ##NEED:linux_src |
---|
3 | #DEP:popt |
---|
4 | # Set initial variables: |
---|
5 | CWD=`pwd` |
---|
6 | if [ "$TMP" = "" ]; then |
---|
7 | TMP=/tmp |
---|
8 | fi |
---|
9 | PKG=$TMP/package-logrotate |
---|
10 | |
---|
11 | NAME=logrotate |
---|
12 | VERSION=3.6.8 |
---|
13 | ARCH=`arch` |
---|
14 | BUILD=1DatuX |
---|
15 | |
---|
16 | if [ ! -d $TMP ]; then |
---|
17 | mkdir -p $TMP # location to build the source |
---|
18 | fi |
---|
19 | rm -rf $PKG |
---|
20 | mkdir -p $PKG # place for the package to be built |
---|
21 | |
---|
22 | cd $TMP |
---|
23 | rm -rf logrotate-$VERSION |
---|
24 | tar xzvf $CWD/logrotate-$VERSION.tar.gz |
---|
25 | cd logrotate-$VERSION |
---|
26 | chown -R root.root . |
---|
27 | make clean || exit 1 |
---|
28 | make || exit 1 |
---|
29 | strip logrotate |
---|
30 | mkdir -p $PKG/usr/sbin |
---|
31 | cat logrotate > $PKG/usr/sbin/logrotate |
---|
32 | mkdir -p $PKG/usr/man/man8 |
---|
33 | cat logrotate.8 | gzip -9c > $PKG/usr/man/man8/logrotate.8.gz |
---|
34 | mkdir -p $PKG/usr/doc/logrotate-$VERSION |
---|
35 | cp -a \ |
---|
36 | CHANGES COPYING READM* \ |
---|
37 | $PKG/usr/doc/logrotate-$VERSION |
---|
38 | chmod 644 $PKG/usr/doc/logrotate-$VERSION/* |
---|
39 | chmod 755 $PKG/usr/sbin/* |
---|
40 | mkdir -p $PKG/install |
---|
41 | mkdir -p $PKG/etc/cron.daily |
---|
42 | cp $CWD/logrotate.d $PKG/etc |
---|
43 | chmod 644 $PKG/etc/logrotate.d/* |
---|
44 | cp $CWD/logrotate.conf $PKG/etc |
---|
45 | cp $CWD/logrotate $PKG/etc/cron.daily |
---|
46 | chmod 644 $PKG/etc/logrotate.conf $PKG/etc/cron.daily |
---|
47 | chown -R root:root $PKG/etc/* |
---|
48 | |
---|
49 | #maak alle configfiles eindigend op .new |
---|
50 | find $PKG/etc -follow -type f -exec mv "{}" "{}.new" \; || exit 1 |
---|
51 | |
---|
52 | |
---|
53 | # Build the package: |
---|
54 | cd $PKG |
---|
55 | #makepkg -l y -c n $TMP/logrotate-$VERSION-$ARCH-$BUILD.tgz |
---|
56 | makepkg -l y -c n $CWD/$NAME.pkg > /dev/null && |
---|
57 | echo $VERSION > $CWD/$NAME.version && |
---|
58 | arch > $CWD/$NAME.arch |
---|
59 | |
---|
60 | #mv $TMP/logrotate-$VERSION-$ARCH-$BUILD.tgz $CWD |
---|
61 | |
---|
62 | |
---|
Note: See
TracBrowser
for help on using the repository browser.