diff --git a/ChangeLog b/ChangeLog index 1593f70f..70f6b757 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2010-02-22 Fatih Aşıcı + * pisi/cli/addrepo.py, pisi/db/repodb.py: Remove the check + for repository architecture as the current infrastructure + doesn't allow a unified repository for multiple + architectures. + 2010-02-12 Serdar Dalgıç * pisi/operations/build.py: Use glob.glob0 and lstrip instead of glob.glob. Typos in filePaths in pspec.xml were sometimes ignored and @@ -74,7 +80,7 @@ repository. 2009-12-14 Serdar Dalgıç - * Add architecture and distribution release check to pisi add-repo + * Add architecture and distribution release check to pisi add-repo New parameter --ignore-check is added to pisi ar too. 2009-12-11 Serdar Dalgıç diff --git a/pisi/cli/addrepo.py b/pisi/cli/addrepo.py index 1c81b73d..73ad11e9 100644 --- a/pisi/cli/addrepo.py +++ b/pisi/cli/addrepo.py @@ -43,8 +43,8 @@ NB: We support only local files (e.g., /a/b/c) and http:// URIs at the moment def options(self): group = optparse.OptionGroup(self.parser, _("add-repo options")) - group.add_option("--ignore-check", action="store_true", default=False, help=_("Ignore repository distribution and architecture check")) - group.add_option("--no-fetch", action="store_true", default=False, help=_("Does not fetch repository index and does not check distribution and architecture match")) + group.add_option("--ignore-check", action="store_true", default=False, help=_("Ignore repository distribution check")) + group.add_option("--no-fetch", action="store_true", default=False, help=_("Does not fetch repository index and does not check distribution match")) group.add_option("--at", action="store", type="int", default=None, help=_("Add repository at given position (0 is first)")) @@ -55,8 +55,6 @@ NB: We support only local files (e.g., /a/b/c) and http:// URIs at the moment pisi.api.remove_repo(repo) def check_arch_and_distro(self, repo): - if not self.repodb.check_architecture(repo): - self.warn_and_remove(_("Repository architecture does not match. Removing %s from system.") % repo) if not self.repodb.check_distribution(repo): self.warn_and_remove(_("Repository distribution does not match. Removing %s from system.") % repo) @@ -74,7 +72,7 @@ NB: We support only local files (e.g., /a/b/c) and http:// URIs at the moment if ctx.get_option('no_fetch'): if not ctx.ui.confirm(_('Add %s repository without updating the database?\nBy confirming ' 'this you are also adding the repository to your system without ' - 'checking the distribution and the architecture of the repository.\n' + 'checking the distribution of the repository.\n' 'Do you want to continue?') % name): return diff --git a/pisi/db/repodb.py b/pisi/db/repodb.py index 661f9182..1cb28df7 100644 --- a/pisi/db/repodb.py +++ b/pisi/db/repodb.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- # -# Copyright (C) 2005 - 2007, TUBITAK/UEKAE +# Copyright (C) 2005 - 2010, TUBITAK/UEKAE # # This program is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License as published by the Free @@ -214,10 +214,6 @@ class RepoDB(lazydb.LazyDB): def repo_active(self, name): return self.repoorder.get_status(name) == "active" - def get_architecture(self, name): - doc = self.get_repo_doc(name) - return doc.getTag("Distribution").getTagData("Architecture") - def get_distribution(self, name): doc = self.get_repo_doc(name) return doc.getTag("Distribution").getTagData("SourceName") @@ -226,11 +222,6 @@ class RepoDB(lazydb.LazyDB): doc = self.get_repo_doc(name) return doc.getTag("Distribution").getTagData("Version") - def check_architecture(self, name): - return self.get_architecture(name) == ctx.config.values.general.architecture - def check_distribution(self, name): return self.get_distribution(name) == ctx.config.values.general.distribution and \ self.get_distribution_release(name) == ctx.config.values.general.distribution_release - -