File: buildsnap

package info (click to toggle)
bzflag 2.0.2.20050318
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 20,464 kB
  • ctags: 24,134
  • sloc: cpp: 110,038; ansic: 9,514; sh: 4,105; makefile: 1,922; perl: 280; python: 221; xml: 180; objc: 178; php: 143
file content (40 lines) | stat: -rwxr-xr-x 1,644 bytes parent folder | download
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
#!/bin/sh
# build release or cvs snapshop debian packages
if [ -z "$1" -o ! -r configure.in ] ; then
 echo "$0 { cvs | release } - must be run in the project home directory"
 exit 1
fi
if [ "$1" == "release" ] ; then
 if [ ! -r debian/changelog ] ; then
   echo "You must create debian/changelog to do a release"
   exit 1
 fi
 version=`head -n 1 debian/changelog | sed -e 's/.*(//' -e 's/).*//'`
else
 VERSIONID=`grep ^AM_INIT_AUTOMAKE configure.in | sed -e 's/.* //g' -e 's/)//g'`
 MAJOR_VERSION=`sed -e 's/#.*define.*BZ_MAJOR_VERSION[^0-9]*\(.*\)/\1/' -e t -e d < src/date/buildDate.cxx`
 MINOR_VERSION=`sed -e 's/#.*define.*BZ_MINOR_VERSION[^0-9]*\(.*\)/\1/' -e t -e d < src/date/buildDate.cxx`
 REV=`sed -e 's/#.*define.*BZ_REV[^0-9]*\(.*\)/\1/' -e t -e d < src/date/buildDate.cxx`
 PKGVER=1
 date=`date -u --rfc-822`
 version=${MAJOR_VERSION}.${MINOR_VERSION}.${REV}.`date -u +%Y%m%d`-$PKGVER
 sed -e "s/@VERSION@/$version/g" -e "s/@DATE@/$date/g" < debian/changelog.in > debian/changelog
fi
echo "Starting on $date to build:"
arch=$(dpkg-architecture -qDEB_HOST_ARCH)
echo "../bzflag_${version}.${arch}.deb"
echo "../bzflag-server_${version}_${arch}.deb"
echo -n "debian/changelog entry: "
head -n 1 debian/changelog
#./autogen.sh
#./configure
#make maintainer-clean
./autogen.sh
./configure --quiet
chmod +x debian/rules misc/tar
# cvs/non-cvs builds should conflict and replace each other.
PATH=`pwd`/misc:$PATH dpkg-buildpackage -us -uc -rfakeroot
echo "now do \"debsign\" and then a \"dupload ../bzflag_${version}_${arch}.changes\""
if [ "$1" == "release" ] ; then
 echo "don't forget to copy new changelog entry to changelog.in"
fi