Fixed version
[invirt/packages/invirt-dev.git] / invirtibuilder
index c955dfd..bf3b499 100755 (executable)
@@ -202,8 +202,11 @@ def uploadBuild(pocket, workdir):
         except subprocess.CalledProcessError, e:
             if not force:
                 raise
-            package = deb822.Changes(open(changes).read())['Binary']
-            logAndRun(['reprepro-env', 'remove', apt, package])
+            changelog = deb822.Changes(open(changes).read())
+            packages = set(changelog['Binary'].split())
+            packages.add(changelog['Source'])
+            for package in packages:
+                logAndRun(['reprepro-env', 'remove', apt, package])
             logAndRun(upload)