Gentoo Archives: gentoo-commits

From: "Fabian Groffen (grobian)" <grobian@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] portage r11505 - main/branches/prefix/bin
Date: Thu, 11 Sep 2008 17:48:04
Message-Id: E1KdqGv-0001Da-TU@stork.gentoo.org
1 Author: grobian
2 Date: 2008-09-11 17:47:56 +0000 (Thu, 11 Sep 2008)
3 New Revision: 11505
4
5 Modified:
6 main/branches/prefix/bin/emaint
7 main/branches/prefix/bin/regenworld
8 Log:
9 Fix usages of WORLD_FILE (seems to be a mixup of config_root and target_root, of which the latter caused problems as observed by darkside in bug #237323
10
11 Modified: main/branches/prefix/bin/emaint
12 ===================================================================
13 --- main/branches/prefix/bin/emaint 2008-09-11 17:32:16 UTC (rev 11504)
14 +++ main/branches/prefix/bin/emaint 2008-09-11 17:47:56 UTC (rev 11505)
15 @@ -37,7 +37,7 @@
16 def _check_world(self, onProgress):
17 categories = set(portage.settings.categories)
18 myroot = portage.settings["ROOT"]
19 - self.world_file = os.path.join(myroot, portage.const.WORLD_FILE)
20 + self.world_file = os.path.join(myroot, portage.const.EPREFIX_LSTRIP, portage.const.WORLD_FILE)
21 self.found = os.access(self.world_file, os.R_OK)
22 vardb = portage.db[myroot]["vartree"].dbapi
23
24
25 Modified: main/branches/prefix/bin/regenworld
26 ===================================================================
27 --- main/branches/prefix/bin/regenworld 2008-09-11 17:32:16 UTC (rev 11504)
28 +++ main/branches/prefix/bin/regenworld 2008-09-11 17:47:56 UTC (rev 11505)
29 @@ -44,7 +44,7 @@
30 __uniqlist__.append(pkgline)
31 return True
32
33 -world_file = os.path.join("/", portage.WORLD_FILE)
34 +world_file = os.path.join(portage.const.EPREFIX, portage.WORLD_FILE)
35
36 # show a little description if we have arguments
37 if len(sys.argv) >= 2 and sys.argv[1] in ["-h", "--help"]:
38 @@ -54,7 +54,7 @@
39 print "your existing world file (%s) before using this tool." % world_file
40 sys.exit(0)
41
42 -worldlist = portage.grabfile(os.path.join("/", portage.WORLD_FILE))
43 +worldlist = portage.grabfile(os.path.join(portage.const.EPREFIX, portage.WORLD_FILE))
44 syslist = portage.settings.packages
45 syslist = filter(issyspkg, syslist)
46
47 @@ -98,5 +98,5 @@
48 print "add to world:",myfavkey
49 worldlist.append(myfavkey)
50
51 -portage.write_atomic(os.path.join("/", portage.WORLD_FILE),
52 +portage.write_atomic(os.path.join(portage.const.EPREFIX, portage.WORLD_FILE),
53 "\n".join(sorted(worldlist)) + "\n")