From 1a46f3afacb665d1b49f3b05498beba5b7be948d Mon Sep 17 00:00:00 2001 From: Mike Khiretskiy Date: Mon, 7 Sep 2015 17:03:23 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9C=D0=BD=D0=BE=D0=B6=D0=B5=D1=81=D1=82?= =?UTF-8?q?=D0=B2=D0=B5=D0=BD=D0=BD=D1=8B=D0=B5=20=D0=B8=D0=B7=D0=BC=D0=B5?= =?UTF-8?q?=D0=BD=D0=B5=D0=BD=D0=B8=D1=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit assemble.env -> builder.env Исправлено скачивание видеодрайверов Исправлен список исключения --keep-tree=off --- pym/builder/build_storage.py | 2 +- pym/builder/utils/cl_builder_image.py | 3 +++ pym/builder/variables/builder.py | 8 ++++++-- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/pym/builder/build_storage.py b/pym/builder/build_storage.py index f3d7de3..226c503 100644 --- a/pym/builder/build_storage.py +++ b/pym/builder/build_storage.py @@ -142,7 +142,7 @@ class BuildStorage(object): """ Хранилище в котором находится информация о собираемом дистрибутиве """ - ini_file = "/etc/calculate/assemble.env" + ini_file = "/etc/calculate/builder.env" data_dir = path.join(builder_data, "mount") def __init__(self, data_dir=None, ini_file=None): diff --git a/pym/builder/utils/cl_builder_image.py b/pym/builder/utils/cl_builder_image.py index 319b50e..cd97ddf 100644 --- a/pym/builder/utils/cl_builder_image.py +++ b/pym/builder/utils/cl_builder_image.py @@ -55,6 +55,9 @@ class ClBuilderImageAction(Action): '"-afmR")', 'condition': lambda Get: Get('cl_builder_prelink_set') == 'on' }, + {'name': 'reconfigure_vars1', + 'method': 'Builder.invalidateVariables("cl_builder_linux_datavars")', + }, # получить видеодрайверы {'name': 'fetch_video_drivers', 'group': __("Fetching video drivers"), diff --git a/pym/builder/variables/builder.py b/pym/builder/variables/builder.py index cb76a1b..56584f6 100644 --- a/pym/builder/variables/builder.py +++ b/pym/builder/variables/builder.py @@ -676,7 +676,6 @@ class VariableClBuilderPkgdir(Variable): else: return "" - class VariableClBuilderAction(ReadonlyVariable): """ Дополнительное действие по созданию образа: iso, squash. @@ -1150,9 +1149,10 @@ class VariableClBuilderSquashExclude(ReadonlyVariable): def get(self): builder_path = self.Get('cl_builder_path') keep_tree = self.GetBool('cl_builder_keep_tree_set') - excludes = ["", "metadata", "profiles/templates/deprecated"] + excludes = ["", "metadata"] important = [".git", "distfiles", "packages", "eclass", "metadata", "profiles", "layout.conf"] + exclude_dirs = ["profiles/templates/deprecated"] def generator(): for rep_dn in self.Get('cl_builder_repository_location'): @@ -1161,6 +1161,10 @@ class VariableClBuilderSquashExclude(ReadonlyVariable): for exclude_name in (x for x in listDirectory(dn) if x not in important): yield path.join(rep_dn, exclude_dn, exclude_name)[1:] + for exclude_dn in exclude_dirs: + dn = pathJoin(builder_path, rep_dn, exclude_dn) + if path.exists(dn): + yield path.join(rep_dn, exclude_dn) if not keep_tree and builder_path: return list(generator())