/usr/sbin/pdebuild-cross-create is in pdebuild-cross 2.2.18.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 | #!/bin/sh
set -e
# Copyright 2010 Neil Williams <codehelp@debian.org>
#
# This package is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
. gettext.sh
TEXTDOMAIN="xapt"
export TEXTDOMAIN
TEXTDOMAINDIR="/usr/share/locale/"
export TEXTDOMAINDIR
cfg="/etc/pdebuild-cross/pdebuild-cross.rc"
if [ ! -f $cfg ]; then
eval_gettext "\$cfg does not exist!"; echo
exit 1
fi
. $cfg
if [ -z "$BUILDPLACE" ]; then
eval_gettext "Broken config, no BUILDPLACE set in '\$cfg'."; echo
exit 2
fi
if [ -f $BASETGZ ]; then
eval_gettext "\$BASETGZ exists! If you want to create a new one, delete or move '\$BASETGZ'."; echo
eval_gettext "Otherwise, use 'pbuilder login --configfile /etc/pdebuild-cross/pdebuild-cross.rc --save-after-login'"; echo
eval_gettext "to make changes within the existing \$BASETGZ."; echo
exit 3
fi
if [ ! -d $BUILDPLACE ]; then
mkdir -p $BUILDPLACE
else
rm -rf $BUILDPLACE/*
fi
if [ -z "$CROSSARCH" ]; then
# get crossarch from dpkg-cross - check if it is not None
if [ -f /etc/dpkg-cross/cross-compile ]; then
DEFARCH=`grep "^default_arch" /etc/dpkg-cross/cross-compile|sed -e 's/default_arch *= *\(.*\)/\1/'`
if [ -n "$DEFARCH" -a "$DEFARCH" != "None" ]; then
CROSSARCH="$DEFARCH"
fi
else
eval_gettext "No CROSSARCH set in '\$cfg' and no dpkg-cross default: You must specify one."; echo
fi
fi
if [ -z "$MULTISTRAPFILE" ]; then
if [ -f "/usr/share/multistrap/${CROSSARCH}.conf" ]; then
MULTISTRAPFILE=/usr/share/multistrap/${CROSSARCH}.conf
else
eval_gettext "Need a multistrap configuration file specified in \$cfg!"; echo
exit 4
fi
fi
multistrap -f $MULTISTRAPFILE -d $BUILDPLACE
|