SCL attempt, not yet working
This commit is contained in:
parent
af8f04adfc
commit
ddfa816cb1
@ -1,5 +1,7 @@
|
||||
--- Python-3.4.0b1/Lib/distutils/command/install.py.lib64 2013-11-24 21:36:54.000000000 +0100
|
||||
+++ Python-3.4.0b1/Lib/distutils/command/install.py 2013-11-27 11:10:43.821150774 +0100
|
||||
diff --git a/Lib/distutils/command/install.py b/Lib/distutils/command/install.py
|
||||
index 456511c..36d31e9 100644
|
||||
--- a/Lib/distutils/command/install.py
|
||||
+++ b/Lib/distutils/command/install.py
|
||||
@@ -45,14 +45,14 @@ else:
|
||||
INSTALL_SCHEMES = {
|
||||
'unix_prefix': {
|
||||
@ -17,9 +19,11 @@
|
||||
'headers': '$base/include/python/$dist_name',
|
||||
'scripts': '$base/bin',
|
||||
'data' : '$base',
|
||||
--- Python-3.4.0b1/Lib/distutils/sysconfig.py.lib64 2013-11-24 21:36:54.000000000 +0100
|
||||
+++ Python-3.4.0b1/Lib/distutils/sysconfig.py 2013-11-27 11:10:43.821150774 +0100
|
||||
@@ -141,8 +141,12 @@
|
||||
diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py
|
||||
index 75537db..e5da51c 100644
|
||||
--- a/Lib/distutils/sysconfig.py
|
||||
+++ b/Lib/distutils/sysconfig.py
|
||||
@@ -141,8 +141,12 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None):
|
||||
prefix = plat_specific and EXEC_PREFIX or PREFIX
|
||||
|
||||
if os.name == "posix":
|
||||
@ -33,9 +37,11 @@
|
||||
if standard_lib:
|
||||
return libpython
|
||||
else:
|
||||
--- Python-3.4.0b1/Lib/site.py.lib64 2013-11-24 21:36:54.000000000 +0100
|
||||
+++ Python-3.4.0b1/Lib/site.py 2013-11-27 11:10:43.822150773 +0100
|
||||
@@ -304,12 +304,16 @@
|
||||
diff --git a/Lib/site.py b/Lib/site.py
|
||||
index 14f4f80..e31e0dd 100644
|
||||
--- a/Lib/site.py
|
||||
+++ b/Lib/site.py
|
||||
@@ -303,11 +303,15 @@ def getsitepackages(prefixes=None):
|
||||
seen.add(prefix)
|
||||
|
||||
if os.sep == '/':
|
||||
@ -45,16 +51,17 @@
|
||||
sitepackages.append(os.path.join(prefix, "lib",
|
||||
"python" + sys.version[:3],
|
||||
"site-packages"))
|
||||
sitepackages.append(os.path.join(prefix, "lib", "site-python"))
|
||||
else:
|
||||
sitepackages.append(prefix)
|
||||
+ sitepackages.append(os.path.join(prefix, "lib64", "site-packages"))
|
||||
sitepackages.append(os.path.join(prefix, "lib", "site-packages"))
|
||||
if sys.platform == "darwin":
|
||||
# for framework builds *only* we add the standard Apple
|
||||
--- Python-3.4.0b1/Lib/sysconfig.py.lib64 2013-11-24 21:36:54.000000000 +0100
|
||||
+++ Python-3.4.0b1/Lib/sysconfig.py 2013-11-27 11:10:43.822150773 +0100
|
||||
@@ -20,10 +20,10 @@
|
||||
diff --git a/Lib/sysconfig.py b/Lib/sysconfig.py
|
||||
index dbf7767..dba45c7 100644
|
||||
--- a/Lib/sysconfig.py
|
||||
+++ b/Lib/sysconfig.py
|
||||
@@ -20,10 +20,10 @@ __all__ = [
|
||||
|
||||
_INSTALL_SCHEMES = {
|
||||
'posix_prefix': {
|
||||
@ -68,7 +75,7 @@
|
||||
'include':
|
||||
'{installed_base}/include/python{py_version_short}{abiflags}',
|
||||
'platinclude':
|
||||
@@ -61,10 +61,10 @@
|
||||
@@ -61,10 +61,10 @@ _INSTALL_SCHEMES = {
|
||||
'data': '{userbase}',
|
||||
},
|
||||
'posix_user': {
|
||||
@ -82,30 +89,37 @@
|
||||
'include': '{userbase}/include/python{py_version_short}',
|
||||
'scripts': '{userbase}/bin',
|
||||
'data': '{userbase}',
|
||||
--- Python-3.4.0b1/Lib/test/test_site.py.lib64 2013-11-24 21:36:55.000000000 +0100
|
||||
+++ Python-3.4.0b1/Lib/test/test_site.py 2013-11-27 11:10:43.822150773 +0100
|
||||
@@ -244,12 +244,15 @@
|
||||
self.assertEqual(dirs[2], wanted)
|
||||
diff --git a/Lib/test/test_site.py b/Lib/test/test_site.py
|
||||
index c2f37f8..a0f6b8d 100644
|
||||
--- a/Lib/test/test_site.py
|
||||
+++ b/Lib/test/test_site.py
|
||||
@@ -244,15 +244,18 @@ class HelperFunctionsTests(unittest.TestCase):
|
||||
elif os.sep == '/':
|
||||
# OS X non-framwework builds, Linux, FreeBSD, etc
|
||||
- self.assertEqual(len(dirs), 2)
|
||||
self.assertEqual(len(dirs), 1)
|
||||
- wanted = os.path.join('xoxo', 'lib', 'python' + sys.version[:3],
|
||||
+ self.assertEqual(len(dirs), 3)
|
||||
+ wanted = os.path.join('xoxo', 'lib64', 'python' + sys.version[:3],
|
||||
'site-packages')
|
||||
self.assertEqual(dirs[0], wanted)
|
||||
- wanted = os.path.join('xoxo', 'lib', 'site-python')
|
||||
else:
|
||||
# other platforms
|
||||
- self.assertEqual(len(dirs), 2)
|
||||
+ self.assertEqual(len(dirs), 3)
|
||||
self.assertEqual(dirs[0], 'xoxo')
|
||||
- wanted = os.path.join('xoxo', 'lib', 'site-packages')
|
||||
+ wanted = os.path.join('xoxo', 'lib', 'python' + sys.version[:3],
|
||||
+ 'site-packages')
|
||||
self.assertEqual(dirs[1], wanted)
|
||||
+ wanted = os.path.join('xoxo', 'lib', 'site-python')
|
||||
+ self.assertEqual(dirs[2], wanted)
|
||||
else:
|
||||
# other platforms
|
||||
self.assertEqual(len(dirs), 2)
|
||||
--- Python-3.4.0b1/Makefile.pre.in.lib64 2013-11-27 11:10:43.814150786 +0100
|
||||
+++ Python-3.4.0b1/Makefile.pre.in 2013-11-27 11:10:43.823150771 +0100
|
||||
@@ -115,7 +115,7 @@
|
||||
|
||||
class PthFile(object):
|
||||
"""Helper class for handling testing of .pth files"""
|
||||
diff --git a/Makefile.pre.in b/Makefile.pre.in
|
||||
index 43bc818..25b1c81 100644
|
||||
--- a/Makefile.pre.in
|
||||
+++ b/Makefile.pre.in
|
||||
@@ -115,7 +115,7 @@ LIBDIR= @libdir@
|
||||
MANDIR= @mandir@
|
||||
INCLUDEDIR= @includedir@
|
||||
CONFINCLUDEDIR= $(exec_prefix)/include
|
||||
@ -114,9 +128,11 @@
|
||||
ABIFLAGS= @ABIFLAGS@
|
||||
|
||||
# Detailed destination directories
|
||||
--- Python-3.4.0b1/Modules/getpath.c.lib64 2013-11-24 21:36:56.000000000 +0100
|
||||
+++ Python-3.4.0b1/Modules/getpath.c 2013-11-27 11:17:33.619449704 +0100
|
||||
@@ -122,8 +122,8 @@
|
||||
diff --git a/Modules/getpath.c b/Modules/getpath.c
|
||||
index f26b8e9..64bb4cf 100644
|
||||
--- a/Modules/getpath.c
|
||||
+++ b/Modules/getpath.c
|
||||
@@ -118,8 +118,8 @@
|
||||
#endif
|
||||
|
||||
#ifndef PYTHONPATH
|
||||
@ -127,7 +143,7 @@
|
||||
#endif
|
||||
|
||||
#ifndef LANDMARK
|
||||
@@ -498,7 +498,7 @@
|
||||
@@ -494,7 +494,7 @@ calculate_path(void)
|
||||
_pythonpath = _Py_char2wchar(PYTHONPATH, NULL);
|
||||
_prefix = _Py_char2wchar(PREFIX, NULL);
|
||||
_exec_prefix = _Py_char2wchar(EXEC_PREFIX, NULL);
|
||||
@ -136,7 +152,7 @@
|
||||
|
||||
if (!_pythonpath || !_prefix || !_exec_prefix || !lib_python) {
|
||||
Py_FatalError(
|
||||
@@ -687,7 +687,7 @@
|
||||
@@ -683,7 +683,7 @@ calculate_path(void)
|
||||
}
|
||||
else
|
||||
wcsncpy(zip_path, _prefix, MAXPATHLEN);
|
||||
@ -145,7 +161,7 @@
|
||||
bufsz = wcslen(zip_path); /* Replace "00" with version */
|
||||
zip_path[bufsz - 6] = VERSION[0];
|
||||
zip_path[bufsz - 5] = VERSION[2];
|
||||
@@ -699,7 +699,7 @@
|
||||
@@ -695,7 +695,7 @@ calculate_path(void)
|
||||
fprintf(stderr,
|
||||
"Could not find platform dependent libraries <exec_prefix>\n");
|
||||
wcsncpy(exec_prefix, _exec_prefix, MAXPATHLEN);
|
||||
@ -154,9 +170,11 @@
|
||||
}
|
||||
/* If we found EXEC_PREFIX do *not* reduce it! (Yet.) */
|
||||
|
||||
--- Python-3.4.0b1/setup.py.lib64 2013-11-24 21:36:56.000000000 +0100
|
||||
+++ Python-3.4.0b1/setup.py 2013-11-27 11:10:43.824150769 +0100
|
||||
@@ -441,7 +441,7 @@
|
||||
diff --git a/setup.py b/setup.py
|
||||
index ef8d0f8..fb24a76 100644
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -455,7 +455,7 @@ class PyBuildExt(build_ext):
|
||||
# directories (i.e. '.' and 'Include') must be first. See issue
|
||||
# 10520.
|
||||
if not cross_compiling:
|
||||
@ -165,7 +183,7 @@
|
||||
add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
|
||||
# only change this for cross builds for 3.3, issues on Mageia
|
||||
if cross_compiling:
|
||||
@@ -718,11 +718,11 @@
|
||||
@@ -732,11 +732,11 @@ class PyBuildExt(build_ext):
|
||||
elif curses_library:
|
||||
readline_libs.append(curses_library)
|
||||
elif self.compiler.find_library_file(lib_dirs +
|
||||
@ -179,7 +197,7 @@
|
||||
extra_link_args=readline_extra_link_args,
|
||||
libraries=readline_libs) )
|
||||
else:
|
||||
@@ -759,8 +759,8 @@
|
||||
@@ -773,8 +773,8 @@ class PyBuildExt(build_ext):
|
||||
if krb5_h:
|
||||
ssl_incs += krb5_h
|
||||
ssl_libs = find_library_file(self.compiler, 'ssl',lib_dirs,
|
||||
|
37
python3.spec
37
python3.spec
@ -2,7 +2,7 @@
|
||||
# Conditionals and other variables controlling the build
|
||||
# ======================================================
|
||||
%{!?scl:%global pkg_name %{name}}
|
||||
%{?scl:%scl_package python}
|
||||
%{?scl:%scl_package python3}
|
||||
# Turn off default SCL bytecompiling.
|
||||
%{?scl:%global _turn_off_bytecompile 1}
|
||||
|
||||
@ -133,7 +133,7 @@
|
||||
Summary: Version 3 of the Python programming language aka Python 3000
|
||||
Name: %{?scl_prefix}python3
|
||||
Version: %{pybasever}.0
|
||||
Release: 0.2.20140625hgb4130b2f7748%{?dist}
|
||||
Release: 0.3.20140626hg3151f6f9df85%{?dist}
|
||||
License: Python
|
||||
Group: Development/Languages
|
||||
|
||||
@ -193,8 +193,8 @@ BuildRequires: xz-devel
|
||||
BuildRequires: zlib-devel
|
||||
|
||||
%if 0%{?with_rewheel}
|
||||
BuildRequires: %{name}-setuptools
|
||||
BuildRequires: %{name}-pip
|
||||
BuildRequires: %{?scl_prefix}%{pkg_name}-setuptools
|
||||
BuildRequires: %{?scl_prefix}%{pkg_name}-pip
|
||||
%endif
|
||||
|
||||
|
||||
@ -202,7 +202,7 @@ BuildRequires: %{name}-pip
|
||||
# Source code and patches
|
||||
# =======================
|
||||
|
||||
Source0: python3-nightly-b4130b2f7748.tar
|
||||
Source0: python3-nightly-3151f6f9df85.tar
|
||||
|
||||
# Avoid having various bogus auto-generated Provides lines for the various
|
||||
# python c modules' SONAMEs:
|
||||
@ -725,10 +725,10 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
||||
URL: http://www.python.org/
|
||||
|
||||
# filter pkgconfig and python(abi) Requires/Provides
|
||||
%{?scl:%filter_from_requires s|python(abi)|%{?scl_prefix}python(abi)|g}
|
||||
%{?scl:%filter_from_provides s|pkgconfig(|%{?scl_prefix}pkgconfig(|g}
|
||||
%{?scl:%filter_from_provides s|/usr/lib.*/python||g}
|
||||
%{?scl:%filter_setup}
|
||||
#%%{?scl:%%filter_from_requires s|python(abi)|%{?scl_prefix}python(abi)|g}
|
||||
#%%{?scl:%%filter_from_provides s|pkgconfig(|%{?scl_prefix}pkgconfig(|g}
|
||||
#%%{?scl:%%filter_from_provides s|/usr/lib.*/python||g}
|
||||
#%%{?scl:%%filter_setup}
|
||||
|
||||
# See notes in bug 532118:
|
||||
Provides: %{?scl_prefix}python(abi) = %{pybasever}
|
||||
@ -737,8 +737,8 @@ Requires: %{?scl_prefix}%{pkg_name}-libs%{?_isa} = %{version}-%{release}
|
||||
%{?scl:Requires: %{scl}-runtime}
|
||||
|
||||
%if 0%{with_rewheel}
|
||||
Requires: %{name}-setuptools
|
||||
Requires: %{name}-pip
|
||||
Requires: %{?scl_prefix}%{pkg_name}-setuptools
|
||||
Requires: %{?scl_prefix}%{pkg_name}-pip
|
||||
%endif
|
||||
|
||||
%description
|
||||
@ -800,7 +800,7 @@ Requires: %{?scl_prefix}%{pkg_name} = %{version}-%{release}
|
||||
Requires: %{?scl_prefix}%{pkg_name}-tools = %{version}-%{release}
|
||||
|
||||
%description test
|
||||
The test modules from the main %{name} package.
|
||||
The test modules from the main %{?scl_prefix}%{pkg_name} package.
|
||||
These are in a separate package to save space, as they are almost never used
|
||||
in production.
|
||||
|
||||
@ -1000,7 +1000,7 @@ sed --in-place \
|
||||
# ======================================================
|
||||
|
||||
%build
|
||||
topdir=$(pwd)
|
||||
export topdir=$(pwd)
|
||||
export CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -fPIC -fwrapv"
|
||||
export CXXFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -fPIC -fwrapv"
|
||||
export CPPFLAGS="`pkg-config --cflags-only-I libffi`"
|
||||
@ -1185,7 +1185,7 @@ InstallPython optimized \
|
||||
|
||||
install -d -m 0755 ${RPM_BUILD_ROOT}%{pylibdir}/site-packages/__pycache__
|
||||
|
||||
mv ${RPM_BUILD_ROOT}%{_bindir}/2to3 ${RPM_BUILD_ROOT}%{_bindir}/%{name}-2to3
|
||||
mv ${RPM_BUILD_ROOT}%{_bindir}/2to3 ${RPM_BUILD_ROOT}%{_bindir}/python3-2to3
|
||||
|
||||
# Development tools
|
||||
install -m755 -d ${RPM_BUILD_ROOT}%{pylibdir}/Tools
|
||||
@ -1425,7 +1425,7 @@ find %{buildroot} -type f -a -name "*.py" -print0 | \
|
||||
xargs -0 %{buildroot}%{_bindir}/python%{pybasever} %{SOURCE8}
|
||||
|
||||
|
||||
topdir=$(pwd)
|
||||
export topdir=$(pwd)
|
||||
CheckPython() {
|
||||
ConfName=$1
|
||||
ConfDir=$(pwd)/build/$ConfName
|
||||
@ -1730,7 +1730,7 @@ rm -fr %{buildroot}
|
||||
%files tools
|
||||
%defattr(-,root,root,755)
|
||||
%{_bindir}/idle3
|
||||
%{_bindir}/%{name}-2to3
|
||||
%{_bindir}/python3-2to3
|
||||
%{_bindir}/2to3-%{pybasever}
|
||||
%{_bindir}/idle%{pybasever}
|
||||
%{pylibdir}/Tools
|
||||
@ -1745,7 +1745,7 @@ rm -fr %{buildroot}
|
||||
%{pylibdir}/__pycache__/turtle*%{bytecode_suffixes}
|
||||
%dir %{pylibdir}/turtledemo
|
||||
%{pylibdir}/turtledemo/*.py
|
||||
#%%{pylibdir}/turtledemo/*.txt
|
||||
%{pylibdir}/turtledemo/*.txt
|
||||
%{pylibdir}/turtledemo/*.cfg
|
||||
%dir %{pylibdir}/turtledemo/__pycache__/
|
||||
%{pylibdir}/turtledemo/__pycache__/*%{bytecode_suffixes}
|
||||
@ -1888,6 +1888,9 @@ rm -fr %{buildroot}
|
||||
# ======================================================
|
||||
|
||||
%changelog
|
||||
* Thu Jun 26 2014 Miro Hrončok <mhroncok@redhat.com> - 3.5.0-0.3.20140626hg3151f6f9df85
|
||||
- Update to hg: 3151f6f9df85
|
||||
|
||||
* Wed Jun 25 2014 Miro Hrončok <mhroncok@redhat.com> - 3.5.0-0.2.20140625hgb4130b2f7748
|
||||
- Update to hg: b4130b2f7748
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user