###############################################################################
-import commands, os, pg, re, sys, time
+import commands, os, pg, sys, time
import apt_pkg
from daklib import database
from daklib import utils
from daklib.dak_exceptions import *
-
-###############################################################################
-
-re_arch_from_filename = re.compile(r"binary-[^/]+")
+from daklib.regexes import re_arch_from_filename
###############################################################################
###############################################################################
def do_sources(sources, suite, component, server):
- temp_filename = utils.temp_filename()
+ (fd, temp_filename) = utils.temp_filename()
(result, output) = commands.getstatusoutput("gunzip -c %s > %s" % (sources, temp_filename))
if (result != 0):
utils.fubar("Gunzip invocation failed!\n%s" % (output), result)