get arch,dist and dist_release of pisi.conf from variables
This commit is contained in:
@@ -95,7 +95,8 @@ class Generals:
|
|||||||
def __init__(self):
|
def __init__(self):
|
||||||
self.values = ctx.config.values
|
self.values = ctx.config.values
|
||||||
self.architecture = self.values.general.architecture
|
self.architecture = self.values.general.architecture
|
||||||
|
self.distribution = self.values.general.distribution
|
||||||
|
self.distribution_release = self.values.general.distribution_release
|
||||||
|
|
||||||
# As we import this module from build.py, we can't init glb as a
|
# As we import this module from build.py, we can't init glb as a
|
||||||
# singleton here. Or else Python will bug us with NoneType errors
|
# singleton here. Or else Python will bug us with NoneType errors
|
||||||
|
|||||||
@@ -160,13 +160,13 @@ def install_pkg_files(package_URIs, reinstall = False):
|
|||||||
if not ctx.get_option('ignore_check'):
|
if not ctx.get_option('ignore_check'):
|
||||||
for x in d_t.keys():
|
for x in d_t.keys():
|
||||||
pkg = d_t[x]
|
pkg = d_t[x]
|
||||||
if pkg.distributionRelease != ctx.config.values.get("general", "distribution_release"):
|
if pkg.distributionRelease != ctx.config.values.general.distribution_release:
|
||||||
raise Exception(_('Package %s is not compatible with your distribution release %s %s.') \
|
raise Exception(_('Package %s is not compatible with your distribution release %s %s.') \
|
||||||
% (x, ctx.config.values.get("general", "distribution"), \
|
% (x, ctx.config.values.general.distribution, \
|
||||||
ctx.config.values.get("general", "distribution_release")))
|
ctx.config.values.general.distribution_release))
|
||||||
if pkg.architecture != ctx.config.values.get("general", "architecture"):
|
if pkg.architecture != ctx.config.values.general.architecture:
|
||||||
raise Exception(_('Package %s (%s) is not compatible with your %s architecture.') \
|
raise Exception(_('Package %s (%s) is not compatible with your %s architecture.') \
|
||||||
% (x, pkg.architecture, ctx.config.values.get("general", "architecture")))
|
% (x, pkg.architecture, ctx.config.values.general.architecture))
|
||||||
|
|
||||||
def satisfiesDep(dep):
|
def satisfiesDep(dep):
|
||||||
# is dependency satisfied among available packages
|
# is dependency satisfied among available packages
|
||||||
|
|||||||
Reference in New Issue
Block a user