Changeset 1156 for spec/trunk/SPECS/python.spec
- Timestamp:
- Jun 3, 2017, 10:51:43 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
spec/trunk/SPECS/python.spec
r1118 r1156 1 #define svn_url F:/rd/rpm/python/trunk2 %define svn_url http://svn.netlabs.org/repos/rpm/python/trunk3 %define svn_rev 11174 5 1 %{!?__python_ver:%global __python_ver EMPTY} 6 2 #global __python_ver 2.7 … … 47 43 %global _python_bytecompile_errors_terminate_build 0 48 44 45 # Completely disable python dependency generators as we enforce the right 46 # provides/requires manually. This, in particular, prevents python-libs from 47 # having the python(abi) dependency so that it can be installed anone. 48 %global __python_provides %{nil} 49 %global __python_requires %{nil} 50 51 # Exclude Windows installer stubs from debug info stripping 52 %define _strip_opts --debuginfo -x "wininst-*.exe" 53 49 54 Summary: An interpreted, interactive, object-oriented programming language 50 55 Name: %{python} 51 56 Version: 2.7.6 52 Release: 1 7%{?dist}57 Release: 18%{?dist} 53 58 License: Python 54 59 Group: Development/Languages 60 Requires: %{name}-libs = %{version}-%{release} 55 61 Provides: python-abi = %{pybasever} 56 62 Provides: python(abi) = %{pybasever} 57 63 58 Source: %{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip 59 60 BuildRequires: gcc make subversion zip 64 %scm_source svn http://svn.netlabs.org/repos/rpm/python/trunk 1151 61 65 62 66 %if %{main_python} … … 76 80 %endif 77 81 82 # Because of fread override that fixes freezes when reading big files on JFS 83 Requires: libcx >= 0.5.3 84 78 85 # YD because of libcx 79 86 Requires: db4 > 4.8.30-6 … … 83 90 Conflicts: rpm < 4.13.0-8 84 91 Conflicts: yum-metadata-parser < 1.1.4-6 85 86 # YD unix adds this automatically by parsing elf binaries87 Requires: %{name}-libs = %{version}-%{release}88 92 89 93 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) … … 108 112 %endif 109 113 110 # OS/2 specific111 BuildRequires: mmap urpo-devel112 113 114 URL: http://www.python.org/ 114 115 … … 140 141 Summary: The libraries for python runtime 141 142 Group: Applications/System 142 Requires: %{name} = %{version}-%{release} 143 143 144 # Needed for ctypes, to load libraries, worked around for Live CDs size 144 145 # Requires: binutils … … 152 153 Summary: The libraries and header files needed for Python development 153 154 Group: Development/Libraries 154 Requires: %{python} %{?_isa}= %{version}-%{release}155 Requires: %{python} = %{version}-%{release} 155 156 Requires: python-rpm-macros 156 157 Requires: python2-rpm-macros … … 224 225 225 226 %prep 226 %if %{?svn_rev:%(sh -c 'if test -f "%{_sourcedir}/%{name}-%{version}-r%{svn_rev}.zip" ; then echo 1 ; else echo 0 ; fi')}%{!?svn_rev):0} 227 %setup -q 228 %else 229 %setup -n "%{name}-%{version}" -Tc 230 svn export %{?svn_rev:-r %{svn_rev}} %{svn_url} . --force 231 rm -f "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip" 232 (cd .. && zip -SrX9 "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip" "%{name}-%{version}") 233 %endif 227 %scm_setup 234 228 235 229 %if 0%{?with_systemtap} … … 258 252 %build 259 253 260 export LDFLAGS="-g -Zbin-files -Zhigh-mem -Zomf -Zargs-wild -Zargs-resp" 261 export LIBS="-lcx -lssl -lcrypto -lurpo -lpthread -lintl" 254 # NOTE: Put -lcx to LDFLAGS instead of LIBS to have LIBCx linked to all shared 255 # (.pyd) modules in addition to the python DLL and EXE itself 256 export LDFLAGS="-g -Zbin-files -Zhigh-mem -Zomf -Zargs-wild -Zargs-resp -Zmap -lcx" 257 export LIBS="-lssl -lcrypto -lintl" 262 258 %configure \ 263 259 --enable-shared \ … … 354 350 rm %{buildroot}%{pylibdir}/*.egg-info 355 351 352 # Get rid of all .pyo files as they are identical to .pyc (only needed in 353 # python -O mode which is used rarely or not at all on OS/2) 354 find %{buildroot}%{pylibdir} -type f -name *.pyo -exec rm -f {} + 355 356 356 %clean 357 357 rm -fr %{buildroot} … … 370 370 371 371 372 %files 372 %files -f %{debug_package_exclude_files} 373 373 %defattr(-, root, root, -) 374 374 %doc LICENSE README … … 382 382 %{_bindir}/python%{pybasever}.exe 383 383 %{_mandir}/*/* 384 %exclude %{_bindir}/*.dbg385 384 386 385 %dir %{pylibdir} … … 388 387 %{dynload_dir}/Python-%{version}-py%{pybasever}.egg-info 389 388 %{dynload_dir}/*.pyd 389 %exclude %{dynload_dir}/*.map 390 390 %exclude %{dynload_dir}/_ctypes_test.pyd 391 391 %exclude %{dynload_dir}/_ct3574.pyd … … 438 438 %{_includedir}/python%{pybasever}/%{_pyconfig_h} 439 439 440 %files libs 440 %files libs -f %{debug_package_exclude_files} 441 441 %defattr(-,root,root,-) 442 442 #%doc LICENSE README … … 446 446 %doc systemtap-example.stp pyfuntop.stp 447 447 %endif 448 %exclude %{_libdir}/*.dbg449 448 %{pylibdir}/unittest/* 450 449 … … 517 516 518 517 %changelog 518 * Sat Jun 3 2017 Dmitriy Kuminov <coding@dmik.org> 2.7.6-18 519 - Put the LIBCx library to LDFLAGS rather than LIBS to have all module DLLs 520 linked against it as well. 521 - Rebuild against LIBCx 0.5.3 to incorporate DosRead JFS workaround for fread. 522 - Remove urpo as it conflicts with LIBCx. 523 - Remove pthread from libraries as not needed any more. 524 - Remove .pyo files (needed only in python -O mode which is rarely used). 525 - Remove .dbg files for Windows stubs (wininst-*.exe). 526 - Use scm_source/scm_setup for downloading sources. 527 519 528 * Mon Apr 24 2017 yd <yd@os2power.com> 2.7.6-17 520 529 - add new requirements and move unittest files. ticket#248.
Note:
See TracChangeset
for help on using the changeset viewer.