Magellan Linux

Contents of /trunk/python/patches/python-2.7.0-lib64.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1090 - (show annotations) (download)
Thu Aug 19 11:11:09 2010 UTC (13 years, 8 months ago) by niro
File size: 7782 byte(s)
-re-diffed patches

1 diff -up Python-2.7rc1/Lib/distutils/command/install.py.lib64 Python-2.7rc1/Lib/distutils/command/install.py
2 --- Python-2.7rc1/Lib/distutils/command/install.py.lib64 2010-05-05 15:09:31.000000000 -0400
3 +++ Python-2.7rc1/Lib/distutils/command/install.py 2010-06-05 23:53:24.802224367 -0400
4 @@ -42,14 +42,14 @@ else:
5 INSTALL_SCHEMES = {
6 'unix_prefix': {
7 'purelib': '$base/lib/python$py_version_short/site-packages',
8 - 'platlib': '$platbase/lib/python$py_version_short/site-packages',
9 + 'platlib': '$platbase/lib64/python$py_version_short/site-packages',
10 'headers': '$base/include/python$py_version_short/$dist_name',
11 'scripts': '$base/bin',
12 'data' : '$base',
13 },
14 'unix_home': {
15 'purelib': '$base/lib/python',
16 - 'platlib': '$base/lib/python',
17 + 'platlib': '$base/lib64/python',
18 'headers': '$base/include/python/$dist_name',
19 'scripts': '$base/bin',
20 'data' : '$base',
21 diff -up Python-2.7rc1/Lib/distutils/sysconfig.py.lib64 Python-2.7rc1/Lib/distutils/sysconfig.py
22 --- Python-2.7rc1/Lib/distutils/sysconfig.py.lib64 2010-05-05 15:09:31.000000000 -0400
23 +++ Python-2.7rc1/Lib/distutils/sysconfig.py 2010-06-05 23:53:24.803224186 -0400
24 @@ -114,8 +114,12 @@ def get_python_lib(plat_specific=0, stan
25 prefix = plat_specific and EXEC_PREFIX or PREFIX
26
27 if os.name == "posix":
28 + if plat_specific or standard_lib:
29 + lib = "lib64"
30 + else:
31 + lib = "lib"
32 libpython = os.path.join(prefix,
33 - "lib", "python" + get_python_version())
34 + lib, "python" + get_python_version())
35 if standard_lib:
36 return libpython
37 else:
38 diff -up Python-2.7rc1/Lib/site.py.lib64 Python-2.7rc1/Lib/site.py
39 --- Python-2.7rc1/Lib/site.py.lib64 2010-06-03 17:21:03.000000000 -0400
40 +++ Python-2.7rc1/Lib/site.py 2010-06-06 04:56:41.504986054 -0400
41 @@ -286,12 +286,16 @@ def getsitepackages():
42 if sys.platform in ('os2emx', 'riscos'):
43 sitepackages.append(os.path.join(prefix, "Lib", "site-packages"))
44 elif os.sep == '/':
45 + sitepackages.append(os.path.join(prefix, "lib64",
46 + "python" + sys.version[:3],
47 + "site-packages"))
48 sitepackages.append(os.path.join(prefix, "lib",
49 "python" + sys.version[:3],
50 "site-packages"))
51 sitepackages.append(os.path.join(prefix, "lib", "site-python"))
52 else:
53 sitepackages.append(prefix)
54 + sitepackages.append(os.path.join(prefix, "lib64", "site-packages"))
55 sitepackages.append(os.path.join(prefix, "lib", "site-packages"))
56 if sys.platform == "darwin":
57 # for framework builds *only* we add the standard Apple
58 diff -up Python-2.7rc1/Makefile.pre.in.lib64 Python-2.7rc1/Makefile.pre.in
59 --- Python-2.7rc1/Makefile.pre.in.lib64 2010-06-05 23:53:24.000000000 -0400
60 +++ Python-2.7rc1/Makefile.pre.in 2010-06-06 04:57:25.280017307 -0400
61 @@ -94,7 +94,7 @@ LIBDIR= @libdir@
62 MANDIR= @mandir@
63 INCLUDEDIR= @includedir@
64 CONFINCLUDEDIR= $(exec_prefix)/include
65 -SCRIPTDIR= $(prefix)/lib
66 +SCRIPTDIR= $(prefix)/lib64
67
68 # Detailed destination directories
69 BINLIBDEST= $(LIBDIR)/python$(VERSION)
70 diff -up Python-2.7rc1/Modules/getpath.c.lib64 Python-2.7rc1/Modules/getpath.c
71 --- Python-2.7rc1/Modules/getpath.c.lib64 2010-05-09 10:46:46.000000000 -0400
72 +++ Python-2.7rc1/Modules/getpath.c 2010-06-06 04:58:53.840226352 -0400
73 @@ -117,8 +117,8 @@
74 #endif
75
76 #ifndef PYTHONPATH
77 -#define PYTHONPATH PREFIX "/lib/python" VERSION ":" \
78 - EXEC_PREFIX "/lib/python" VERSION "/lib-dynload"
79 +#define PYTHONPATH PREFIX "/lib64/python" VERSION ":" \
80 + EXEC_PREFIX "/lib64/python" VERSION "/lib-dynload"
81 #endif
82
83 #ifndef LANDMARK
84 @@ -129,7 +129,7 @@ static char prefix[MAXPATHLEN+1];
85 static char exec_prefix[MAXPATHLEN+1];
86 static char progpath[MAXPATHLEN+1];
87 static char *module_search_path = NULL;
88 -static char lib_python[] = "lib/python" VERSION;
89 +static char lib_python[] = "lib64/python" VERSION;
90
91 static void
92 reduce(char *dir)
93 @@ -524,7 +524,7 @@ calculate_path(void)
94 }
95 else
96 strncpy(zip_path, PREFIX, MAXPATHLEN);
97 - joinpath(zip_path, "lib/python00.zip");
98 + joinpath(zip_path, "lib64/python00.zip");
99 bufsz = strlen(zip_path); /* Replace "00" with version */
100 zip_path[bufsz - 6] = VERSION[0];
101 zip_path[bufsz - 5] = VERSION[2];
102 @@ -534,7 +534,7 @@ calculate_path(void)
103 fprintf(stderr,
104 "Could not find platform dependent libraries <exec_prefix>\n");
105 strncpy(exec_prefix, EXEC_PREFIX, MAXPATHLEN);
106 - joinpath(exec_prefix, "lib/lib-dynload");
107 + joinpath(exec_prefix, "lib64/lib-dynload");
108 }
109 /* If we found EXEC_PREFIX do *not* reduce it! (Yet.) */
110
111 diff -up Python-2.7rc1/Modules/Setup.dist.lib64 Python-2.7rc1/Modules/Setup.dist
112 --- Python-2.7rc1/Modules/Setup.dist.lib64 2010-06-05 23:53:24.792224061 -0400
113 +++ Python-2.7rc1/Modules/Setup.dist 2010-06-05 23:53:24.845009526 -0400
114 @@ -413,7 +413,7 @@ gdbm gdbmmodule.c -lgdbm
115 # and the subdirectory of PORT where you built it.
116 DBLIBVER=4.7
117 DBINC=/usr/include/db4
118 -DBLIB=/usr/lib
119 +DBLIB=/usr/lib64
120 _bsddb _bsddb.c -I$(DBINC) -L$(DBLIB) -ldb-$(DBLIBVER)
121
122 # Historical Berkeley DB 1.85
123 @@ -459,7 +459,7 @@ cPickle cPickle.c
124 # Andrew Kuchling's zlib module.
125 # This require zlib 1.1.3 (or later).
126 # See http://www.gzip.org/zlib/
127 -zlib zlibmodule.c -I$(prefix)/include -L$(exec_prefix)/lib -lz
128 +zlib zlibmodule.c -I$(prefix)/include -L$(exec_prefix)/lib64 -lz
129
130 # Interface to the Expat XML parser
131 #
132 diff -up Python-2.7rc1/setup.py.lib64 Python-2.7rc1/setup.py
133 --- Python-2.7rc1/setup.py.lib64 2010-06-04 05:49:20.000000000 -0400
134 +++ Python-2.7rc1/setup.py 2010-06-06 05:00:36.653100371 -0400
135 @@ -347,7 +347,7 @@ class PyBuildExt(build_ext):
136
137 def detect_modules(self):
138 # Ensure that /usr/local is always used
139 - add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
140 + add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib64')
141 add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
142
143 # Add paths specified in the environment variables LDFLAGS and
144 @@ -643,11 +643,11 @@ class PyBuildExt(build_ext):
145 elif curses_library:
146 readline_libs.append(curses_library)
147 elif self.compiler.find_library_file(lib_dirs +
148 - ['/usr/lib/termcap'],
149 + ['/usr/lib64/termcap'],
150 'termcap'):
151 readline_libs.append('termcap')
152 exts.append( Extension('readline', ['readline.c'],
153 - library_dirs=['/usr/lib/termcap'],
154 + library_dirs=['/usr/lib64/termcap'],
155 extra_link_args=readline_extra_link_args,
156 libraries=readline_libs) )
157 else:
158 @@ -681,8 +681,8 @@ class PyBuildExt(build_ext):
159 if krb5_h:
160 ssl_incs += krb5_h
161 ssl_libs = find_library_file(self.compiler, 'ssl',lib_dirs,
162 - ['/usr/local/ssl/lib',
163 - '/usr/contrib/ssl/lib/'
164 + ['/usr/local/ssl/lib64',
165 + '/usr/contrib/ssl/lib64/'
166 ] )
167
168 if (ssl_incs is not None and