From: Zac Medico Date: Fri, 16 Mar 2007 05:02:20 +0000 (-0000) Subject: Automatically convert ROOT and PORTAGE_CONFIGROOT to absolute paths when necessary... X-Git-Tag: v2.1.2.3~22 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=7ec1629e54531e31ca4d8e4a22b0115cfd1cd5d8;p=portage.git Automatically convert ROOT and PORTAGE_CONFIGROOT to absolute paths when necessary since relative paths lead to problems. (trunk r6209:6211) svn path=/main/branches/2.1.2/; revision=6214 --- diff --git a/pym/portage.py b/pym/portage.py index cfef72343..c977637ec 100644 --- a/pym/portage.py +++ b/pym/portage.py @@ -1004,8 +1004,8 @@ class config: if config_root is None: config_root = "/" - config_root = \ - normalize_path(config_root).rstrip(os.path.sep) + os.path.sep + config_root = normalize_path(os.path.abspath( + config_root)).rstrip(os.path.sep) + os.path.sep check_var_directory("PORTAGE_CONFIGROOT", config_root) @@ -1256,8 +1256,8 @@ class config: if target_root is None: target_root = "/" - target_root = \ - normalize_path(target_root).rstrip(os.path.sep) + os.path.sep + target_root = normalize_path(os.path.abspath( + target_root)).rstrip(os.path.sep) + os.path.sep check_var_directory("ROOT", target_root)