diff options
author | Konrad Hinsen <konrad.hinsen@fastmail.net> | 2024-01-04 13:44:19 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2024-08-31 10:44:38 +0200 |
commit | d5e0180805f52ef38a03ff9d6c11dd6174e3526b (patch) | |
tree | c93af2fff8f6f2bf2ad34737761a65a7b49404d3 /gnu/packages/aux-files/python | |
parent | be86f3de1eb175ba3e17f2146f2c96849f4f4fe7 (diff) | |
download | guix-d5e0180805f52ef38a03ff9d6c11dd6174e3526b.tar.gz guix-d5e0180805f52ef38a03ff9d6c11dd6174e3526b.zip |
gnu: python: Normalize sys.prefix in sitecustomize.py.
* gnu/packages/aux-files/python/sitecustomize.py: normalize sys.prefix to deal
with situations where it contains "../", as can happen in relocatable packs.
Change-Id: Ibfe13d7c2a14beaa199f599e64bc0b7bfb500fe8
Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Diffstat (limited to 'gnu/packages/aux-files/python')
-rw-r--r-- | gnu/packages/aux-files/python/sitecustomize.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gnu/packages/aux-files/python/sitecustomize.py b/gnu/packages/aux-files/python/sitecustomize.py index e2348e0356..82ea91104d 100644 --- a/gnu/packages/aux-files/python/sitecustomize.py +++ b/gnu/packages/aux-files/python/sitecustomize.py @@ -37,7 +37,7 @@ import sys major_minor = '{}.{}'.format(*sys.version_info) site_packages_prefix = os.path.join( 'lib', 'python' + major_minor, 'site-packages') -python_site = os.path.join(sys.prefix, site_packages_prefix) +python_site = os.path.normpath(os.path.join(sys.prefix, site_packages_prefix)) try: all_sites_raw = os.environ['GUIX_PYTHONPATH'].split(os.path.pathsep) |