summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--python/python3/README24
-rw-r--r--python/python3/patches/python3.pure64.diff32
-rw-r--r--python/python3/patches/python3.x86_64.diff183
-rw-r--r--python/python3/python3.SlackBuild29
-rw-r--r--python/python3/python3.info8
5 files changed, 141 insertions, 135 deletions
diff --git a/python/python3/README b/python/python3/README
index 64880e33b2..e5171230e3 100644
--- a/python/python3/README
+++ b/python/python3/README
@@ -1,13 +1,15 @@
-Python is an interpreted, interactive, object-oriented programming language
-that combines remarkable power with very clear syntax. Python's basic power
-can be extended with your own modules written in C or C++. Python is also
-adaptable as an extension language for existing applications.
+Python is an interpreted, interactive, object-oriented programming
+language that combines remarkable power with very clear syntax.
+Python's basic power can be extended with your own modules written in C
+or C++. Python is also adaptable as an extension language for existing
+applications.
-Python 3 (a.k.a. "Python 3000" or "Py3k") is a new version of the language that
-is incompatible with the 2.x line of releases. The language is mostly the
-same, but many details, especially how built-in objects like dictionaries and
-strings work, have changed considerably, and a lot of deprecated features have
-finally been removed. Also, the standard library has been reorganized in a few
-prominent places.
+Python 3 (a.k.a. "Python 3000" or "Py3k") is a new version of the
+language that is incompatible with the 2.x line of releases. The
+language is mostly the same, but many details, especially how built-in
+objects like dictionaries and strings work, have changed considerably,
+and a lot of deprecated features have finally been removed. Also, the
+standard library has been reorganized in a few prominent places.
-It is safe to install this on a system which already has 2.x version of Python.
+It is safe to install this on a system which already has 2.x version of
+Python.
diff --git a/python/python3/patches/python3.pure64.diff b/python/python3/patches/python3.pure64.diff
deleted file mode 100644
index 915f2e1cf7..0000000000
--- a/python/python3/patches/python3.pure64.diff
+++ /dev/null
@@ -1,32 +0,0 @@
-diff -uar Python-3.1.3.orig/Lib/distutils/command/install.py Python-3.1.3/Lib/distutils/command/install.py
---- Python-3.1.3.orig/Lib/distutils/command/install.py 2010-11-29 22:16:59.433287434 +0200
-+++ Python-3.1.3/Lib/distutils/command/install.py 2010-11-29 22:21:28.544937484 +0200
-@@ -46,14 +46,14 @@
-
- INSTALL_SCHEMES = {
- 'unix_prefix': {
-- 'purelib': '$base/lib/python$py_version_short/site-packages',
-+ 'purelib': '$base/lib64/python$py_version_short/site-packages',
- 'platlib': '$platbase/lib64/python$py_version_short/site-packages',
- 'headers': '$base/include/python$py_version_short/$dist_name',
- 'scripts': '$base/bin',
- 'data' : '$base',
- },
- 'unix_home': {
-- 'purelib': '$base/lib/python',
-+ 'purelib': '$base/lib64/python',
- 'platlib': '$base/lib64/python',
- 'headers': '$base/include/python/$dist_name',
- 'scripts': '$base/bin',
-diff -uar Python-3.1.3.orig/Lib/distutils/sysconfig.py Python-3.1.3/Lib/distutils/sysconfig.py
---- Python-3.1.3.orig/Lib/distutils/sysconfig.py 2010-11-29 22:16:59.434287447 +0200
-+++ Python-3.1.3/Lib/distutils/sysconfig.py 2010-11-29 22:29:32.627720854 +0200
-@@ -120,7 +120,7 @@
- if plat_specific or standard_lib:
- lib = "lib64"
- else:
-- lib = "lib"
-+ lib = "lib64"
- libpython = os.path.join(prefix,
- lib, "python" + get_python_version())
- if standard_lib:
diff --git a/python/python3/patches/python3.x86_64.diff b/python/python3/patches/python3.x86_64.diff
index eb036ec8c2..44cc7797da 100644
--- a/python/python3/patches/python3.x86_64.diff
+++ b/python/python3/patches/python3.x86_64.diff
@@ -1,88 +1,121 @@
-diff -uar Python-3.1.3.orig/Lib/distutils/command/install.py Python-3.1.3/Lib/distutils/command/install.py
---- Python-3.1.3.orig/Lib/distutils/command/install.py 2009-06-04 10:39:50.000000000 +0300
-+++ Python-3.1.3/Lib/distutils/command/install.py 2010-11-29 21:24:50.939437490 +0200
-@@ -47,14 +47,14 @@
+diff -uar Python-3.2.1.orig/Lib/distutils/command/install.py Python-3.2.1/Lib/distutils/command/install.py
+--- Python-3.2.1.orig/Lib/distutils/command/install.py 2011-07-09 09:58:46.000000000 +0300
++++ Python-3.2.1/Lib/distutils/command/install.py 2011-07-11 13:24:36.929183098 +0300
+@@ -46,15 +46,15 @@
+
INSTALL_SCHEMES = {
'unix_prefix': {
- 'purelib': '$base/lib/python$py_version_short/site-packages',
+- 'purelib': '$base/lib/python$py_version_short/site-packages',
- 'platlib': '$platbase/lib/python$py_version_short/site-packages',
++ 'purelib': '$base/lib64/python$py_version_short/site-packages',
+ 'platlib': '$platbase/lib64/python$py_version_short/site-packages',
- 'headers': '$base/include/python$py_version_short/$dist_name',
+ 'headers': '$base/include/python$py_version_short$abiflags/$dist_name',
'scripts': '$base/bin',
'data' : '$base',
},
'unix_home': {
- 'purelib': '$base/lib/python',
+- 'purelib': '$base/lib/python',
- 'platlib': '$base/lib/python',
++ 'purelib': '$base/lib64/python',
+ 'platlib': '$base/lib64/python',
'headers': '$base/include/python/$dist_name',
'scripts': '$base/bin',
'data' : '$base',
-diff -uar Python-3.1.3.orig/Lib/distutils/sysconfig.py Python-3.1.3/Lib/distutils/sysconfig.py
---- Python-3.1.3.orig/Lib/distutils/sysconfig.py 2010-08-04 00:33:04.000000000 +0300
-+++ Python-3.1.3/Lib/distutils/sysconfig.py 2010-11-29 21:36:39.452228520 +0200
-@@ -117,8 +117,12 @@
- prefix = plat_specific and EXEC_PREFIX or PREFIX
+diff -uar Python-3.2.1.orig/Lib/distutils/sysconfig.py Python-3.2.1/Lib/distutils/sysconfig.py
+--- Python-3.2.1.orig/Lib/distutils/sysconfig.py 2011-07-09 09:58:47.000000000 +0300
++++ Python-3.2.1/Lib/distutils/sysconfig.py 2011-07-11 13:24:36.929183098 +0300
+@@ -125,7 +125,7 @@
if os.name == "posix":
-+ if plat_specific or standard_lib:
-+ lib = "lib64"
-+ else:
-+ lib = "lib"
libpython = os.path.join(prefix,
- "lib", "python" + get_python_version())
-+ lib, "python" + get_python_version())
++ "lib64", "python" + get_python_version())
if standard_lib:
return libpython
else:
-diff -uar Python-3.1.3.orig/Lib/site.py Python-3.1.3/Lib/site.py
---- Python-3.1.3.orig/Lib/site.py 2010-10-13 01:56:55.000000000 +0300
-+++ Python-3.1.3/Lib/site.py 2010-11-29 21:38:44.804126610 +0200
-@@ -262,12 +262,16 @@
+diff -uar Python-3.2.1.orig/Lib/site.py Python-3.2.1/Lib/site.py
+--- Python-3.2.1.orig/Lib/site.py 2011-07-09 09:58:49.000000000 +0300
++++ Python-3.2.1/Lib/site.py 2011-07-11 13:24:36.930183090 +0300
+@@ -285,13 +285,13 @@
if sys.platform in ('os2emx', 'riscos'):
- sitedirs.append(os.path.join(prefix, "Lib", "site-packages"))
+ sitepackages.append(os.path.join(prefix, "Lib", "site-packages"))
elif os.sep == '/':
-+ sitedirs.append(os.path.join(prefix, "lib64",
-+ "python" + sys.version[:3],
-+ "site-packages"))
- sitedirs.append(os.path.join(prefix, "lib",
+- sitepackages.append(os.path.join(prefix, "lib",
++ sitepackages.append(os.path.join(prefix, "lib64",
"python" + sys.version[:3],
"site-packages"))
- sitedirs.append(os.path.join(prefix, "lib", "site-python"))
+ sitepackages.append(os.path.join(prefix, "lib", "site-python"))
else:
- sitedirs.append(prefix)
-+ sitedirs.append(os.path.join(prefix, "lib64", "site-packages"))
- sitedirs.append(os.path.join(prefix, "lib", "site-packages"))
-
+ sitepackages.append(prefix)
+- sitepackages.append(os.path.join(prefix, "lib", "site-packages"))
++ sitepackages.append(os.path.join(prefix, "lib64", "site-packages"))
if sys.platform == "darwin":
-diff -uar Python-3.1.3.orig/Makefile.pre.in Python-3.1.3/Makefile.pre.in
---- Python-3.1.3.orig/Makefile.pre.in 2010-10-14 14:35:17.000000000 +0300
-+++ Python-3.1.3/Makefile.pre.in 2010-11-29 21:46:00.887367145 +0200
-@@ -94,7 +94,7 @@
+ # for framework builds *only* we add the standard Apple
+ # locations.
+diff -uar Python-3.2.1.orig/Lib/sysconfig.py Python-3.2.1/Lib/sysconfig.py
+--- Python-3.2.1.orig/Lib/sysconfig.py 2011-07-09 09:58:49.000000000 +0300
++++ Python-3.2.1/Lib/sysconfig.py 2011-07-11 13:24:36.930183090 +0300
+@@ -21,10 +21,10 @@
+
+ _INSTALL_SCHEMES = {
+ 'posix_prefix': {
+- 'stdlib': '{base}/lib/python{py_version_short}',
+- 'platstdlib': '{platbase}/lib/python{py_version_short}',
+- 'purelib': '{base}/lib/python{py_version_short}/site-packages',
+- 'platlib': '{platbase}/lib/python{py_version_short}/site-packages',
++ 'stdlib': '{base}/lib64/python{py_version_short}',
++ 'platstdlib': '{platbase}/lib64/python{py_version_short}',
++ 'purelib': '{base}/lib64/python{py_version_short}/site-packages',
++ 'platlib': '{platbase}/lib64/python{py_version_short}/site-packages',
+ 'include':
+ '{base}/include/python{py_version_short}{abiflags}',
+ 'platinclude':
+@@ -33,10 +33,10 @@
+ 'data': '{base}',
+ },
+ 'posix_home': {
+- 'stdlib': '{base}/lib/python',
+- 'platstdlib': '{base}/lib/python',
+- 'purelib': '{base}/lib/python',
+- 'platlib': '{base}/lib/python',
++ 'stdlib': '{base}/lib64/python',
++ 'platstdlib': '{base}/lib64/python',
++ 'purelib': '{base}/lib64/python',
++ 'platlib': '{base}/lib64/python',
+ 'include': '{base}/include/python',
+ 'platinclude': '{base}/include/python',
+ 'scripts': '{base}/bin',
+@@ -81,10 +81,10 @@
+ 'data' : '{userbase}',
+ },
+ 'posix_user': {
+- 'stdlib': '{userbase}/lib/python{py_version_short}',
+- 'platstdlib': '{userbase}/lib/python{py_version_short}',
+- 'purelib': '{userbase}/lib/python{py_version_short}/site-packages',
+- 'platlib': '{userbase}/lib/python{py_version_short}/site-packages',
++ 'stdlib': '{userbase}/lib64/python{py_version_short}',
++ 'platstdlib': '{userbase}/lib64/python{py_version_short}',
++ 'purelib': '{userbase}/lib64/python{py_version_short}/site-packages',
++ 'platlib': '{userbase}/lib64/python{py_version_short}/site-packages',
+ 'include': '{userbase}/include/python{py_version_short}',
+ 'scripts': '{userbase}/bin',
+ 'data' : '{userbase}',
+diff -uar Python-3.2.1.orig/Makefile.pre.in Python-3.2.1/Makefile.pre.in
+--- Python-3.2.1.orig/Makefile.pre.in 2011-07-09 09:58:52.000000000 +0300
++++ Python-3.2.1/Makefile.pre.in 2011-07-11 13:24:36.931183082 +0300
+@@ -106,7 +106,7 @@
MANDIR= @mandir@
INCLUDEDIR= @includedir@
CONFINCLUDEDIR= $(exec_prefix)/include
-SCRIPTDIR= $(prefix)/lib
+SCRIPTDIR= $(prefix)/lib64
+ ABIFLAGS= @ABIFLAGS@
# Detailed destination directories
- BINLIBDEST= $(LIBDIR)/python$(VERSION)
-diff -uar Python-3.1.3.orig/Modules/Setup.dist Python-3.1.3/Modules/Setup.dist
---- Python-3.1.3.orig/Modules/Setup.dist 2009-06-04 12:30:30.000000000 +0300
-+++ Python-3.1.3/Modules/Setup.dist 2010-11-29 21:47:10.734770412 +0200
-@@ -351,7 +351,7 @@
- # Andrew Kuchling's zlib module.
- # This require zlib 1.1.3 (or later).
- # See http://www.gzip.org/zlib/
--#zlib zlibmodule.c -I$(prefix)/include -L$(exec_prefix)/lib -lz
-+#zlib zlibmodule.c -I$(prefix)/include -L$(exec_prefix)/lib64 -lz
-
- # Interface to the Expat XML parser
- #
-diff -uar Python-3.1.3.orig/Modules/getpath.c Python-3.1.3/Modules/getpath.c
---- Python-3.1.3.orig/Modules/getpath.c 2010-10-08 02:39:04.000000000 +0300
-+++ Python-3.1.3/Modules/getpath.c 2010-11-29 22:03:08.820526757 +0200
-@@ -119,8 +119,8 @@
+diff -uar Python-3.2.1.orig/Modules/getpath.c Python-3.2.1/Modules/getpath.c
+--- Python-3.2.1.orig/Modules/getpath.c 2011-07-09 09:58:54.000000000 +0300
++++ Python-3.2.1/Modules/getpath.c 2011-07-11 13:24:36.931183082 +0300
+@@ -122,8 +122,8 @@
#endif
#ifndef PYTHONPATH
@@ -93,52 +126,52 @@ diff -uar Python-3.1.3.orig/Modules/getpath.c Python-3.1.3/Modules/getpath.c
#endif
#ifndef LANDMARK
-@@ -131,7 +131,7 @@
- static wchar_t exec_prefix[MAXPATHLEN+1];
+@@ -135,7 +135,7 @@
static wchar_t progpath[MAXPATHLEN+1];
static wchar_t *module_search_path = NULL;
--static wchar_t lib_python[] = L"lib/python" VERSION;
-+static wchar_t lib_python[] = L"lib64/python" VERSION;
+ static int module_search_path_malloced = 0;
+-static wchar_t *lib_python = L"lib/python" VERSION;
++static wchar_t *lib_python = L"lib64/python" VERSION;
- /* In principle, this should use HAVE__WSTAT, and _wstat
- should be detected by autoconf. However, no current
-@@ -612,7 +612,7 @@
+ static void
+ reduce(wchar_t *dir)
+@@ -583,7 +583,7 @@
}
else
- wcsncpy(zip_path, L"" PREFIX, MAXPATHLEN);
+ wcsncpy(zip_path, _prefix, MAXPATHLEN);
- joinpath(zip_path, L"lib/python00.zip");
+ joinpath(zip_path, L"lib64/python00.zip");
bufsz = wcslen(zip_path); /* Replace "00" with version */
zip_path[bufsz - 6] = VERSION[0];
zip_path[bufsz - 5] = VERSION[2];
-@@ -622,7 +622,7 @@
+@@ -593,7 +593,7 @@
fprintf(stderr,
"Could not find platform dependent libraries <exec_prefix>\n");
- wcsncpy(exec_prefix, L"" EXEC_PREFIX, MAXPATHLEN);
+ wcsncpy(exec_prefix, _exec_prefix, MAXPATHLEN);
- joinpath(exec_prefix, L"lib/lib-dynload");
+ joinpath(exec_prefix, L"lib64/lib-dynload");
}
/* If we found EXEC_PREFIX do *not* reduce it! (Yet.) */
-diff -uar Python-3.1.3.orig/setup.py Python-3.1.3/setup.py
---- Python-3.1.3.orig/setup.py 2010-11-26 13:56:26.000000000 +0200
-+++ Python-3.1.3/setup.py 2010-11-29 22:06:52.939575911 +0200
-@@ -341,7 +341,7 @@
-
- def detect_modules(self):
- # Ensure that /usr/local is always used
+diff -uar Python-3.2.1.orig/setup.py Python-3.2.1/setup.py
+--- Python-3.2.1.orig/setup.py 2011-07-09 09:58:56.000000000 +0300
++++ Python-3.2.1/setup.py 2011-07-11 13:24:36.932183074 +0300
+@@ -396,7 +396,7 @@
+ # Ensure that /usr/local is always used, but the local build
+ # directories (i.e. '.' and 'Include') must be first. See issue
+ # 10520.
- add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
+ add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib64')
add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
+ self.add_multiarch_paths()
- # Add paths specified in the environment variables LDFLAGS and
-@@ -610,11 +610,11 @@
+@@ -643,11 +643,11 @@
elif curses_library:
readline_libs.append(curses_library)
elif self.compiler.find_library_file(lib_dirs +
-- ['/usr/lib/termcap'],
-+ ['/usr/lib64/termcap'],
- 'termcap'):
+- ['/usr/lib/termcap'],
++ ['/usr/lib64/termcap'],
+ 'termcap'):
readline_libs.append('termcap')
exts.append( Extension('readline', ['readline.c'],
- library_dirs=['/usr/lib/termcap'],
@@ -146,7 +179,7 @@ diff -uar Python-3.1.3.orig/setup.py Python-3.1.3/setup.py
extra_link_args=readline_extra_link_args,
libraries=readline_libs) )
else:
-@@ -651,8 +651,8 @@
+@@ -684,8 +684,8 @@
if krb5_h:
ssl_incs += krb5_h
ssl_libs = find_library_file(self.compiler, 'ssl',lib_dirs,
diff --git a/python/python3/python3.SlackBuild b/python/python3/python3.SlackBuild
index 253bef21aa..b6dbd02e53 100644
--- a/python/python3/python3.SlackBuild
+++ b/python/python3/python3.SlackBuild
@@ -5,7 +5,7 @@
# Based on Patrick Volkerding's official build script for python
PRGNAM=python3
-VERSION=${VERSION:-3.1.3}
+VERSION=${VERSION:-3.2.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -37,15 +37,15 @@ fi
set -eu
# Location for Python site-packages:
-SITEPK=$PKG/usr/lib${LIBDIRSUFFIX}/python3.1/site-packages
+SITEPK=$PKG/usr/lib${LIBDIRSUFFIX}/python3.2/site-packages
# same as above without $PKG
-TOOLSDIR=/usr/lib${LIBDIRSUFFIX}/python3.1/site-packages
+TOOLSDIR=/usr/lib${LIBDIRSUFFIX}/python3.2/site-packages
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf Python-$VERSION
-tar xvf $CWD/Python-$VERSION.tar.bz2
+tar xvf $CWD/Python-$VERSION.tar.xz
cd Python-$VERSION
patch -p1 < $CWD/patches/python3.readline.set_pre_input_hook.diff
@@ -53,8 +53,6 @@ patch -p1 < $CWD/patches/python3.readline.set_pre_input_hook.diff
if [ "$ARCH" = "x86_64" ]; then
# Install to lib64 instead of lib:
patch -p1 < $CWD/patches/python3.x86_64.diff
- # Python must report /usr/lib64/python3.1/site-packages as python_lib_dir:
- patch -p1 < $CWD/patches/python3.pure64.diff
fi
chown -R root:root .
@@ -65,7 +63,6 @@ chmod -R u+w,go+r-w,a-s+X .
--libdir=/usr/lib${LIBDIRSUFFIX} \
--mandir=/usr/man \
--docdir=/usr/doc/$PRGNAM-$VERSION \
- --with-ncurses \
--with-threads \
--enable-ipv6 \
--enable-shared \
@@ -75,21 +72,25 @@ chmod -R u+w,go+r-w,a-s+X .
make
make altinstall DESTDIR=$PKG
-# Create a symlink for convenience.
-( cd $PKG/usr/bin ; ln -sf python3.1 python3 )
+# Create a few useful symlinks.
+( cd $PKG/usr/bin
+ ln -sf python3.2 python3
+ ln -sf python3.2*-config python3.2-config
+ ln -sf pydoc3.2 pydoc3
+)
# We'll install the python-tools under site-packages:
mkdir -p $SITEPK
cp -a Tools/* $SITEPK
-# Python 2.6 already has this script.
-rm -f $PKG/usr/bin/2to3
-
-# Install docs and demos:
+# Install docs:
mkdir -p $PKG/usr/doc/python3-$VERSION
-cp -a README LICENSE Demo Doc Misc $PKG/usr/doc/python3-$VERSION
+cp -a README LICENSE Misc $PKG/usr/doc/python3-$VERSION
mv $SITEPK/README $PKG/usr/doc/python3-$VERSION/README.python-tools
( cd $PKG/usr/doc/python3-$VERSION ; ln -sf $TOOLSDIR Tools )
+tar xf $CWD/python-$VERSION-docs-html.tar.bz2
+mv python-$VERSION-docs-html $PKG/usr/doc/python3-$VERSION/html
+chown -R root:root $PKG/usr/doc/python3-$VERSION
find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
diff --git a/python/python3/python3.info b/python/python3/python3.info
index 4bb3fb83ec..be6ede18db 100644
--- a/python/python3/python3.info
+++ b/python/python3/python3.info
@@ -1,8 +1,10 @@
PRGNAM="python3"
-VERSION="3.1.3"
+VERSION="3.2.1"
HOMEPAGE="http://python.org/"
-DOWNLOAD="http://python.org/ftp/python/3.1.3/Python-3.1.3.tar.bz2"
-MD5SUM="ad5e5f1c07e829321e0a015f8cafe245"
+DOWNLOAD="http://python.org/ftp/python/3.2.1/Python-3.2.1.tar.xz \
+ http://python.org/ftp/python/doc/3.2.1/python-3.2.1-docs-html.tar.bz2"
+MD5SUM="2cf014296afc18897daa7b79414ad773 \
+ 1d6c21614e6957040b9fe6cd93af13f2"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
MAINTAINER="Audrius Kažukauskas"