From ad50ac00a531dbe60260c63760388ce6dac12361 Mon Sep 17 00:00:00 2001 From: Mattia Rizzolo Date: Wed, 17 Jun 2015 19:21:48 +0000 Subject: import 0.125+nmu3 --- pbuilder-unshare-wrapper | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100755 pbuilder-unshare-wrapper (limited to 'pbuilder-unshare-wrapper') diff --git a/pbuilder-unshare-wrapper b/pbuilder-unshare-wrapper new file mode 100755 index 0000000..ffa25c8 --- /dev/null +++ b/pbuilder-unshare-wrapper @@ -0,0 +1,21 @@ +#!/bin/sh + +die() { + echo >&@ E: $2 returned error code $1 + echo >&2 N: Could not set up the loopback interface. + exit 1 +} + +if test -x /sbin/ifconfig; then + /sbin/ifconfig lo up || die $? ifconfig +elif test -x /sbin/ip; then + /sbin/ip link set lo up || die $? ip +elif test -x /bin/ip; then + /bin/ip link set lo up || die $? ip +else + echo >&2 E: Neither ifconfig nor ip found. + echo >&2 N: Could not set up the loopback interface. + exit 1 +fi + +exec "$@" -- cgit v1.2.3