refresh mariadb patch support (upstreamed version apparently incomplete)

This commit is contained in:
Rex Dieter 2017-10-19 15:32:02 -05:00
parent ae07984e4d
commit e724321967
2 changed files with 27 additions and 1 deletions

View File

@ -55,7 +55,7 @@ BuildRequires: pkgconfig(libsystemd)
Name: qt5-qtbase
Summary: Qt5 - QtBase components
Version: 5.9.2
Release: 1%{?dist}
Release: 2%{?dist}
# See LGPL_EXCEPTIONS.txt, for exception details
License: LGPLv2 with exceptions or GPLv3 with exceptions
@ -108,6 +108,7 @@ Patch64: qt5-qtbase-5.9.1-firebird.patch
# fix for new mariadb
Patch65: qtbase-opensource-src-5.9.0-mysql.patch
Patch66: qtbase-mariadb.patch
## upstream patches (5.9 branch)
@ -349,6 +350,7 @@ Qt5 libraries used for drawing widgets and OpenGL items.
%if 0%{?fedora} > 27
%patch65 -p1 -b .mysql
%endif
%patch66 -p1 -b .mariadb
%if 0%{?inject_optflags}
## adjust $RPM_OPT_FLAGS
@ -963,6 +965,9 @@ fi
%changelog
* Thu Oct 19 2017 Rex Dieter <rdieter@fedoraproject.org> - 5.9.2-2
- refresh mariadb patch support (upstreamed version apparently incomplete)
* Mon Oct 09 2017 Jan Grulich <jgrulich@redhat.com> - 5.9.2-1
- 5.9.2

21
qtbase-mariadb.patch Normal file
View File

@ -0,0 +1,21 @@
diff -up qtbase-opensource-src-5.9.2/src/plugins/sqldrivers/mysql/qsql_mysql.cpp.rex qtbase-opensource-src-5.9.2/src/plugins/sqldrivers/mysql/qsql_mysql.cpp
--- qtbase-opensource-src-5.9.2/src/plugins/sqldrivers/mysql/qsql_mysql.cpp.rex 2017-10-02 03:43:38.000000000 -0500
+++ qtbase-opensource-src-5.9.2/src/plugins/sqldrivers/mysql/qsql_mysql.cpp 2017-10-19 14:56:16.752878279 -0500
@@ -1159,14 +1159,15 @@ static void qLibraryInit()
# endif // MYSQL_VERSION_ID
#endif // Q_NO_MYSQL_EMBEDDED
-#ifdef MARIADB_BASE_VERSION
+#if defined(MARIADB_BASE_VERSION) || defined(MARIADB_VERSION_ID)
qAddPostRoutine(mysql_server_end);
#endif
}
static void qLibraryEnd()
{
-#if !defined(MARIADB_BASE_VERSION)
+#if !defined(MARIADB_BASE_VERSION) && !defined(MARIADB_VERSION_ID)
+//#error should not get here on f27+ says rex
# if !defined(Q_NO_MYSQL_EMBEDDED)
# if MYSQL_VERSION_ID > 40000
# if (MYSQL_VERSION_ID >= 40110 && MYSQL_VERSION_ID < 50000) || MYSQL_VERSION_ID >= 50003