source: trunk/debian/package/robocfg/build.sh @ 293

Last change on this file since 293 was 293, checked in by amain, 8 years ago

robocfg: increase package version number

  • Property svn:executable set to *
File size: 1.1 KB
RevLine 
[76]1#!/bin/bash
2#
3# 1. Download package and unpack package
4# 2. Copy debian/directory to it
5# 3. Run dpkg-buildpackage --arch=<ARCH> -rfakeroot
6
7if [ -z $ARCH ]; then echo "First set \$ARCH before running the build script"; exit 1; fi
8
9export DEBFULLNAME="Amain (DebWrt.net)"
10export LC_ALL=C
11VERBOSE=1
12
13[ "1" == $VERBOSE ] && set -x
14
15PACKAGE=robocfg
[293]16VERSION=1.0.1
[76]17RELEASE=1
18DOWNLOAD_URL=svn://svn.openwrt.org/openwrt/trunk/package/robocfg
19DEP=
20
21BASE_DIR=/usr/src
22BUILD_BASE_DIR=${BASE_DIR}/${PACKAGE}
23BUILD_DIR=${BUILD_BASE_DIR}/${PACKAGE}-${VERSION}
24DOWNLOAD_DIR=${BASE_DIR}/dl
25
26mkdir -p $DOWNLOAD_DIR
27rm -rf ${BUILD_DIR}
28mkdir -p ${BUILD_DIR}
29svn co ${DOWNLOAD_URL} ${BUILD_DIR}
30
31if [ ! -d debian ]; then
32   cd ${BUILD_DIR} 
33   dh_make -c gpl -e "amain@debwrt.net" -s -n
34   echo "Please complete debian package configuration. When done: cp -ra ${BUILD_DIR}/debian ."
35else
36   cp -rav debian ${BUILD_DIR}
37   cd ${BUILD_DIR}
38   dpkg-buildpackage -a${ARCH} -rfakeroot
39   find ${BUILD_BASE_DIR} -maxdepth 1 -name "*.deb"  | xargs -r -t -i sudo dpkg-cross -a ${ARCH} -i {} || true
40fi
41
Note: See TracBrowser for help on using the repository browser.