diff options
author | Alex Alexander <wired@gentoo.org> | 2010-12-05 19:35:43 +0000 |
---|---|---|
committer | Alex Alexander <wired@gentoo.org> | 2010-12-05 19:35:43 +0000 |
commit | 1d97cda0d053e4629ff3a0f0aa84ceed0249e2e5 (patch) | |
tree | e76b14733ec9a1e0affd0353be84af488e14beae /x11-libs | |
parent | Remove USE=hppa mask (bug #347827). (diff) | |
download | gentoo-2-1d97cda0d053e4629ff3a0f0aa84ceed0249e2e5.tar.gz gentoo-2-1d97cda0d053e4629ff3a0f0aa84ceed0249e2e5.tar.bz2 gentoo-2-1d97cda0d053e4629ff3a0f0aa84ceed0249e2e5.zip |
added patch for postgres 9, bug #346099
(Portage version: 2.2.0_alpha6/cvs/Linux x86_64)
Diffstat (limited to 'x11-libs')
-rw-r--r-- | x11-libs/qt-sql/ChangeLog | 8 | ||||
-rw-r--r-- | x11-libs/qt-sql/files/qt-sql-4.7.1_postgres_9.patch | 58 | ||||
-rw-r--r-- | x11-libs/qt-sql/qt-sql-4.7.1-r1.ebuild | 74 |
3 files changed, 139 insertions, 1 deletions
diff --git a/x11-libs/qt-sql/ChangeLog b/x11-libs/qt-sql/ChangeLog index fd246eac0d04..0a4f95572c63 100644 --- a/x11-libs/qt-sql/ChangeLog +++ b/x11-libs/qt-sql/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for x11-libs/qt-sql # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/x11-libs/qt-sql/ChangeLog,v 1.100 2010/11/09 15:50:59 wired Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-libs/qt-sql/ChangeLog,v 1.101 2010/12/05 19:35:43 wired Exp $ + +*qt-sql-4.7.1-r1 (05 Dec 2010) + + 05 Dec 2010; Alex Alexander <wired@gentoo.org> +qt-sql-4.7.1-r1.ebuild, + +files/qt-sql-4.7.1_postgres_9.patch: + added patch for postgres 9, bug #346099 *qt-sql-4.7.1 (09 Nov 2010) diff --git a/x11-libs/qt-sql/files/qt-sql-4.7.1_postgres_9.patch b/x11-libs/qt-sql/files/qt-sql-4.7.1_postgres_9.patch new file mode 100644 index 000000000000..eebc50ad6da7 --- /dev/null +++ b/x11-libs/qt-sql/files/qt-sql-4.7.1_postgres_9.patch @@ -0,0 +1,58 @@ +--- qt-everywhere-opensource-src-4.7.1/src/sql/drivers/psql/qsql_psql.cpp 2010-09-10 11:05:25.000000000 +0200 ++++ qsql_psql.cpp 2010-11-03 12:37:55.966977333 +0100 +@@ -661,6 +661,17 @@ + break; + } + break; ++ case 9: ++ switch (vMin) { ++ case 0: ++ serverVersion = QPSQLDriver::Version9; ++ break; ++ default: ++ serverVersion = QPSQLDriver::Version9; ++ break; ++ } ++ break; ++ + default: + break; + } +@@ -852,7 +863,8 @@ + // This hack can dissapear once there is an API to query this sort of information. + if (d->pro == QPSQLDriver::Version8 || + d->pro == QPSQLDriver::Version81 || +- d->pro == QPSQLDriver::Version82) { ++ d->pro == QPSQLDriver::Version82 || ++ d->pro == QPSQLDriver::Version9) { + transaction_failed = qstrcmp(PQcmdStatus(res), "ROLLBACK") == 0; + } + +@@ -963,6 +975,7 @@ + case QPSQLDriver::Version8: + case QPSQLDriver::Version81: + case QPSQLDriver::Version82: ++ case QPSQLDriver::Version9: + stmt = QLatin1String("SELECT pg_attribute.attname, pg_attribute.atttypid::int, " + "pg_class.relname " + "FROM pg_attribute, pg_class " +@@ -1046,6 +1059,7 @@ + case QPSQLDriver::Version8: + case QPSQLDriver::Version81: + case QPSQLDriver::Version82: ++ case QPSQLDriver::Version9: + stmt = QLatin1String("select pg_attribute.attname, pg_attribute.atttypid::int, " + "pg_attribute.attnotnull, pg_attribute.attlen, pg_attribute.atttypmod, " + "pg_attrdef.adsrc " +--- qt-everywhere-opensource-src-4.7.1/src/sql/drivers/psql/qsql_psql.h 2010-09-10 11:05:25.000000000 +0200 ++++ qsql_psql.h 2010-11-03 12:36:16.380310668 +0100 +@@ -104,7 +104,8 @@ + Version74 = 10, + Version8 = 11, + Version81 = 12, +- Version82 = 13 ++ Version82 = 13, ++ Version9 = 14 + }; + + explicit QPSQLDriver(QObject *parent=0); diff --git a/x11-libs/qt-sql/qt-sql-4.7.1-r1.ebuild b/x11-libs/qt-sql/qt-sql-4.7.1-r1.ebuild new file mode 100644 index 000000000000..3093afc34fcc --- /dev/null +++ b/x11-libs/qt-sql/qt-sql-4.7.1-r1.ebuild @@ -0,0 +1,74 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/x11-libs/qt-sql/qt-sql-4.7.1-r1.ebuild,v 1.1 2010/12/05 19:35:43 wired Exp $ + +EAPI="3" +inherit qt4-build + +DESCRIPTION="The SQL module for the Qt toolkit" +SLOT="4" +KEYWORDS="~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 -sparc ~x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x64-solaris ~x86-solaris" +IUSE="firebird freetds iconv mysql odbc postgres qt3support +sqlite" + +DEPEND="~x11-libs/qt-core-${PV}[aqua=,debug=,qt3support=] + firebird? ( dev-db/firebird ) + freetds? ( dev-db/freetds ) + mysql? ( virtual/mysql ) + odbc? ( dev-db/unixODBC ) + postgres? ( dev-db/postgresql-base ) + sqlite? ( dev-db/sqlite:3 )" +RDEPEND="${DEPEND}" + +pkg_setup() { + QT4_TARGET_DIRECTORIES="src/sql src/plugins/sqldrivers" + QT4_EXTRACT_DIRECTORIES="${QT4_TARGET_DIRECTORIES} + include/Qt/ + include/QtCore/ + include/QtSql/ + include/QtScript/ + src/src.pro + src/corelib/ + src/plugins + src/3rdparty + src/tools" + + if ! ( use firebird || use freetds || use mysql || use odbc || use postgres || use sqlite ); + then + ewarn "You need to enable at least one SQL driver. Enable at least" + ewarn "one of these USE flags: \"firebird freetds mysql odbc postgres sqlite tds\"." + die "Enable at least one SQL driver." + fi + + qt4-build_pkg_setup +} + +src_prepare() { + qt4-build_src_prepare + + # bug 346099 + epatch "${FILESDIR}"/"${P}"_postgres_9.patch + + sed -e '/pg_config --libs/d' -i "${S}"/configure \ + || die "sed to fix postgresql usage in ./configure failed" +} + +src_configure() { + # Don't support sqlite2 anymore + myconf="${myconf} -no-sql-sqlite2 + $(qt_use mysql sql-mysql plugin) $(use mysql && echo "-I${EPREFIX}/usr/include/mysql -L${EPREFIX}/usr/$(get_libdir)/mysql ") + $(qt_use postgres sql-psql plugin) $(use postgres && echo "-I${EPREFIX}/usr/include/postgresql/pgsql ") + $(qt_use sqlite sql-sqlite plugin) $(use sqlite && echo '-system-sqlite') + $(qt_use odbc sql-odbc plugin) + $(qt_use freetds sql-tds plugin) + $(qt_use firebird sql-ibase plugin) + $(qt_use qt3support)" + + myconf="${myconf} $(qt_use iconv) -no-xkb -no-fontconfig -no-xrender + -no-xrandr -no-xfixes -no-xcursor -no-xinerama -no-xshape -no-sm + -no-opengl -no-nas-sound -no-dbus -no-cups -no-nis -no-gif -no-libpng + -no-libmng -no-libjpeg -no-openssl -system-zlib -no-webkit -no-phonon + -no-xmlpatterns -no-freetype -no-libtiff -no-accessibility + -no-fontconfig -no-glib -no-opengl -no-svg -no-gtkstyle" + + qt4-build_src_configure +} |