]> git.pld-linux.org Git - packages/python3.git/blame - python3-noarch_to_datadir.patch
- renamed from xxx30 to xxx3
[packages/python3.git] / python3-noarch_to_datadir.patch
CommitLineData
f215c9da
AF
1--- Python-3.0.1/Modules/getpath.c.wiget 2009-02-25 10:58:09.000000000 +0100
2+++ Python-3.0.1/Modules/getpath.c 2009-02-25 11:21:43.000000000 +0100
e684db95
AM
3@@ -126,7 +126,8 @@
4
5 #ifndef PYTHONPATH
6 #define PYTHONPATH PREFIX "/" LIB_PYTHON VERSION ":" \
7- EXEC_PREFIX "/" LIB_PYTHON VERSION "/lib-dynload:"
8+ EXEC_PREFIX "/" LIB_PYTHON VERSION "/lib-dynload:" \
9+ PREFIX "/share/python" VERSION
10 #endif
11
12 #ifndef LANDMARK
f215c9da
AF
13@@ -138,6 +139,7 @@ static wchar_t exec_prefix[MAXPATHLEN+1]
14 static wchar_t progpath[MAXPATHLEN+1];
15 static wchar_t *module_search_path = NULL;
16 static wchar_t lib_python[] = LIB_PYTHON VERSION;
17+static wchar_t share_python[] = L"share/python" VERSION;
e684db95 18
f215c9da
AF
19 /* In principle, this should use HAVE__WSTAT, and _wstat
20 should be detected by autoconf. However, no current
21@@ -338,7 +340,7 @@ search_for_prefix(wchar_t *argv0_path, w
22 delim = wcschr(prefix, DELIM);
e684db95 23 if (delim)
f215c9da 24 *delim = L'\0';
e684db95
AM
25- joinpath(prefix, lib_python);
26+ joinpath(prefix, share_python);
27 joinpath(prefix, LANDMARK);
28 return 1;
29 }
f215c9da 30@@ -361,7 +363,7 @@ search_for_prefix(wchar_t *argv0_path, w
e684db95
AM
31 copy_absolute(prefix, argv0_path);
32 do {
f215c9da 33 n = wcslen(prefix);
e684db95
AM
34- joinpath(prefix, lib_python);
35+ joinpath(prefix, share_python);
36 joinpath(prefix, LANDMARK);
37 if (ismodule(prefix))
38 return 1;
f215c9da 39@@ -371,7 +373,7 @@ search_for_prefix(wchar_t *argv0_path, w
e684db95
AM
40
41 /* Look at configure's PREFIX */
f215c9da 42 wcsncpy(prefix, L"" PREFIX, MAXPATHLEN);
e684db95
AM
43- joinpath(prefix, lib_python);
44+ joinpath(prefix, share_python);
45 joinpath(prefix, LANDMARK);
46 if (ismodule(prefix))
47 return 1;
f215c9da 48@@ -598,7 +600,7 @@ calculate_path(void)
e684db95
AM
49 fprintf(stderr,
50 "Could not find platform independent libraries <prefix>\n");
f215c9da 51 wcsncpy(prefix, L"" PREFIX, MAXPATHLEN);
e684db95
AM
52- joinpath(prefix, lib_python);
53+ joinpath(prefix, share_python);
54 }
55 else
56 reduce(prefix);
f215c9da 57@@ -611,7 +613,7 @@ calculate_path(void)
e684db95
AM
58 }
59 else
f215c9da
AF
60 wcsncpy(zip_path, L"" PREFIX, MAXPATHLEN);
61- joinpath(zip_path, L"lib/python00.zip");
e684db95 62+ joinpath(zip_path, LIB_PYTHON "00.zip");
f215c9da 63 bufsz = wcslen(zip_path); /* Replace "00" with version */
e684db95
AM
64 zip_path[bufsz - 6] = VERSION[0];
65 zip_path[bufsz - 5] = VERSION[2];
f215c9da
AF
66--- Python-3.0.1/Lib/site.py.wiget 2009-02-25 10:58:09.000000000 +0100
67+++ Python-3.0.1/Lib/site.py 2009-02-25 11:03:48.000000000 +0100
68@@ -262,11 +262,10 @@ def addsitepackages(known_paths):
69 "python" + sys.version[:3],
70 "site-packages"))
71 sitedirs.append(os.path.join(prefix, sys.lib, "site-python"))
72- if sys.lib != 'lib':
73- sitedirs.append(os.path.join(prefix, 'lib',
74- "python" + sys.version[:3],
75- "site-packages"))
76- sitedirs.append(os.path.join(prefix, 'lib', "site-python"))
77+ sitedirs.append(os.path.join(prefix, 'share',
78+ "python" + sys.version[:3],
79+ "site-packages"))
80+ sitedirs.append(os.path.join(prefix, 'share', "site-python"))
81
82 else:
83 sitedirs.append(prefix)
84--- Python-3.0.1/Lib/distutils/sysconfig.py.wiget 2009-02-25 10:58:09.000000000 +0100
85+++ Python-3.0.1/Lib/distutils/sysconfig.py 2009-02-25 10:58:09.000000000 +0100
86@@ -114,12 +114,12 @@ def get_python_lib(plat_specific=0, stan
87 prefix = plat_specific and EXEC_PREFIX or PREFIX
88
89 if os.name == "posix":
90- if plat_specific:
91- lib = sys.lib
92+ if plat_specific:
93+ libpython = os.path.join(prefix,
94+ sys.lib, "python" + get_python_version())
95 else:
96- lib = 'lib'
97- libpython = os.path.join(prefix,
98- lib, "python" + get_python_version())
99+ libpython = os.path.join(prefix,
100+ "share", "python" + get_python_version())
101 if standard_lib:
102 return libpython
103 else:
104--- Python-3.0.1/Lib/distutils/command/install.py.wiget 2009-02-25 10:58:09.000000000 +0100
105+++ Python-3.0.1/Lib/distutils/command/install.py 2009-02-25 10:58:09.000000000 +0100
106@@ -40,14 +40,14 @@ else:
107
108 INSTALL_SCHEMES = {
109 'unix_prefix': {
110- 'purelib': '$base/lib/python$py_version_short/site-packages',
111+ 'purelib': '$base/share/python$py_version_short/site-packages',
112 'platlib': '$platbase/'+libname+'/python$py_version_short/site-packages',
113 'headers': '$base/include/python$py_version_short/$dist_name',
114 'scripts': '$base/bin',
115 'data' : '$base',
116 },
117 'unix_home': {
118- 'purelib': '$base/lib/python',
119+ 'purelib': '$base/share/python',
120 'platlib': '$base/'+libname+'/python',
121 'headers': '$base/include/python/$dist_name',
122 'scripts': '$base/bin',
123--- Python-3.0.1/Makefile.pre.in.wiget 2009-02-25 10:58:09.000000000 +0100
124+++ Python-3.0.1/Makefile.pre.in 2009-02-25 10:58:09.000000000 +0100
125@@ -93,7 +93,7 @@ LIBDIR= $(exec_prefix)/$(LIB)
126 MANDIR= @mandir@
127 INCLUDEDIR= @includedir@
128 CONFINCLUDEDIR= $(exec_prefix)/include
129-SCRIPTDIR= $(prefix)/$(LIB)
130+SCRIPTDIR= $(prefix)/share
131
132 # Detailed destination directories
133 BINLIBDEST= $(LIBDIR)/python$(VERSION)
314cf8f7
AF
134--- Python-3.0.1/Lib/distutils/tests/test_install.py.wig 2009-02-25 11:42:38.000000000 +0100
135+++ Python-3.0.1/Lib/distutils/tests/test_install.py 2009-02-25 11:51:23.000000000 +0100
136@@ -38,7 +38,7 @@ class InstallTestCase(support.TempdirMan
137 expected = os.path.normpath(expected)
138 self.assertEqual(got, expected)
139
140- libdir = os.path.join(destination, "lib", "python")
141+ libdir = os.path.join(destination, "share", "python")
142 platlibdir = os.path.join(destination, sys.lib, "python")
143 check_path(cmd.install_lib, libdir)
144 check_path(cmd.install_platlib, platlibdir)
This page took 0.10079 seconds and 4 git commands to generate.