debianisation finished
This commit is contained in:
parent
f9fe6f002e
commit
84f056169b
17 changed files with 84 additions and 38 deletions
|
@ -26,6 +26,7 @@ function error_die()
|
|||
|
||||
# the base directory of your local development files
|
||||
ROOT_DIR=$(dirname "$0")/..
|
||||
ROOT_DIR=$(cd "$ROOT_DIR"; pwd)
|
||||
|
||||
# the template (default) configuration directory
|
||||
DEFAULTCONF_DIR="$ROOT_DIR/etc-defaults.d"
|
||||
|
|
53
scripts/debian
Normal file
53
scripts/debian
Normal file
|
@ -0,0 +1,53 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Copyright (c) 02005 sense.lab <senselab@systemausfall.org>
|
||||
#
|
||||
# License: This script is distributed under the terms of version 2
|
||||
# of the GNU GPL. See the LICENSE file included with the package.
|
||||
#
|
||||
# $Id: cbox-build.sh 336 2005-11-29 22:28:28Z lars $
|
||||
#
|
||||
# build a debian package
|
||||
#
|
||||
|
||||
set -ue
|
||||
|
||||
# include common functions and settings
|
||||
source $(dirname $0)/common.sh.inc
|
||||
|
||||
######### some settings ###########
|
||||
DEB_BUILD_DIR=/tmp/cryptobox-debian-$$
|
||||
[ -e "$DEB_BUILD_DIR" ] && rm -rf "$DEB_BUILD_DIR"
|
||||
|
||||
DEB_ROOT_DIR=$TEMPLATE_DIR
|
||||
DEB_CONTROL_DIR=$ROOT_DIR/DEBIAN
|
||||
DEB_PACKAGE_DIR=$ROOT_DIR/packages
|
||||
|
||||
############# do it ###############
|
||||
|
||||
ACTION=build
|
||||
[ $# -gt 0 ] && ACTION=$1 && shift
|
||||
|
||||
case "$ACTION" in
|
||||
build )
|
||||
# check for uid=0 (necessary for building)
|
||||
[ "$(id -u)" -ne 0 ] && echo "this script ($0) has to be called as root" >&2 && exit 1
|
||||
svn export "$DEB_ROOT_DIR" "$DEB_BUILD_DIR"
|
||||
svn export "$DEB_CONTROL_DIR" "$DEB_BUILD_DIR/DEBIAN"
|
||||
chown -R root. "$DEB_BUILD_DIR/usr/share/doc/"
|
||||
dpkg-deb --build "$DEB_BUILD_DIR" "$DEB_PACKAGE_DIR"
|
||||
rm -rf "$DEB_BUILD_DIR"
|
||||
;;
|
||||
check )
|
||||
PACKAGE_FILE=$(find "$DEB_PACKAGE_DIR" -type f -name "cryptobox*" | grep "\.deb$" | sort -n | tail -1)
|
||||
if [ -z "$PACKAGE_FILE" ]
|
||||
then echo "no debian package found in $DEB_PACKAGE_DIR"
|
||||
else lintian "$PACKAGE_FILE"
|
||||
fi
|
||||
;;
|
||||
* )
|
||||
echo "Syntax: $(basename $0) [ build | check help ]"
|
||||
echo
|
||||
;;
|
||||
esac
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue