summaryrefslogtreecommitdiff
path: root/rpmqv.c
diff options
context:
space:
mode:
authorMichal Schmidt <mschmidt@redhat.com>2010-06-23 14:37:56 +0200
committerPanu Matilainen <pmatilai@redhat.com>2010-06-23 16:06:43 +0300
commit7583fcc3416e5e4accf1c52bc8903149b1314145 (patch)
tree822eef3d54c2a567e76f6edcfb6a0c7d37e0a641 /rpmqv.c
parentb6adef396b6278945ca97a552c8a6020d4a7b628 (diff)
downloadrpm-7583fcc3416e5e4accf1c52bc8903149b1314145.tar.gz
rpm-7583fcc3416e5e4accf1c52bc8903149b1314145.tar.bz2
rpm-7583fcc3416e5e4accf1c52bc8903149b1314145.zip
Allow '--short-circuit' for '-bb'
This patch allows short-circuiting of building binary packages. To prevent accidental use of short-circuited rpms, they are marked with an unsatisfiable dependency "rpmlib(ShortCircuited)". A developer using this feature for local development and testing will use "--nodeps". Should such a rpm leak into the world, users will quickly notice it does not install by default. (v3: avoids API change, suggested by Panu Matilainen. v2: added poisoning with unsatisfiable dependency.) Michal
Diffstat (limited to 'rpmqv.c')
-rw-r--r--rpmqv.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/rpmqv.c b/rpmqv.c
index be2707c92..6104e2ffd 100644
--- a/rpmqv.c
+++ b/rpmqv.c
@@ -660,6 +660,8 @@ int main(int argc, char *argv[])
case 'b':
ba->buildAmount |= RPMBUILD_PACKAGEBINARY;
ba->buildAmount |= RPMBUILD_CLEAN;
+ if ((ba->buildChar == 'b') && ba->shortCircuit)
+ break;
case 'i':
ba->buildAmount |= RPMBUILD_INSTALL;
ba->buildAmount |= RPMBUILD_CHECK;