~doko/python/pkg3.3-debian

« back to all changes in this revision

Viewing changes to patches/site-locations.diff

  • Committer: Matthias Klose
  • Date: 2013-01-26 15:27:56 UTC
  • Revision ID: doko@ubuntu.com-20130126152756-wnuhawmmrt8sz0x2
python3.3 (3.3.0-10) experimental; urgency=low

  * Update to 20130126 from the 3.3 branch.
  * Update hurd patches.
  * python3.3-dbg, libpython3.3-dbg: Drop dependency on python.
  * python3.3-dbg: Make gdb (not gdb-minimal) a recommendation.
  * Git rid of build-dependency on python.
  * Add site-packages in virtual environments created by pyvenv.
    Closes: #698777.

 -- Matthias Klose <doko@debian.org>  Sat, 26 Jan 2013 12:17:05 +0100

Show diffs side-by-side

added added

removed removed

Lines of Context:
23
23
+
24
24
 If a file named "pyvenv.cfg" exists one directory above sys.executable,
25
25
 sys.prefix and sys.exec_prefix are set to that directory and
26
 
 it is also checked for site-packages and site-python (sys.prefix and
27
 
@@ -303,10 +309,17 @@
 
26
 it is also checked for site-packages and site-python (sys.base_prefix and
 
27
@@ -303,10 +309,21 @@
28
28
         if sys.platform in ('os2emx', 'riscos'):
29
29
             sitepackages.append(os.path.join(prefix, "Lib", "site-packages"))
30
30
         elif os.sep == '/':
 
31
+            if 'VIRTUAL_ENV' in os.environ:
 
32
+                sitepackages.append(os.path.join(prefix, "lib",
 
33
+                                                 "python" + sys.version[:3],
 
34
+                                                 "site-packages"))
31
35
+            sitepackages.append(os.path.join(prefix, "local/lib",
32
 
+                                        "python" + sys.version[:3],
33
 
+                                        "dist-packages"))
 
36
+                                             "python" + sys.version[:3],
 
37
+                                             "dist-packages"))
34
38
+            sitepackages.append(os.path.join(prefix, "lib",
35
 
+                                        "python3",
36
 
+                                        "dist-packages"))
 
39
+                                             "python3",
 
40
+                                             "dist-packages"))
37
41
+            # this one is deprecated for Debian
38
42
             sitepackages.append(os.path.join(prefix, "lib",
39
 
                                         "python" + sys.version[:3],
 
43
-                                        "python" + sys.version[:3],
40
44
-                                        "site-packages"))
41
45
-            sitepackages.append(os.path.join(prefix, "lib", "site-python"))
42
 
+                                        "dist-packages"))
 
46
+                                             "python" + sys.version[:3],
 
47
+                                             "dist-packages"))
43
48
+            sitepackages.append(os.path.join(prefix, "lib", "dist-python"))
44
49
         else:
45
50
             sitepackages.append(prefix)