]> git.proxmox.com Git - mirror_frr.git/blob - tools/build-debian-package.sh
Merge pull request #5285 from ton31337/fix/send_BGP_NOTIFY_CEASE_PEER_UNCONFIG_after_...
[mirror_frr.git] / tools / build-debian-package.sh
1 #!/bin/sh
2 #
3 # Written by Daniil Baturin, 2018
4 # This file is public domain
5 set -e
6
7 cd "`dirname $0`"
8 cd ..
9
10 if [ "`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
15 fi
16
17 git diff-index --quiet HEAD || echo "Warning: git working directory is not clean!"
18
19 echo "Preparing the build"
20 tools/tarsource.sh -V
21
22 echo "Building the Debian package"
23 if test $# -eq 0; then
24 dpkg-buildpackage -b -uc -us
25 else
26 dpkg-buildpackage "$@"
27 fi