# HG changeset patch # User Michael Schloh von Bennewitz # Date 1346171300 -7200 # Node ID 241043c7d6579ee03f25b6979fdbad5f9b4526f9 # Parent e01f13f7c27620da3bc1e7cedfa20eb27c9e2165 Update version, modernize packaging, and slightly correct build configuration. diff -r e01f13f7c276 -r 241043c7d657 python/python.patch --- a/python/python.patch Fri Aug 24 20:52:12 2012 +0200 +++ b/python/python.patch Tue Aug 28 18:28:20 2012 +0200 @@ -1,6 +1,6 @@ Index: configure ---- configure.orig 2010-11-01 02:47:19.000000000 +0100 -+++ configure 2010-12-05 18:07:39.000000000 +0100 +--- configure.orig 2011-06-11 17:46:28.000000000 +0200 ++++ configure 2011-12-11 16:42:17.000000000 +0100 @@ -3920,9 +3920,9 @@ CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then @@ -32,8 +32,8 @@ if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null then Index: setup.py ---- setup.py.orig 2010-10-31 17:40:21.000000000 +0100 -+++ setup.py 2010-12-05 18:05:56.000000000 +0100 +--- setup.py.orig 2011-06-11 17:46:28.000000000 +0200 ++++ setup.py 2011-12-11 16:43:40.000000000 +0100 @@ -369,8 +369,8 @@ def detect_modules(self): @@ -87,4 +87,3 @@ for dir in inc_dirs: tcl_include_sub += [dir + os.sep + "tcl" + dotversion] tk_include_sub += [dir + os.sep + "tk" + dotversion] -Common subdirectories: Python-2.7.2.orig/Tools and Python-2.7.2/Tools diff -r e01f13f7c276 -r 241043c7d657 python/python.spec --- a/python/python.spec Fri Aug 24 20:52:12 2012 +0200 +++ b/python/python.spec Tue Aug 28 18:28:20 2012 +0200 @@ -1,6 +1,6 @@ ## ## python.spec -- OpenPKG RPM Package Specification -## Copyright (c) 2000-2010 OpenPKG Foundation e.V. +## Copyright (c) 2000-2012 OpenPKG Foundation e.V. ## ## Permission to use, copy, modify, and distribute this software for ## any purpose with or without fee is hereby granted, provided that @@ -31,8 +31,8 @@ Class: BASE Group: Language License: GPL -Version: 2.7.2 -Release: 20110914 +Version: 2.7.3 +Release: 20120800 # package options %option with_readline no @@ -50,10 +50,8 @@ Patch0: python.patch # build information -Prefix: %{l_prefix} -BuildRoot: %{l_buildroot} -BuildPreReq: OpenPKG, openpkg >= 20060823, gcc -PreReq: OpenPKG, openpkg >= 20060823, gcc +BuildPreReq: OpenPKG, openpkg >= 20100101, gcc, make +PreReq: OpenPKG, openpkg >= 20100101, gcc BuildPreReq: zlib PreReq: zlib %if "%{with_readline}" == "yes" @@ -92,8 +90,6 @@ BuildPreReq: openssl PreReq: openssl %endif -AutoReq: no -AutoReqProv: no %description Python is an interpreted, interactive, object-oriented programming @@ -115,10 +111,10 @@ %prep %setup -q -n Python-%{version} %patch -p0 - %{l_shtool} subst \ - -e 's;\(LDSHARED=.*\)\$(CC);\1\\$(CC);g' \ - -e 's;\(LDCXXSHARED=.*\)\$(CXX);\1\\$(CXX);g' \ - configure + +%build + %{l_shtool} subst %{l_value -s -a} \ + setup.py %{l_shtool} subst \ -e 's;altinstall bininstall maninstall;altinstall maninstall;' \ -e 's;python$(VERSION);python;g' \ @@ -136,9 +132,6 @@ %{l_shtool} subst \ -e 's;python{py_version_short};python;g' \ Lib/sysconfig.py - -%build - echo "" >config.cache %if "%{with_readline}" == "yes" ( echo "readline readline.c %{l_cppflags} %{l_ldflags} -lreadline -ltermcap" ) >>Modules/Setup.local @@ -180,12 +173,6 @@ ) >>Modules/Setup.local %endif - # getaddrinfo bug - disableipv6="" - case "%{l_platform -t}" in - *-aix* ) disableipv6="--disable-ipv6" ;; - esac - CC="%{l_prefix}/bin/gcc" \ CXX="%{l_cxx}" \ CFLAGS="%{l_cflags -O}" \ @@ -193,9 +180,6 @@ CXXFLAGS="%{l_cxxflags -O}" \ LDFLAGS="%{l_ldflags}" \ ./configure \ - --cache-file=./config.cache \ - --with-gcc \ - $disableipv6 \ --prefix=%{l_prefix} \ --mandir=%{l_prefix}/man \ --with-dbmliborder=ndbm \ @@ -203,7 +187,6 @@ %{l_make} %{l_mflags -O} %install - rm -rf $RPM_BUILD_ROOT %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT ln $RPM_BUILD_ROOT%{l_prefix}/lib/python/config/libpython*.a \ $RPM_BUILD_ROOT%{l_prefix}/lib/python/config/libpython.a @@ -216,5 +199,4 @@ %files -f files %clean - rm -rf $RPM_BUILD_ROOT