Fixed bz-decompress error message bug.
[doldaconnect.git] / autopackage / makeall
... / ...
CommitLineData
1#!/bin/sh
2
3set -e
4
5tempdir="$(mktemp -d /tmp/dc-apkg-XXXXXX)"
6cd "$tempdir"
7git clone git://git.dolda2000.com/doldaconnect
8cd doldaconnect
9if [ -n "$1" ]; then
10 git checkout "$1"
11fi
12./bootstrap
13./configure
14
15packages="`cat autopackage/build`"
16version="`sed -n 's/^.* VERSION "\([^"]*\)".*$/\1/p' config.h`"
17
18for pkg in $packages; do
19 sfile="autopackage/$pkg.apspec"
20 pname="$(sed -n 's/^ShortName: *\([^ ]\+\)$/\1/p' "$sfile")"
21 if [ -z "$pname" ]; then
22 echo "makeall: could not find apkg shortname for $sfile" >&2
23 exit 1
24 fi
25 make clean
26 PACKAGEFILENAME="$pname.package" makepackage "$sfile"
27 mv "$pname-$version.package" "$pname-$version.package.meta" "$pname.xml" "$tempdir"
28done
29
30rm -rf "$tempdir/doldaconnect"
31
32echo "packages are in $tempdir"