Quick hack to make 'mach' fail when BuildRequires: can not be
fulfilled. Installation of them fails silently, but 'rpmbuild
--rebuild' barfs and user has to install them manually.

2003-12-03  Enrico Scholz  <enrico.scholz@informatik.tu-chemnitz.de>
	* rediffed

2003-11-18  Enrico Scholz  <enrico.scholz@informatik.tu-chemnitz.de>
        * updated (-l switch on 'su')

2003-11-13  Enrico Scholz  <enrico.scholz@informatik.tu-chemnitz.de>
	* created initially
--- mach.cvs/scripts/mach.in~filereq	2003-12-03 01:43:10.000000000 +0100
+++ mach.cvs/scripts/mach.in	2003-12-03 01:44:09.000000000 +0100
@@ -252,7 +252,7 @@
         # remove non-packagey things from buildreqs
         # currently removes everything containing ( or /
         if buildreqs:
-            return filter(lambda x: not re.search("[(/]", x), buildreqs)
+            return filter(lambda x: not re.search("^(/|rpmlib\\()", x), buildreqs)
         else:
             return []
 
@@ -630,7 +630,7 @@
             # fix ownership on all of these
             self.do_chroot ("cd /usr/src/rpm && chown -R machbuild:machbuild *")
             try:
-                self.do_chroot ("cd / && rpmbuild -bs --nodeps %s" \
+                self.do_chroot ("cd / && rpmbuild -bs %s" \
                                 % os.path.join ('usr', 'src', 'rpm', 'SPECS', 
                                                 os.path.basename (specfile)),
                                 "Creating .src.rpm",
@@ -814,7 +814,7 @@
                 debug ("BuildRequires: %s" % buildreqs)
                 try:
         	    self.aptget ("update")
-                    self.aptget ('install -y %s' % buildreqs,
+                    self.aptget ('install -my %s' % buildreqs,
                                  "Installing BuildRequires", self.progress ())
                     # FIXME: build-dep would be nice but only works on a pkg
                     # in the rpm-src tree apparently
@@ -876,7 +876,7 @@
 
             # rebuild from spec inside chroot, note: using a login shell
             # in order to get a vanilla default environment
-            command = "su -c 'rpmbuild -ba --nodeps %s /usr/src/rpm/SPECS/%s 2>&1' - machbuild" % (string.join (options), specfile)
+            command = "su -c 'rpmbuild -ba %s /usr/src/rpm/SPECS/%s 2>&1' - machbuild" % (string.join (options), specfile)
             (status, output) = self.do_chroot (command,
                                                "Rebuilding %s" % srpmname,
                                                True)
