summaryrefslogtreecommitdiffstats
path: root/src/plugins/sqldrivers/psql
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'wip/qt6' into wip/cmakeAlexandru Croitor2019-08-151-2/+2
|\ | | | | | | Change-Id: I50ac36b8803c296998149e98cc61e38687cdd14b
| * Port from QStringViewLiteral to u""Marc Mutz2019-07-291-2/+2
| | | | | | | | | | | | | | | | | | Now that all our supported compilers know char16_t, we no longer need QStringViewLiteral, whose only purpose in life was to turn u"" into L"" for MSVC < 2015. Change-Id: I25a094fe7992d9d5dbeb4a524d9e99e043dcb8ce Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | Merge remote-tracking branch 'origin/dev' into wip/cmakeAlexandru Croitor2019-06-031-2/+2
|\| | | | | | | Change-Id: Ide5b3408bfefca410323cf26b810b44c06d3a227
| * Use QStringView overloads of <QDate/Time>::toString()Marc Mutz2019-05-291-2/+2
| | | | | | | | | | | | | | | | | | | | | | There are no QLatin1String overloads, so using QLatin1String as the format string produced a temporary QString. Use QStringViewLiteral instead. Change-Id: I682eb8cfaa98fdcfb491edd290460db636a98a9f Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | Write find_dependency() calls in Qt Module config filesAlexandru Croitor2019-05-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change introduces a new function called qt_find_package() which can take an extra option called PROVIDED_TARGETS, which associates targets with the package that defines those targets. This is done by setting the INTERFACE_QT_PACKAGE_NAME and INTERFACE_QT_PACKAGE_VERSION properties on the imported targets. This information allows us to generate appropriate find_dependency() calls in a module's Config file for third party libraries. For example when an application links against QtCore, it should also link against zlib and atomic libraries. In order to do that, the library locations first have to be found by CMake. This is achieved by embedding find_dependency(ZLIB) and find_dependency(Atomic) in Qt5CoreDependencies.cmake which is included by Qt5CoreConfig.cmake. The latter is picked up when an application project contains find_package(Qt5Core), and thus all linking dependencies are resolved. The information 'which package provides which targets' is contained in the python json2cmake conversion script. The generated output of the script contains qt_find_package() calls that represent that information. The Qt5CoreDependencies.cmake file and which which dependencies it contains is generated at the QtPostProcess stop. Note that for non-static Qt builds, we only need to propagate public 3rd party libraries. For static builds, we need all third party libraries. In order for the INTERFACE_QT_PACKAGE_NAME property to be read in any scope, the targets on which the property is set, have to be GLOBAL. Also for applications and other modules to find all required third party libraries, we have to install all our custom Find modules, and make sure they define INTERFACE IMPORTED libraries, and not just IMPORTED libraries. Change-Id: I694d6e32d05b96d5e241df0156fc79d0029426aa Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | Merge commit 'dev' into 'wip/cmake-merge'Tobias Hunger2019-04-163-164/+163
|\| | | | | | | Change-Id: I176c40d031be26a1dd1cf08843e448a660598783
| * QPSQL: Use nullptr for pointersRobert Szefner2019-03-131-7/+7
| | | | | | | | | | Change-Id: I2b61cf0b81550c0878b0f06488a933c4b14e4728 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
| * QPSQL: Fix code formattingRobert Szefner2019-03-132-33/+32
| | | | | | | | | | | | | | Only whitespace changes. Change-Id: I474aa1b477be7081b58bd781417861878b207f4e Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
| * QPSQL: Use qstrtod() function for string to double conversionRobert Szefner2019-03-111-20/+24
| | | | | | | | | | | | | | | | | | | | | | | | A change to qstrtod() will give us a small performance improvement. Because the qstrtod() function does not correctly parse the NaN values, an appropriate check condition for NaN has been added. Also changed code structure so now the double conversion function is called only in one place. Task-number: QTBUG-65748 Change-Id: I49d40e5157e79cc5fce35db4c4272d1ccd270c6b Reviewed-by: Andy Shaw <andy.shaw@qt.io>
| * Always escape the table names when creating the SQL statementAndy Shaw2019-01-231-20/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since some databases are case sensitive if part of the query is quoted, then we should ensure that all instances of the table name are escaped unless the test is delibrately testing the non-escaped case. As a result, this commit also removes some expected failures pertaining to PostgreSQL and also adds an entry to the list of tables being dropped when a test is finished. [ChangeLog][Sql][PostgreSQL] QSqlDatabase is now stricter about table names when used with record() and primaryIndex(). If the tablename was not quoted when it was created, then the table name passed to record() and primaryIndex() needs to be in lower case so that PostgreSQL is able to find it. Fixes: QTBUG-65788 Change-Id: Id1f54cb66b761c39edf858501b730ede7eec1fd3 Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
| * QSQL: cleanup/modernize PostgreSQL pluginChristian Ehrlicher2019-01-093-85/+94
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Cleanup/modernize the PostgreSQL plugin - use nullptr - use range-based for loop - use QStringLiteral or QByteArray::fromRawData instead QLatin1String/QString::fromLatin1 where possible - use QRegularExpression instead QRegExp - use QQueue instead QList - uppercase SQL keywords Change-Id: Ie22be1538328ff1e2b663066ede96741d271e050 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
| * QSQL: add support for PostgreSQL 11Christian Ehrlicher2018-12-202-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | Add support for PostgreSQL 11 by adding QPSQLDriver::Version11 and use it in qMakePSQLVersion(). [ChangeLog][QSQL][PostgreSQL] Added support for PostgreSQL 11 Fixes: QTBUG-71642 Change-Id: Ie3cd3a81fd00084b587457b91b4e92c2e7001172 Reviewed-by: Andy Shaw <andy.shaw@qt.io> Reviewed-by: Robert Szefner <robertsz27@interia.pl>
* | CMake: Re-generate plugins/sqldrivers/psqlTobias Hunger2019-03-291-7/+8
| | | | | | | | | | Change-Id: If02ae8f616600d49cbbcd2aee298395d03b68a8f Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
* | cmake: Find and build psql pluginAlbert Astals Cid2019-02-121-0/+27
|/ | | | | Change-Id: I8cbc8ab0061f67824d78198cbb926f0625fc7e41 Reviewed-by: Liang Qi <liang.qi@qt.io>
* Merge remote-tracking branch 'origin/5.11' into 5.12Liang Qi2018-09-271-6/+6
|\ | | | | | | | | | | | | | | Conflicts: src/corelib/global/qconfig-bootstrapped.h src/widgets/util/qcompleter.cpp Change-Id: I4f44f0f074982530f2f2e750ce696230b2754cf3
| * Modernize the "datestring" featureLiang Qi2018-09-241-6/+6
| | | | | | | | | | | | Change-Id: I2236a456fe3758d9054b22e36fe6316f3522d533 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | SQL PostgreSQL/SQlite: Properly decode default varchar parameterChristian Ehrlicher2018-09-121-2/+5
|/ | | | | | | | | The default values for varchar columns were not decoded properly. Task-number: QTBUG-46968 Change-Id: Ie13d48c316cd694240f7e287010b97afc8c6c341 Reviewed-by: Robert Szefner <robertsz27@interia.pl> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Fix crash when deleting a QSqlQueryModel after closing the databaseMarcel Krems2018-03-211-2/+4
| | | | | | Task-number: QTBUG-66553 Change-Id: Ib5c04ebe5ac2b7581613e0044804072eb0980b2e Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* SQL/Postgres: Fix support for nan, inf and -infChristian Ehrlicher2018-03-071-38/+13
| | | | | | | | | | | Postgresql needs a special value for nan and +/- inf. This was considered during insert but not during select. Also remove some pre-c++11 inf/nan - handling and replace it with Qt equivalents. Change-Id: I044ca58e9cf673f4b100b05a0d8e25c8a9c29ec5 Reviewed-by: Robert Szefner <robertsz27@interia.pl> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* psql: do not try to get table name when PQftable returns InvalidOidChristian Ehrlicher2018-02-221-7/+9
| | | | | | | | | | | When the table for a selected column can't be determined (e.g. because there is no table for it), PQftable returns InvalidOid. This was not covered and a query to determine the table name was executed every time which slowed down calls to QSqlQuery::value(QString). Task-number: QTBUG-65226 Change-Id: Idd8fbaaef7b01ca4151439f46cad2cce6f1c93e9 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Merge remote-tracking branch 'origin/5.10.1' into 5.11Liang Qi2018-02-191-4/+7
|\ | | | | | | | | | | | | Conflicts: src/plugins/sqldrivers/psql/qsql_psql.cpp Change-Id: I070b455078b41e75c46562fcea5676d6218cd00c
| * psql: Improve performance of record()v5.10.1Andy Shaw2018-02-081-4/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In order to save having to always run a query to get the tablename for a known oid then we cache the result on the driver side. The oid stays the same while the table exists, so only on dropping it would it change. Recreating the table causes it to get a new oid, so there is no risk of the old one being associated with the wrong table when this happens, if the driver is still open at that point. The benchmark added shows the improvement from the previous code, before the results for PostgreSQL was: RESULT : tst_QSqlRecord::benchmarkRecord():"0_QPSQL@localhost": 259 msecs per iteration (total: 259, iterations: 1) whereas now it is: RESULT : tst_QSqlRecord::benchmarkRecord():"0_QPSQL@localhost": 0.000014 msecs per iteration (total: 59, iterations: 4194304) Task-number: QTBUG-65226 Change-Id: Ic290cff719102743da84e2044cd23e540f20c96c Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de> Reviewed-by: Robert Szefner <robertsz27@interia.pl> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | Small optimalization for NULL valuesRobert Szefner2018-01-091-2/+1
| | | | | | | | | | | | | | | | No need to call PQgetvalue() before PQgetisnull(). Change-Id: Ie83ee577b082dbe9d9ca2e86212a281abebdde6e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* | QPSQL: Add support for multiple result setsRobert Szefner2018-01-081-1/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change adds support for multiple result sets in PostgreSQL. [Important Behavior Changes] The QPSQL driver now supports multiple result sets. Since QPSQL previously did not support multiple result sets, there may be some compatibility issues with the existing code that executed several queries as one and were expecting to get the results of the last one. In this case use QSqlQuery::nextResult() to move to the last result set. [ChangeLog][QtSql][QPSQL] Added support for multiple result sets Change-Id: I2bfc91f512c4dac83116f3aa42833839a6da084c Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* | QPSQL: Add support for forward-only queriesRobert Szefner2018-01-061-30/+274
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With this change, it is possible to significantly reduce memory consumption of applications that fetch large result sets from databases. The implementation is based on the new functionality called "single-row mode" that was introduced in PostgreSQL version 9.2: https://www.postgresql.org/docs/9.2/static/libpq-async.html It also uses asynchronous commands PQsendQuery(), PQgetResult(): https://www.postgresql.org/docs/9.2/static/libpq-single-row-mode.html [ChangeLog][QtSql][QPSQL] Added support for forward-only queries (requires libpq version 9.2 or later) [Important Behavior Changes] The QPSQL driver now supports forward-only queries. To use this feature, you must build QPSQL plugin with PostreSQL client library version 9.2 or later. See the Qt SQL documentation for more information about QPSQL limitations of forward-only queries (sql-driver.html). [Important Behavior Changes] If you build the QPSQL plugin with PostgreSQL version 9.2 or later, then you must distribute your application with libpq version 9.2 or later. Otherwise, the QPSQL plugin will fail to load. Task-number: QTBUG-63714 Change-Id: I15db8c8fd664f2a1f719329f5d113511fa69010c Reviewed-by: Andy Shaw <andy.shaw@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | Merge remote-tracking branch 'origin/5.10' into devLars Knoll2018-01-021-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf sc/corelib/io/qfsfileengine_p.h src/corelib/io/qstorageinfo_unix.cpp src/platformsupport/eglconvenience/qeglpbuffer_p.h src/platformsupport/input/libinput/qlibinputkeyboard.cpp src/platformsupport/input/libinput/qlibinputpointer.cpp src/plugins/platforms/cocoa/qcocoamenu.mm src/plugins/platforms/ios/qiosscreen.h src/plugins/platforms/ios/qioswindow.h src/plugins/platforms/ios/quiview.mm src/printsupport/dialogs/qpagesetupdialog_unix_p.h src/printsupport/dialogs/qprintpreviewdialog.cpp src/printsupport/widgets/qcupsjobwidget_p.h src/widgets/widgets/qmenu.cpp tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp Change-Id: Iecb4883122efe97ef0ed850271e6c51bab568e9c
| * Merge remote-tracking branch 'origin/5.9' into 5.10Liang Qi2017-12-051-1/+1
| |\ | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/platforms/ios/quiview.mm Change-Id: I88384c70047391c75d9ff166c8d9881ff6751dbf
| | * QPSQL: Remove semicolon after Q_DECLARE_SQLDRIVER_PRIVATERobert Szefner2017-11-291-1/+1
| | | | | | | | | | | | | | | | | | | | | The semicolon is unnecessary and QtCreator warns of it. Change-Id: I20f803d1ea0136080ff4dc4f7d9863fd8028992e Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* | | Remove code that refers to PostgreSQL 7.2 or olderAndy Shaw2017-12-011-148/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We haven't had support for anything older than 7.3 for a long time, so this removes the code to save having to maintain it any further. Task-number: QTBUG-644 Change-Id: If0635f3bef5138a00a0e77011a70f23d0bffda32 Reviewed-by: Robert Szefner <robertsz27@interia.pl> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Merge remote-tracking branch 'origin/5.10' into devLiang Qi2017-11-232-98/+117
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/network/access/qhttp2protocolhandler_p.h src/network/kernel/kernel.pri src/network/ssl/qsslkey_qt.cpp src/plugins/platforms/cocoa/qcocoascreen.mm src/plugins/platforms/windows/accessible/iaccessible2.cpp src/plugins/platforms/windows/accessible/iaccessible2.h src/plugins/platforms/windows/accessible/qwindowsaccessibility.cpp src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.cpp src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.h src/widgets/widgets/qmenu_p.h tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp tests/auto/other/qaccessibility/tst_qaccessibility.cpp tests/auto/testlib/selftests/expected_cmptest.lightxml tests/auto/testlib/selftests/expected_cmptest.teamcity tests/auto/testlib/selftests/expected_cmptest.txt tests/auto/testlib/selftests/expected_cmptest.xml Done-with: Edward Welbourne <edward.welbourne@qt.io> Change-Id: I4217cc7d840cbae3e3dd28574741544469c4c6b9
| * | Merge remote-tracking branch 'origin/5.9' into 5.10Liang Qi2017-11-092-98/+117
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/kernel/qwindow.cpp src/plugins/platforms/cocoa/qcocoawindow.mm src/plugins/platforms/windows/qwindowssystemtrayicon.cpp src/plugins/platforms/xcb/qxcbconnection_xi2.cpp tests/auto/corelib/io/qtemporarydir/tst_qtemporarydir.cpp tests/auto/widgets/kernel/qaction/tst_qaction.cpp Change-Id: Ifa515dc0ece7eb1471b00c1214149629a7e6a233
| | * QPSQL: Fix check for minimum supported PostgreSQL versionRobert Szefner2017-11-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | According to Qt documentation http://doc.qt.io/qt-5/sql-driver.html#qpsql minimum supported version of PostgreSQL is 7.3 Change-Id: I30cffaddc29fd56b534bfd259cc235ea1204a21f Reviewed-by: Andy Shaw <andy.shaw@qt.io>
| | * QPSQL: Fix handling binary data for PostgreSQL 9.x and laterRobert Szefner2017-11-041-8/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Set byte_output to 'escape' mode for server version 9 and later, no matter what version of client library we use. Since setting byte_output doesn't depend on client version anymore, we can move it to separate function. This fixes qtbase\tests\auto\sql\kernel\qsqldatabase tst_QSqlDatabase::psql_escapeBytea() test (before this change test did not pass on PostgreSQL 9.6) Change-Id: I37aaa18267d7e6459c00010ed899536c01e8124e Reviewed-by: Andy Shaw <andy.shaw@qt.io>
| | * QPSQL: Fix detection of PostreSQL version 9.x and laterRobert Szefner2017-11-042-98/+108
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixed parsing version string for PostgreSQL. PostgreSQL versioning changed since version 10, see link: https://www.postgresql.org/support/versioning Extended QPSQLDriver::Protocol enum for PostreSQL 9.x and later, added underscore to item names to separate major and minor version. Changed long switch-case statements to if-else. Change-Id: Ib19ae7ba426f262e80c52670e7ecb3532ff460a0 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* | | Replace Q_DECL_OVERRIDE with override where possibleKevin Funk2017-09-193-33/+33
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remaining uses of Q_DECL_OVERRIDE are in: src/corelib/global/qcompilerdetection.h src/corelib/global/qglobal.cpp doc/global/qt-cpp-defines.qdocconf (definition and documentation of Q_DECL_OVERRIDE) tests/manual/qcursor/qcursorhighdpi/main.cpp (a test executable compilable both under Qt4 and Qt5) Change-Id: Ib9b05d829add69e98a86238274b6a1fcb19b49ba Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | QSqlField: Add a means to see what the tablename is for a given fieldAndy Shaw2017-07-121-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | When you are using a query that pulls from a number of different tables then it can be ambiguous as to which table a particular field belongs to. So this will make it possible to determine the table that a given field belongs to if it is set. Task-number: QTBUG-7170 Change-Id: I49b7890c0523d81272a153df3860df800ff853d5 Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | Merge remote-tracking branch 'origin/5.9' into devLiang Qi2017-04-041-5/+5
|\| | | | | | | | | | | | | | | Conflicts: src/platformsupport/fontdatabases/mac/qcoretextfontdatabase_p.h src/plugins/platforms/xcb/qxcbwindow.cpp Change-Id: Ic747c3c50e68c005b425e7a1ec2a90965527c8bd
| * Prefer rvalue version of toLocal8Bit()Anton Kudryavtsev2017-03-301-1/+1
| | | | | | | | | | | | | | | | ... to re-use existing buffers. Change-Id: I5907a2e29d7f7dac04df5bf50769b47131e175d8 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * Prefer rvalue versions of toLower() and toUpper()Anton Kudryavtsev2017-03-281-4/+4
| | | | | | | | | | | | | | ... to re-use existing buffers. Change-Id: Ib2bc938f1cf0451c1dbc012b3db022b878e987cb Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/5.9' into devLiang Qi2017-03-281-7/+6
|\| | | | | | | | | | | | | | | | | Conflicts: examples/examples.pro tests/auto/corelib/tools/qchar/tst_qchar.cpp tests/auto/other/qaccessibility/accessiblewidgets.h Change-Id: I426696c40ab57d14dc295b8103152cede79f244c
| * Merge remote-tracking branch 'origin/5.8' into 5.9Liang Qi2017-03-211-7/+6
| |\ | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/platforms/eglfs/eglfs-plugin.pro Change-Id: Id76cdbb41b7758572a3b8ea4dcb40d49bac968db
| | * PostgreSQL: fix datetime format when system locale doesn't use arabic numeralsMichael Jabbour2017-03-181-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | psql driver was previously using QDateTime::toString() function which is locale-depndent. Task-number: QTBUG-59524 Change-Id: I7f50f95b5c82e66476abfee24ad28b78b3257041 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Remove a Q_GLOBAL_STATIC with QMutex in favor of QBasicAtomicIntThiago Macieira2017-03-171-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | Much simpler, no memory allocation, no locking. Change-Id: Iae839f6a131a4f0784bffffd14a9e70c7b62d9a7 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | | Fix postgres notification subscription on LISTEN failureLorenz Haas2017-03-161-0/+1
|/ / | | | | | | | | | | | | | | | | | | | | Register a notification only if the LISTEN call was successful. This behaves now like the UNLISTEN case: the notification is only unregistered if the call was successful. Change-Id: I2b18ec3a619fea5bed0a319013ad9df4b9e15456 Reviewed-by: Matt Newell <newellm@blur.com> Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* / Use QString::asprintf(), QStringBuilder, and the multi-arg overload of ↵Alexander Volkov2017-01-121-1/+1
|/ | | | | | | | | | | | | QString::arg() ... instead of sequential .arg(const QString &) callings. It saves memory allocations and prevents unexpected results if replacing strings contain place markers. Found with clazy's qstring-arg check. Change-Id: I3912275a6e11c6fb7559ff5623f2e8cde9b7f07a Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Replace QLatin1Literal with QLatin1StringAnton Kudryavtsev2016-09-031-2/+2
| | | | | | | | | | QLatin1Literal is just alias of QLatin1String for Qt4 compatibility. So it's style cleanup patch. Change-Id: Ia3b3e5dc3169f13a1ef819d69be576b8a8bfb258 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* employ QMAKE_USE: LIBS += $$QMAKE_LIBS_FOOOswald Buddenhagen2016-08-191-7/+1
| | | | | | | | this migrates the cases where the build system already made (some) use of variables (possibly) set by configure. Change-Id: I43a08caed481d5f887a3a40821e71a4797760e7e Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Unify naming of LIBS/CFLAGS for 3rd party librariesLars Knoll2016-04-071-2/+2
| | | | | | | | Most libs use QMAKE_LIBS/CFLAGS, but some have other naming conventions. Unify them into using QMAKE_LIBS/CFLAGS. Change-Id: I39b188adc1f9a223a83b294c5315c3095a9c68de Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* Always compile sql drivers as pluginsLars Knoll2016-04-074-3/+1648
| | | | | | | | | | | | Compiling the drivers into Qt Sql does not make a lot of sense anymore, as we handle plugins well enough in the build system these days. [ChangeLog][Build system] SQL drivers are now always compiled as plugins. Change-Id: I364b82a480849399d1fafe4b20e9f08922569260 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Mark Brand <mabrand@mabrand.nl>
* Updated license headersJani Heikkinen2016-01-151-14/+20
| | | | | | | | | | | From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new LGPL header instead of LGPL21 one (in those files which will be under LGPL v3) Change-Id: I046ec3e47b1876cd7b4b0353a576b352e3a946d9 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>