From 763c9d2215bdebfc538e9e75f5e1dcc3e4fd5a6b Mon Sep 17 00:00:00 2001 From: Joerg Jaspert Date: Sat, 21 Feb 2009 11:02:49 +0100 Subject: [PATCH] mixed component remove the mixed component part, its LONG gone. Signed-off-by: Joerg Jaspert --- config/debian/dak.conf | 6 ------ dak/check_archive.py | 2 -- dak/check_overrides.py | 2 -- dak/import_archive.py | 24 ++++++------------------ dak/init_db.py | 6 +----- dak/make_overrides.py | 2 -- dak/make_suite_file_list.py | 37 ++----------------------------------- 7 files changed, 9 insertions(+), 70 deletions(-) diff --git a/config/debian/dak.conf b/config/debian/dak.conf index 3cd6705b..d3b9bada 100644 --- a/config/debian/dak.conf +++ b/config/debian/dak.conf @@ -631,12 +631,6 @@ Component Description "Software that fails to meet the DFSG"; MeetsDFSG "false"; }; - - mixed // **NB:** only used for overrides; not yet used in other code - { - Description "Legacy Mixed"; - MeetsDFSG "false"; - }; }; Section diff --git a/dak/check_archive.py b/dak/check_archive.py index f7230b00..80782908 100755 --- a/dak/check_archive.py +++ b/dak/check_archive.py @@ -151,8 +151,6 @@ def check_dscs(): count = 0 suite = 'unstable' for component in Cnf.SubTree("Component").List(): - if component == "mixed": - continue component = component.lower() list_filename = '%s%s_%s_source.list' % (Cnf["Dir::Lists"], suite, component) list_file = utils.open_file(list_filename) diff --git a/dak/check_overrides.py b/dak/check_overrides.py index ff01306d..1e7e5384 100755 --- a/dak/check_overrides.py +++ b/dak/check_overrides.py @@ -331,8 +331,6 @@ def main (): utils.fubar("Couldn't find id's of all suites: %s" % suites) for component in Cnf.SubTree("Component").List(): - if component == "mixed": - continue; # Ick # It is crucial for the dsc override creation based on binary # overrides that 'dsc' goes first otypes = Cnf.ValueList("OverrideType") diff --git a/dak/import_archive.py b/dak/import_archive.py index 3e5100be..028239b0 100755 --- a/dak/import_archive.py +++ b/dak/import_archive.py @@ -233,13 +233,10 @@ def update_locations (): SubSec = Cnf.SubTree("Location::%s" % (location)) archive_id = database.get_archive_id(SubSec["archive"]) type = SubSec.Find("type") - if type == "legacy-mixed": - projectB.query("INSERT INTO location (path, archive, type) VALUES ('%s', %d, '%s')" % (location, archive_id, SubSec["type"])) - else: - for component in Cnf.SubTree("Component").List(): - component_id = database.get_component_id(component) - projectB.query("INSERT INTO location (path, component, archive, type) VALUES ('%s', %d, %d, '%s')" % - (location, component_id, archive_id, SubSec["type"])) + for component in Cnf.SubTree("Component").List(): + component_id = database.get_component_id(component) + projectB.query("INSERT INTO location (path, component, archive, type) VALUES ('%s', %d, %d, '%s')" % + (location, component_id, archive_id, SubSec["type"])) def update_architectures (): projectB.query("DELETE FROM architecture") @@ -542,11 +539,7 @@ Please read the documentation before running this script. SubSec = Cnf.SubTree("Location::%s" % (location)) server = SubSec["Archive"] type = Cnf.Find("Location::%s::Type" % (location)) - if type == "legacy-mixed": - sources = location + 'Sources.gz' - suite = Cnf.Find("Location::%s::Suite" % (location)) - do_sources(sources, suite, "", server) - elif type == "legacy" or type == "pool": + if type == "pool": for suite in Cnf.ValueList("Location::%s::Suites" % (location)): for component in Cnf.SubTree("Component").List(): sources = Cnf["Dir::Root"] + "dists/" + Cnf["Suite::%s::CodeName" % (suite)] + '/' + component + '/source/' + 'Sources.gz' @@ -560,12 +553,7 @@ Please read the documentation before running this script. SubSec = Cnf.SubTree("Location::%s" % (location)) server = SubSec["Archive"] type = Cnf.Find("Location::%s::Type" % (location)) - if type == "legacy-mixed": - packages = location + 'Packages' - suite = Cnf.Find("Location::%s::Suite" % (location)) - print 'Processing '+location+'...' - process_packages (packages, suite, "", server) - elif type == "legacy" or type == "pool": + if type == "pool": for suite in Cnf.ValueList("Location::%s::Suites" % (location)): udeb_components = map(lambda x: x+"/debian-installer", Cnf.ValueList("Suite::%s::UdebComponents" % suite)) diff --git a/dak/init_db.py b/dak/init_db.py index d6a7ebfb..e1f1bced 100755 --- a/dak/init_db.py +++ b/dak/init_db.py @@ -106,11 +106,7 @@ def do_location(): utils.fubar("Archive '%s' for location '%s' not found." % (location_config["Archive"], location)) location_type = location_config.get("type") - if location_type == "legacy-mixed": - projectB.query("INSERT INTO location (path, archive, type) VALUES " - "('%s', %d, '%s')" - % (location, archive_id, location_config["type"])) - elif location_type == "legacy" or location_type == "pool": + if location_type == "pool": for component in Cnf.SubTree("Component").List(): component_id = database.get_component_id(component) projectB.query("INSERT INTO location (path, component, " diff --git a/dak/make_overrides.py b/dak/make_overrides.py index bff25dd9..8fdde8b1 100755 --- a/dak/make_overrides.py +++ b/dak/make_overrides.py @@ -125,8 +125,6 @@ def main (): sys.stderr.write("Processing %s...\n" % (suite)) override_suite = Cnf["Suite::%s::OverrideCodeName" % (suite)] for component in Cnf.SubTree("Component").List(): - if component == "mixed": - continue # Ick for otype in Cnf.ValueList("OverrideType"): if otype == "deb": suffix = "" diff --git a/dak/make_suite_file_list.py b/dak/make_suite_file_list.py index 941c7370..fdf2c5e3 100755 --- a/dak/make_suite_file_list.py +++ b/dak/make_suite_file_list.py @@ -202,34 +202,6 @@ def cleanup(packages): ################################################################################ -def write_legacy_mixed_filelist(suite, list, packages, dislocated_files): - # Work out the filename - filename = os.path.join(Cnf["Dir::Lists"], "%s_-_all.list" % (suite)) - output = utils.open_file(filename, "w") - # Generate the final list of files - files = {} - for fileid in list: - path = packages[fileid]["path"] - filename = packages[fileid]["filename"] - file_id = packages[fileid]["file_id"] - if suite == "stable" and dislocated_files.has_key(file_id): - filename = dislocated_files[file_id] - else: - filename = path + filename - if files.has_key(filename): - utils.warn("%s (in %s) is duplicated." % (filename, suite)) - else: - files[filename] = "" - # Sort the files since apt-ftparchive doesn't - keys = files.keys() - keys.sort() - # Write the list of files out - for outfile in keys: - output.write(outfile+'\n') - output.close() - -############################################################ - def write_filelist(suite, component, arch, type, list, packages, dislocated_files): # Work out the filename if arch != "source": @@ -326,13 +298,8 @@ def write_filelists(packages, dislocated_files): filelist.extend(d[suite][component]["all"][packagetype]) write_filelist(suite, component, arch, packagetype, filelist, packages, dislocated_files) - else: # legacy-mixed suite - filelist = [] - for component in d[suite].keys(): - for arch in d[suite][component].keys(): - for packagetype in d[suite][component][arch].keys(): - filelist.extend(d[suite][component][arch][packagetype]) - write_legacy_mixed_filelist(suite, filelist, packages, dislocated_files) + else: # something broken + utils.warn("Suite %s has no components." % (suite)) ################################################################################ -- 2.39.5