Add ignore_safety to pisi.conf

This commit is contained in:
Faik Uygur
2009-06-19 06:35:29 +00:00
parent 503c362571
commit 89c1a71464
4 changed files with 4 additions and 3 deletions
+1
View File
@@ -75,6 +75,7 @@ class GeneralDefaults:
package_cache = False
package_cache_limit = 0
bandwidth_limit = 0
ignore_safety = False
ignore_delta = False
class BuildDefaults:
+1 -1
View File
@@ -537,7 +537,7 @@ class Builder:
build_deps = self.spec.source.buildDependencies
if not ctx.get_option('ignore_safety'):
if not ctx.config.values.general.ignore_safety and not ctx.get_option('ignore_safety'):
if self.componentdb.has_component('system.devel'):
build_deps_names = set([x.package for x in build_deps])
devel_deps_names = set(self.componentdb.get_component('system.devel').packages)
+1 -1
View File
@@ -36,7 +36,7 @@ def remove(A, ignore_dep = False, ignore_safety = False):
# filter packages that are not installed
A_0 = A = set(A)
if not ctx.get_option('ignore_safety') and not ignore_safety:
if not ctx.get_option('ignore_safety') and not ctx.config.values.general.ignore_safety and not ignore_safety:
if componentdb.has_component('system.base'):
systembase = set(componentdb.get_union_component('system.base').packages)
refused = A.intersection(systembase)
+1 -1
View File
@@ -237,7 +237,7 @@ def upgrade_base(A = set()):
installdb = pisi.db.installdb.InstallDB()
componentdb = pisi.db.componentdb.ComponentDB()
ignore_build = ctx.get_option('ignore_build_no')
if not ctx.get_option('ignore_safety'):
if not ctx.config.values.general.ignore_safety and not ctx.get_option('ignore_safety'):
if componentdb.has_component('system.base'):
systembase = set(componentdb.get_union_component('system.base').packages)
extra_installs = filter(lambda x: not installdb.has_package(x), systembase - set(A))