PKGBUILDs/qt5-base/mingw-w64-static/0004-Fix-building-mysql-driver-under-mingw.patch
Martchus defbb48223 Change work around for using static Qt 5 with CMake
* Make it possible to use shared and static Qt build (installed
  in the same prefix) at the same time in a project.
* This allows compiling shared and static libraries depending on
  Qt in one step.
* Static CMake modules are prefixed with 'Static', eg. 'StaticQt5Core'
  and provide importet targets as eg. 'Qt5::static::Core'.
2016-11-02 21:25:48 +01:00

26 lines
825 B
Diff

From f30b82c0605e3a2c1dfe8f0ac7da11182ebcd19f Mon Sep 17 00:00:00 2001
From: Mark Brand <mabrand@mabrand.nl>
Date: Tue, 6 Oct 2015 09:53:20 +0200
Subject: [PATCH 04/25] Fix building mysql driver under mingw
---
src/sql/drivers/mysql/qsql_mysql.pri | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/sql/drivers/mysql/qsql_mysql.pri b/src/sql/drivers/mysql/qsql_mysql.pri
index 3cfb614..8b7063f 100644
--- a/src/sql/drivers/mysql/qsql_mysql.pri
+++ b/src/sql/drivers/mysql/qsql_mysql.pri
@@ -4,7 +4,7 @@ SOURCES += $$PWD/qsql_mysql.cpp
QMAKE_CXXFLAGS *= $$QT_CFLAGS_MYSQL
LIBS += $$QT_LFLAGS_MYSQL
-unix {
+if (unix|mingw) {
isEmpty(QT_LFLAGS_MYSQL) {
!contains(LIBS, .*mysqlclient.*):!contains(LIBS, .*mysqld.*) {
use_libmysqlclient_r:LIBS += -lmysqlclient_r
--
2.10.1