aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Blake <eblake@redhat.com>2011-12-07 09:26:57 -0700
committerEric Blake <eblake@redhat.com>2011-12-08 14:37:15 -0700
commitf48ab7d888fd72604dab67034c87da31fa8d0d27 (patch)
tree8de8973df34373aef2c809639601bc7bf447b79e /bootstrap.conf
parenttest: fix potential lock corruption in test driver (diff)
downloadlibvirt-f48ab7d888fd72604dab67034c87da31fa8d0d27.tar.gz
libvirt-f48ab7d888fd72604dab67034c87da31fa8d0d27.tar.bz2
libvirt-f48ab7d888fd72604dab67034c87da31fa8d0d27.zip
maint: allow bootstrap in a sandbox
Jiri Denemark reported an instance of bootstrapping libvirt failing when run inside a sandbox, traced to rpm trying to access /var/ which was not permitted by the sandbox. Alex Jia reported that 0.9.8-rc1 failed to bootstrap if patch(1) is not installed. * bootstrap.conf (buildreq): Avoid rpm call if python-config exists. Also, require patch, in case we have gnulib-local diffs.
Diffstat (limited to 'bootstrap.conf')
-rw-r--r--bootstrap.conf10
1 files changed, 6 insertions, 4 deletions
diff --git a/bootstrap.conf b/bootstrap.conf
index a29159029..c3527180a 100644
--- a/bootstrap.conf
+++ b/bootstrap.conf
@@ -195,6 +195,7 @@ gettext 0.17
git 1.5.5
gzip -
libtool -
+patch -
perl 5.5
pkg-config -
python-config -
@@ -203,10 +204,11 @@ tar -
xmllint -
xsltproc -
"
-# You don't have to be on a system with rpm; rather, if you happen to
-# be on RHEL 5, then this bypasses the bootstrap logic that probes for
-# a working 'python-config --version'.
-if `(rpm -q python-devel) >/dev/null 2>&1`; then
+# Use rpm as a fallback to bypass the bootstrap probe for python-config,
+# for the sake of RHEL 5; without requiring it on newer systems that
+# have python-config to begin with.
+if `(${PYTHON_CONFIG-python-config} --version;
+ test $? -lt 126 || rpm -q python-devel) >/dev/null 2>&1`; then
PYTHON_CONFIG=true
fi