File: makesrcpkg

package info (click to toggle)
nas 1.9.2-4squeeze1
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 7,996 kB
  • ctags: 29,014
  • sloc: ansic: 52,102; makefile: 32,002; sh: 6,972; perl: 1,104; yacc: 249; cpp: 216; lex: 68
file content (66 lines) | stat: -rw-r--r-- 1,197 bytes parent folder | download | duplicates (9)
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
#!/bin/sh
#
# makesrcpkg - make a src distribution
#
# Jon Trulson - 6/20/99
#
# $Id: makesrcpkg 133 2004-06-20 23:27:10Z jon $
#
##############################################################################
# set -x

# a little test...

if [ ! -d lib -o ! -d server -o ! -f RELEASE ]
then	# assume we're not in the top level...
	echo "You must be in the top level build directory to run this."
	exit 1
fi

VERSION=`cat RELEASE |cut -d' ' -f5`

NASVER="nas-$VERSION"

ARCFILE="${NASVER}.src.tar"

#exit 1

rm -f ${ARCFILE}.gz
rm -rf $NASVER
echo Arcive name: $ARCFILE

FILELIST="./config/filelist"

mkdir $NASVER 2>/dev/null

cat $FILELIST |cpio -pdvumL $NASVER/

if [ -f CHANGES ]
then
    cp CHANGES $NASVER/
    echo "### CHANGES file added."
fi


find $NASVER -type f -exec chmod 644 {} \;
find $NASVER -type d -exec chmod 755 {} \;
chmod 755 config/makesrcpkg

chmod 755 $NASVER/config/configure
chmod 755 $NASVER/config/ltmain.sh
chmod 755 $NASVER/config/config.guess
chmod 755 $NASVER/config/config.sub
chmod 755 $NASVER/config/install-sh


tar cvf ${ARCFILE} $NASVER
gzip -v $ARCFILE
rm -rf $NASVER

set -x 
cp -f ${ARCFILE}.gz $HOME/tx/nas/
chmod 644 $HOME/tx/nas/${ARCFILE}.gz

exit