Bug #337603 - Fix invalid '/etc/make.profile is not a symlink' message
authorZac Medico <zmedico@gentoo.org>
Thu, 16 Sep 2010 10:34:08 +0000 (03:34 -0700)
committerZac Medico <zmedico@gentoo.org>
Thu, 16 Sep 2010 10:34:08 +0000 (03:34 -0700)
displayed when /etc/portage/make.profile is perfectly valid.

pym/portage/package/ebuild/config.py

index 8ee93005ae856e5fe515a037a5e6a59f0c9b7409..7c1060f1287a0bbc09fa37045d4ce05ca79d2a16 100644 (file)
@@ -848,9 +848,9 @@ class config(object):
 
                abs_profile_path = os.path.join(self["PORTAGE_CONFIGROOT"],
                        PROFILE_PATH)
-               if not self.profile_path or (not os.path.islink(abs_profile_path) and \
-                       not os.path.exists(os.path.join(abs_profile_path, "parent")) and \
-                       os.path.exists(os.path.join(self["PORTDIR"], "profiles"))):
+               if (not self.profile_path or \
+                       not os.path.exists(os.path.join(self.profile_path, "parent"))) and \
+                       os.path.exists(os.path.join(self["PORTDIR"], "profiles")):
                        writemsg(_("\n\n!!! %s is not a symlink and will probably prevent most merges.\n") % abs_profile_path,
                                noiselevel=-1)
                        writemsg(_("!!! It should point into a profile within %s/profiles/\n") % self["PORTDIR"])