1 |
commit: 3e4f4bc617fe6107ff661705ae359084c9311c12 |
2 |
Author: wiktor w brodlo <wiktor <AT> brodlo <DOT> net> |
3 |
AuthorDate: Mon Jul 4 21:41:26 2011 +0000 |
4 |
Commit: Wiktor W Brodlo <wiktor <AT> brodlo <DOT> net> |
5 |
CommitDate: Mon Jul 4 21:41:26 2011 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/anaconda.git;a=commit;h=3e4f4bc6 |
7 |
|
8 |
Set profile and update the progress bar |
9 |
|
10 |
--- |
11 |
gentoo/livecd.py | 1 + |
12 |
gentoo/utils.py | 27 ++++++++++++++++++++++----- |
13 |
2 files changed, 23 insertions(+), 5 deletions(-) |
14 |
|
15 |
diff --git a/gentoo/livecd.py b/gentoo/livecd.py |
16 |
index 19e755d..a59612c 100644 |
17 |
--- a/gentoo/livecd.py |
18 |
+++ b/gentoo/livecd.py |
19 |
@@ -118,6 +118,7 @@ class LiveCDCopyBackend(backend.AnacondaBackend): |
20 |
# Now copy the portage tree |
21 |
self._gentoo_install.copy_portage() |
22 |
self._gentoo_install.install_setup_tools() |
23 |
+ self._gentoo_install.set_profile() |
24 |
|
25 |
self._gentoo_install.setup_users() |
26 |
self._gentoo_install.setup_language() # before ldconfig, thx |
27 |
|
28 |
diff --git a/gentoo/utils.py b/gentoo/utils.py |
29 |
index 60c332a..af1f17e 100644 |
30 |
--- a/gentoo/utils.py |
31 |
+++ b/gentoo/utils.py |
32 |
@@ -777,8 +777,8 @@ class GentooInstall: |
33 |
# self._setup_packages_to_remove() |
34 |
|
35 |
action = _("System Installation") |
36 |
- copy_update_interval = 100 |
37 |
- copy_update_counter = 99 |
38 |
+ copy_update_interval = 10 |
39 |
+ copy_update_counter = 9 |
40 |
# get file counters |
41 |
total_files = 0 |
42 |
image_dir = self._prod_root |
43 |
@@ -1053,15 +1053,32 @@ class GentooInstall: |
44 |
|
45 |
def copy_portage(self): |
46 |
self._progress.set_fraction(0.0) |
47 |
- self._progress.set_text(_("Copying the Portage tree")) |
48 |
+ self._progress.set_text(_("Copying the Portage tree (can take a long time)")) |
49 |
subprocess.call(["cp", "--recursive", "/usr/portage", self._root+"/usr/"]) |
50 |
# We need some packages from anaconda-overlay but ideally they should be added to portage |
51 |
self._progress.set_fraction(0.5) |
52 |
subprocess.call(["cp", "--recursive", "/anaconda-overlay", self._root+"/usr/portage"]) |
53 |
+ self._progress.set_fraction(1) |
54 |
|
55 |
def install_setup_tools(self): |
56 |
- self._portage.install("system-config-date system-config-keyboard system-config-users") |
57 |
- self._portage.install("keyboard-configuration-helpers language-configuration-helpers") |
58 |
+ self._progress.set_fraction(0.0) |
59 |
+ self._progress.set_text(_("Installing configuration helpers")) |
60 |
+ self.install_package("system-config-date") |
61 |
+ self._progress.set_fraction(0.2) |
62 |
+ self.install_package("system-config-keyboard") |
63 |
+ self._progress.set_fraction(0.4) |
64 |
+ self.install_package("system-config-users") |
65 |
+ self._progress.set_fraction(0.6) |
66 |
+ self.install_package("keyboard-configuration-helpers") |
67 |
+ self._progress.set_fraction(0.8) |
68 |
+ self.install_package("language-configuration-helpers") |
69 |
+ self._progress.set_fraction(1.0) |
70 |
+ |
71 |
+ def set_profile(self): |
72 |
+ self._progress.set_fraction(0.0) |
73 |
+ self._progress.set_text(_("Setting profile %s" % self._anaconda.profile)) |
74 |
+ self.spawn_chroot("eselect profile set "+self._anaconda.profile) |
75 |
+ self._progress.set_fraction(1.0) |
76 |
|
77 |
#def _get_langpacks(self): |
78 |
# return [x.strip() for x in LANGUAGE_PACKS.split("\n") if \ |