Tue, 22 Mar 2011 19:46:20 +0100
Backport RPM boilerplate logic for legacy OpenPKG and update versions.
python-db/python-db.patch | file | annotate | diff | comparison | revisions | |
python-db/python-db.spec | file | annotate | diff | comparison | revisions |
1.1 --- a/python-db/python-db.patch Tue Mar 22 19:33:14 2011 +0100 1.2 +++ b/python-db/python-db.patch Tue Mar 22 19:46:20 2011 +0100 1.3 @@ -1,7 +1,8 @@ 1.4 -Index: psycopg2-2.0.14/psycopg/config.h 1.5 ---- psycopg2-2.0.14/psycopg/config.h.orig 2009-04-26 14:09:21 +0200 1.6 -+++ psycopg2-2.0.14/psycopg/config.h 2009-10-08 22:31:01 +0200 1.7 -@@ -140,10 +140,11 @@ 1.8 +Index: psycopg2-2.4/psycopg/config.h 1.9 +diff -Nau psycopg2-2.4psycopg/config.h.orig/ psycopg2-2.4/psycopg/config.h 1.10 +--- psycopg2-2.4/psycopg/config.h.orig 2011-02-27 12:44:55.000000000 +0100 1.11 ++++ psycopg2-2.4/psycopg/config.h 2011-03-22 19:19:11.648184363 +0100 1.12 +@@ -141,10 +141,11 @@ 1.13 1.14 #if (defined(__FreeBSD__) && __FreeBSD_version < 503000) || (defined(_WIN32) && !defined(__GNUC__)) || defined(__sun__) || defined(sun) 1.15 /* what's this, we have no round function either? */ 1.16 @@ -14,10 +15,11 @@ 1.17 #endif 1.18 1.19 /* postgresql < 7.4 does not have PQfreemem */ 1.20 -Index: psycopg2-2.0.14/setup.py 1.21 ---- psycopg2-2.0.14/setup.py.orig 2009-10-04 23:37:14 +0200 1.22 -+++ psycopg2-2.0.14/setup.py 2009-10-08 23:15:48 +0200 1.23 -@@ -203,6 +203,9 @@ 1.24 +Index: psycopg2-2.4/setup.py 1.25 +diff -Nau psycopg2-2.4/setup.py.orig/ psycopg2-2.4/setup.py 1.26 +--- psycopg2-2.4/setup.py.orig 2011-02-27 12:46:47.000000000 +0100 1.27 ++++ psycopg2-2.4/setup.py 2011-03-22 19:36:51.906859031 +0100 1.28 +@@ -269,6 +269,9 @@ 1.29 os.path.join(self.get_pg_config("libdir"), "libpq.a")) 1.30 else: 1.31 self.libraries.append("pq")
2.1 --- a/python-db/python-db.spec Tue Mar 22 19:33:14 2011 +0100 2.2 +++ b/python-db/python-db.spec Tue Mar 22 19:46:20 2011 +0100 2.3 @@ -21,16 +21,14 @@ 2.4 ## SUCH DAMAGE. 2.5 ## 2.6 2.7 -# FIXME: rse: Oracle module was blindly packaged 2.8 - 2.9 # package version 2.10 -%define V_python 2.5 2.11 -%define V_pysqlite_major 2.4 2.12 -%define V_pysqlite 2.4.1 2.13 -%define V_psycopg2 2.0.14 2.14 -%define V_mysql_python 1.2.3c1 2.15 -%define V_cx_oracle 5.0.3 2.16 -%define V_sqlobject 0.12.4 2.17 +%define V_python 2.7 2.18 +%define V_pysqlite 2.6.3 2.19 +%define V_psycopg2 2.4 2.20 +%define V_psycopg_maj 2-4 2.21 +%define V_mysql_python 1.2.3 2.22 +%define V_cx_oracle 5.1 2.23 +%define V_sqlobject 0.15.1 2.24 2.25 # package information 2.26 Name: python-db 2.27 @@ -43,7 +41,7 @@ 2.28 Group: Language 2.29 License: GPL 2.30 Version: %{V_python} 2.31 -Release: 20100506 2.32 +Release: 20110322 2.33 2.34 # package options 2.35 %option with_sqlite yes 2.36 @@ -52,16 +50,18 @@ 2.37 %option with_oracle no 2.38 2.39 # list of sources 2.40 -Source0: http://initd.org/pub/software/pysqlite/releases/%{V_pysqlite_major}/%{V_pysqlite}/pysqlite-%{V_pysqlite}.tar.gz 2.41 -Source1: http://initd.org/pub/software/psycopg/psycopg2-%{V_psycopg2}.tar.gz 2.42 +Source0: http://pysqlite.googlecode.com/files/pysqlite-%{V_pysqlite}.tar.gz 2.43 +Source1: http://www.psycopg.org/psycopg/tarballs/PSYCOPG-%{V_psycopg_maj}/psycopg2-%{V_psycopg2}.tar.gz 2.44 Source2: http://switch.dl.sourceforge.net/mysql-python/MySQL-python-%{V_mysql_python}.tar.gz 2.45 Source3: http://switch.dl.sourceforge.net/cx-oracle/cx_Oracle-%{V_cx_oracle}.tar.gz 2.46 Source4: http://pypi.python.org/packages/source/S/SQLObject/SQLObject-%{V_sqlobject}.tar.gz 2.47 Patch0: python-db.patch 2.48 2.49 # build information 2.50 -BuildPreReq: OpenPKG, openpkg >= 20100101, python >= %{V_python} 2.51 -PreReq: OpenPKG, openpkg >= 20100101, python >= %{V_python} 2.52 +Prefix: %{l_prefix} 2.53 +BuildRoot: %{l_buildroot} 2.54 +BuildPreReq: OpenPKG, openpkg >= 20060823, python >= %{V_python} 2.55 +PreReq: OpenPKG, openpkg >= 20060823, python >= %{V_python} 2.56 BuildPreReq: python-setup 2.57 %if "%{with_sqlite}" == "yes" 2.58 BuildPreReq: sqlite 2.59 @@ -79,6 +79,8 @@ 2.60 BuildPreReq: oracle 2.61 PreReq: oracle 2.62 %endif 2.63 +AutoReq: no 2.64 +AutoReqProv: no 2.65 2.66 %description 2.67 This packages provides Python DB-API 2.0 compliant bindings to 2.68 @@ -159,6 +161,7 @@ 2.69 ) || exit $? 2.70 2.71 %install 2.72 + rm -rf $RPM_BUILD_ROOT 2.73 %{l_shtool} mkdir -f -p -m 755 \ 2.74 $RPM_BUILD_ROOT%{l_prefix} 2.75 %if "%{with_sqlite}" == "yes" 2.76 @@ -207,4 +210,5 @@ 2.77 %files -f files 2.78 2.79 %clean 2.80 + rm -rf $RPM_BUILD_ROOT 2.81