diff -dur Python-3.5.0.orig/Lib/site.py Python-3.5.0/Lib/site.py
--- Python-3.5.0.orig/Lib/site.py 2015-09-13 13:41:21.000000000 +0200
+++ Python-3.5.0/Lib/site.py 2015-12-03 17:31:03.874280444 +0100
-@@ -304,12 +304,14 @@ def getsitepackages(prefixes=None):
+@@ -334,12 +334,14 @@ def getsitepackages(prefixes=None):
seen.add(prefix)
if os.sep == '/':
sitepackages.append(prefix)
- sitepackages.append(os.path.join(prefix, "lib", "site-packages"))
+ sitepackages.append(os.path.join(prefix, sys.lib, "site-packages"))
- if sys.platform == "darwin":
- # for framework builds *only* we add the standard Apple
- # locations.
+ return sitepackages
+
+ def addsitepackages(known_paths, prefixes=None):
diff -dur Python-3.5.0.orig/Lib/sysconfig.py Python-3.5.0/Lib/sysconfig.py
--- Python-3.5.0.orig/Lib/sysconfig.py 2015-09-13 13:41:21.000000000 +0200
+++ Python-3.5.0/Lib/sysconfig.py 2015-12-03 17:31:51.974741432 +0100
Python/importdl.o: $(srcdir)/Python/importdl.c
$(CC) -c $(PY_CORE_CFLAGS) -I$(DLINCLDIR) -o $@ $(srcdir)/Python/importdl.c
-@@ -1362,8 +1364,8 @@
+@@ -1470,9 +1470,9 @@ libainstall: @DEF_MAKE_RULE@ python-conf
+ @if test -d $(LIBRARY); then :; else \
+ if test "$(PYTHONFRAMEWORKDIR)" = no-framework; then \
if test "$(SHLIB_SUFFIX)" = .dll; then \
- $(INSTALL_DATA) $(LDLIBRARY) $(DESTDIR)$(LIBPL) ; \
+- $(INSTALL_DATA) $(LDLIBRARY) $(DESTDIR)$(LIBPL) ; \
++ $(INSTALL_DATA) $(LDLIBRARY) $(DESTDIR)$(LIBDIR) ; \
else \
- $(INSTALL_DATA) $(LIBRARY) $(DESTDIR)$(LIBPL)/$(LIBRARY) ; \
-- $(RANLIB) $(DESTDIR)$(LIBPL)/$(LIBRARY) ; \
+ $(INSTALL_DATA) $(LIBRARY) $(DESTDIR)$(LIBDIR)/$(LIBRARY) ; \
-+ $(RANLIB) $(DESTDIR)$(LIBDIR)/$(LIBRARY) ; \
fi; \
else \
echo Skip install of $(LIBRARY) - use make frameworkinstall; \
#if !defined(PREFIX) || !defined(EXEC_PREFIX) || !defined(VERSION) || !defined(VPATH)
#error "PREFIX, EXEC_PREFIX, VERSION, and VPATH must be constant defined"
-@@ -511,7 +523,7 @@
- _pythonpath = Py_DecodeLocale(PYTHONPATH, NULL);
- _prefix = Py_DecodeLocale(PREFIX, NULL);
- _exec_prefix = Py_DecodeLocale(EXEC_PREFIX, NULL);
-- lib_python = Py_DecodeLocale("lib/python" VERSION, NULL);
-+ lib_python = Py_DecodeLocale(LIB_PYTHON VERSION, NULL);
+@@ -753,7 +753,7 @@ calculate_zip_path(PyCalculatePath *calc
+ else {
+ wcsncpy(calculate->zip_path, calculate->prefix, MAXPATHLEN);
+ }
+- joinpath(calculate->zip_path, L"lib/python00.zip");
++ joinpath(calculate->zip_path, L"" LIB_PYTHON "00.zip");
- if (!_pythonpath || !_prefix || !_exec_prefix || !lib_python) {
- Py_FatalError(
-@@ -700,7 +712,7 @@
+ /* Replace "00" with version */
+ size_t bufsz = wcslen(calculate->zip_path);
+@@ -878,7 +878,7 @@ calculate_init(PyCalculatePath *calculat
+ if (!calculate->prefix) {
+ return DECODE_LOCALE_ERR("EXEC_PREFIX define", len);
+ }
+- calculate->lib_python = Py_DecodeLocale("lib/python" VERSION, &len);
++ calculate->lib_python = Py_DecodeLocale(LIB_PYTHON VERSION, &len);
+ if (!calculate->lib_python) {
+ return DECODE_LOCALE_ERR("EXEC_PREFIX define", len);
}
- else
- wcsncpy(zip_path, _prefix, MAXPATHLEN);
-- joinpath(zip_path, L"lib/python00.zip");
-+ joinpath(zip_path, L"" LIB_PYTHON "00.zip");
- bufsz = wcslen(zip_path); /* Replace "00" with version */
- zip_path[bufsz - 6] = VERSION[0];
- zip_path[bufsz - 5] = VERSION[2];
diff -dur Python-3.5.0.orig/Python/getplatform.c Python-3.5.0/Python/getplatform.c
--- Python-3.5.0.orig/Python/getplatform.c 2015-09-13 13:41:26.000000000 +0200
+++ Python-3.5.0/Python/getplatform.c 2015-12-03 17:31:03.874280444 +0100
diff -dur Python-3.5.0.orig/Python/sysmodule.c Python-3.5.0/Python/sysmodule.c
--- Python-3.5.0.orig/Python/sysmodule.c 2015-09-13 13:41:26.000000000 +0200
+++ Python-3.5.0/Python/sysmodule.c 2015-12-03 17:31:03.874280444 +0100
-@@ -1767,6 +1767,10 @@
+@@ -2307,6 +2307,10 @@ _PySys_BeginInit(PyObject **sysmod)
PyUnicode_FromString(Py_GetCopyright()));
SET_SYS_FROM_STRING("platform",
PyUnicode_FromString(Py_GetPlatform()));
+ PyUnicode_FromString(Py_GetArch()));
+ SET_SYS_FROM_STRING("lib",
+ PyUnicode_FromString(Py_GetLib()));
- SET_SYS_FROM_STRING("executable",
- PyUnicode_FromWideChar(
- Py_GetProgramFullPath(), -1));
+ SET_SYS_FROM_STRING("maxsize",
+ PyLong_FromSsize_t(PY_SSIZE_T_MAX));
+ SET_SYS_FROM_STRING("float_info",
diff -dur Python-3.5.0.orig/configure.ac Python-3.5.0/configure.ac
--- Python-3.5.0.orig/configure.ac 2015-12-03 17:30:32.777292009 +0100
+++ Python-3.5.0/configure.ac 2015-12-03 17:31:03.877613811 +0100
# intentionally NOT "/usr/bin/env python". On many systems
# (e.g. Solaris), /usr/local/bin is not in $PATH as passed to CGI
# scripts, and /usr/local/bin is the default directory where Python is
---- Python-3.0.1/Tools/pybench/pybench.py.wiget 2009-02-07 18:28:46.000000000 +0100
-+++ Python-3.0.1/Tools/pybench/pybench.py 2009-03-14 18:12:32.000000000 +0100
-@@ -1,4 +1,4 @@
--#!/usr/local/bin/python -O
-+#!/usr/bin/python3 -O
-
- """ A Python Benchmark Suite
-
---- Python-3.0.1/Tools/scripts/fixps.py.wiget 2007-08-03 19:06:41.000000000 +0200
-+++ Python-3.0.1/Tools/scripts/fixps.py 2009-03-14 18:12:32.000000000 +0100
-@@ -15,13 +15,13 @@ def main():
- print(filename, ': can\'t open :', msg)
- continue
- line = f.readline()
-- if not re.match('^#! */usr/local/bin/python', line):
-- print(filename, ': not a /usr/local/bin/python script')
-+ if not re.match('^#! */usr/bin/python3', line):
-+ print(filename, ': not a /usr/bin/python3 script')
- f.close()
- continue
- rest = f.read()
- f.close()
-- line = re.sub('/usr/local/bin/python',
-+ line = re.sub('/usr/bin/python3',
- '/usr/bin/env python', line)
- print(filename, ':', repr(line))
- f = open(filename, "w")
+
%endif
%define broken_tests test_nntplib test_gdb test_site test_ssl %{?broken_tests_x32}
-%define py_ver 3.6
+%define py_ver 3.7
%define py_abi %{py_ver}m
%define py_platform %{py_abi}-%{_target_base_arch}-%{_target_os}%{?_gnu}
%define py_prefix %{_prefix}
Summary(tr.UTF-8): X arayüzlü, yüksek düzeyli, kabuk yorumlayıcı dili
Summary(uk.UTF-8): Мова програмування дуже високого рівня з X-інтерфейсом
Name: python3
-Version: %{py_ver}.5
-Release: 3
+Version: %{py_ver}.0
+Release: 0.1
Epoch: 1
License: PSF
Group: Development/Languages/Python
Source0: https://www.python.org/ftp/python/%{version}/Python-%{version}.tar.xz
-# Source0-md5: 9f49654a4d6f733ff3284ab9d227e9fd
+# Source0-md5: eb8c2a6b1447d50813c02714af4681f3
Source1: pyconfig.h.in
Patch0: %{name}-pythonpath.patch
Patch1: %{name}-ac_fixes.patch
%patch11 -p1
%patch12 -p1
-%{__rm} -r Modules/zlib
%{__rm} -r Modules/expat
-for SUBDIR in darwin libffi libffi_msvc libffi_osx; do
+for SUBDIR in darwin libffi_msvc libffi_osx; do
%{__rm} -r Modules/_ctypes/$SUBDIR/*
done
--with-dbmliborder=gdbm:ndbm:bdb \
--with-doc-strings \
--without-ensurepip \
- --with-fpectl \
%{?with_debug:--with-pydebug} \
--with-system-expat \
--with-system-ffi \
- %{?with_system_mpdecimal:--with-system-libmpdec} \
- --with-threads
+ %{?with_system_mpdecimal:--with-system-libmpdec}
%{__make} 2>&1 | awk '
BEGIN { fail = 0; logmsg = ""; }