]> git.proxmox.com Git - mirror_frr.git/blame - tools/build-debian-package.sh
snapcraft: Don't stage libc6
[mirror_frr.git] / tools / build-debian-package.sh
CommitLineData
836ad9fb
DB
1#!/bin/sh
2#
3# Written by Daniil Baturin, 2018
4# This file is public domain
3e662ed3 5set -e
836ad9fb 6
3e662ed3
DL
7cd "`dirname $0`"
8cd ..
836ad9fb 9
3e662ed3
DL
10if [ "`id -u`" = 0 ]; then
11 echo "Running as root - installing dependencies"
12 apt-get install fakeroot debhelper devscripts
13 mk-build-deps --install debian/control
14 exit 0
836ad9fb
DB
15fi
16
3e662ed3 17git diff-index --quiet HEAD || echo "Warning: git working directory is not clean!"
836ad9fb
DB
18
19echo "Preparing the build"
3e662ed3 20tools/tarsource.sh -V
836ad9fb
DB
21
22echo "Building the Debian package"
3e662ed3
DL
23if test $# -eq 0; then
24 dpkg-buildpackage -b -uc -us
25else
26 dpkg-buildpackage "$@"
27fi