kdb rebuild

This commit is contained in:
Rmys
2025-01-26 13:40:14 +03:00
parent eb6be99f7b
commit 67856e67f7
4 changed files with 147 additions and 273 deletions
@@ -0,0 +1,36 @@
From 40cdaea4d7824cc1b0d26e6ad2dcb61fa2077911 Mon Sep 17 00:00:00 2001
From: Pino Toscano <pino@kde.org>
Date: Tue, 29 Oct 2019 07:52:32 +0100
Subject: [PATCH] PgSQL driver: fix build with PostgreSQL 12+
ABSTIMEOID and RELTIMEOID were removed, as their data types were dropped.
---
src/drivers/postgresql/PostgresqlTypes.cpp | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/drivers/postgresql/PostgresqlTypes.cpp b/src/drivers/postgresql/PostgresqlTypes.cpp
index ea576d69..0697129e 100644
--- a/src/drivers/postgresql/PostgresqlTypes.cpp
+++ b/src/drivers/postgresql/PostgresqlTypes.cpp
@@ -36,6 +36,7 @@
#endif
#include <libpq-fe.h>
#include <catalog/pg_type.h> // needed for BOOLOID, etc.
+#include <pg_config.h> // needed for PG_VERSION_NUM
#ifdef _MSC_VER
#pragma warning( pop )
@@ -70,8 +71,10 @@ void PostgresqlDriver::initPgsqlToKDbMap()
//! @todo POLYGONOID geometric polygon '(pt1,...)'
m_pgsqlToKDbTypes.insert(FLOAT4OID, KDbField::Double);
m_pgsqlToKDbTypes.insert(FLOAT8OID, KDbField::Double);
+#if PG_VERSION_NUM < 120000
m_pgsqlToKDbTypes.insert(ABSTIMEOID, KDbField::Date);
m_pgsqlToKDbTypes.insert(RELTIMEOID, KDbField::Date);
+#endif
//! @todo TINTERVALOID (abstime,abstime), time interval
//! @todo CIRCLEOID geometric circle '(center,radius)'
//! @todo CASHOID monetary amounts, $d,ddd.cc
--
GitLab
@@ -0,0 +1,33 @@
From 4fc65f4fea459f8ab1f99c5ceb575fc8f4ea651a Mon Sep 17 00:00:00 2001
From: Bhushan Shah <bhush94@gmail.com>
Date: Sun, 13 Dec 2020 19:16:30 +0530
Subject: [PATCH] include KDEInstallDirs as first thing
Otherwise ECMGeneratePriFile won't get correct paths and will install
pri file in wrong place and things wanting to use kdb with qmake won't
work.
---
CMakeLists.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3219e967..e3f98b43 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -13,12 +13,12 @@ kdb_add_tests(OFF)
kdb_add_examples(OFF)
# ECM
+include(KDEInstallDirs)
include(ECMGeneratePriFile)
include(ECMInstallIcons)
include(ECMOptionalAddSubdirectory)
include(ECMPoQmTools)
include(ECMSetupVersion)
-include(KDEInstallDirs)
include(KDECMakeSettings NO_POLICY_SCOPE)
include(KDEFrameworkCompilerSettings NO_POLICY_SCOPE)
include(ECMSetupQtPluginMacroNames)
--
GitLab
@@ -0,0 +1,67 @@
From b36d74f13a1421437a725fb74502c993c359392a Mon Sep 17 00:00:00 2001
From: Nicolas Fella <nicolas.fella@gmx.de>
Date: Mon, 16 Nov 2020 16:41:27 +0100
Subject: [PATCH] Fix build with newer Qt
---
src/KDb.cpp | 34 +++++++++++++++++-----------------
1 file changed, 17 insertions(+), 17 deletions(-)
diff --git a/src/KDb.cpp b/src/KDb.cpp
index 5c3b601f..ee92c2ee 100644
--- a/src/KDb.cpp
+++ b/src/KDb.cpp
@@ -1635,33 +1635,33 @@ QString KDb::escapeBLOB(const QByteArray& array, BLOBEscapingType type)
for (int i = 0; i < size; i++) {
const unsigned char val = array[i];
if (val < 32 || val >= 127 || val == 39 || val == 92) {
- str[new_length++] = '\\';
- str[new_length++] = '\\';
- str[new_length++] = '0' + val / 64;
- str[new_length++] = '0' + (val % 64) / 8;
- str[new_length++] = '0' + val % 8;
+ str[new_length++] = QLatin1Char('\\');
+ str[new_length++] = QLatin1Char('\\');
+ str[new_length++] = QChar::fromLatin1('0' + val / 64);
+ str[new_length++] = QChar::fromLatin1('0' + (val % 64) / 8);
+ str[new_length++] = QChar::fromLatin1('0' + val % 8);
} else {
- str[new_length++] = val;
+ str[new_length++] = QChar::fromLatin1(val);
}
}
} else {
for (int i = 0; i < size; i++) {
const unsigned char val = array[i];
- str[new_length++] = intToHexDigit(val / 16);
- str[new_length++] = intToHexDigit(val % 16);
+ str[new_length++] = QChar::fromLatin1(intToHexDigit(val / 16));
+ str[new_length++] = QChar::fromLatin1(intToHexDigit(val % 16));
}
}
if (type == BLOBEscapingType::XHex || type == BLOBEscapingType::Octal) {
- str[new_length++] = '\'';
+ str[new_length++] = QLatin1Char('\'');
} else if (type == BLOBEscapingType::ByteaHex) {
- str[new_length++] = '\'';
- str[new_length++] = ':';
- str[new_length++] = ':';
- str[new_length++] = 'b';
- str[new_length++] = 'y';
- str[new_length++] = 't';
- str[new_length++] = 'e';
- str[new_length++] = 'a';
+ str[new_length++] = QLatin1Char('\'');
+ str[new_length++] = QLatin1Char(':');
+ str[new_length++] = QLatin1Char(':');
+ str[new_length++] = QLatin1Char('b');
+ str[new_length++] = QLatin1Char('y');
+ str[new_length++] = QLatin1Char('t');
+ str[new_length++] = QLatin1Char('e');
+ str[new_length++] = QLatin1Char('a');
}
return str;
}
--
GitLab
+11 -273
View File
@@ -17,19 +17,23 @@
<Dependency>extra-cmake-modules</Dependency>
<Dependency>qt5-base-devel</Dependency>
<Dependency>qt5-linguist</Dependency>
<Dependency>kcoreaddons-devel</Dependency>
<Dependency>kcoreaddons5-devel</Dependency>
<Dependency>icu4c-devel</Dependency>
<Dependency>ki18n-devel</Dependency>
<Dependency>ki18n5-devel</Dependency>
<Dependency>sqlite-devel</Dependency>
<Dependency>mariadb-lib</Dependency>
<Dependency>mariadb-client</Dependency>
<Dependency>postgresql-lib</Dependency>
</BuildDependencies>
<Patches>
<Patch level="1">kdb-3.2.0-build-w-pg12.patch</Patch>
<Patch level="1">40cdaea4.patch</Patch>
<Patch level="1">6.patch</Patch>
<Patch level="1">b36d74f1.patch</Patch>
<!-- <Patch level="1">kdb-3.2.0-build-w-pg12.patch</Patch> -->
<Patch level="1">kdb-3.2.0-cmake-pg12.patch</Patch>
<Patch level="1">kdb-3.2.0-cmake-pg13.patch</Patch>
<Patch level="1">kdb-3.2.0-qt-5.15.patch</Patch>
<!-- <Patch level="1">kdb-3.2.0-qt-5.15.patch</Patch> -->
<Patch level="1">kdb-3.2.0-KDEInstallDirs.patch</Patch>
</Patches>
</Source>
@@ -42,7 +46,7 @@
<Dependency>libgcc</Dependency>
<Dependency>sqlite</Dependency>
<Dependency>qt5-base</Dependency>
<Dependency>kcoreaddons</Dependency>
<Dependency>kcoreaddons5</Dependency>
<Dependency>mariadb-lib</Dependency>
<Dependency>postgresql-lib</Dependency>
</RuntimeDependencies>
@@ -68,279 +72,13 @@
</Package>
<History>
<Update release="40">
<Date>2023-12-07</Date>
<Update release="41">
<Date>2025-01-26</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="39">
<Date>2023-10-27</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="38">
<Date>2023-09-14</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="37">
<Date>2023-06-08</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="36">
<Date>2023-05-11</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="35">
<Date>2023-04-20</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="34">
<Date>2023-03-03</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="33">
<Date>2023-01-05</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="32">
<Date>2022-12-08</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="31">
<Date>2022-11-05</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="30">
<Date>2022-09-24</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="29">
<Date>2022-06-21</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="28">
<Date>2022-05-17</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="27">
<Date>2022-05-07</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="26">
<Date>2022-01-10</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="25">
<Date>2021-10-15</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="24">
<Date>2021-09-13</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="23">
<Date>2021-06-16</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="22">
<Date>2021-03-10</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="21">
<Date>2020-09-12</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="20">
<Date>2020-06-11</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="19">
<Date>2020-05-06</Date>
<Version>3.2.0</Version>
<Comment>Rebuild.</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="18">
<Date>2020-03-30</Date>
<Version>3.2.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="17">
<Date>2020-02-02</Date>
<Version>3.2.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="16">
<Date>2019-09-15</Date>
<Version>3.2.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="15">
<Date>2019-07-22</Date>
<Version>3.2.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="14">
<Date>2019-04-18</Date>
<Version>3.2.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="13">
<Date>2019-03-11</Date>
<Version>3.1.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="12">
<Date>2019-02-14</Date>
<Version>3.1.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="11">
<Date>2019-01-11</Date>
<Version>3.1.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="10">
<Date>2018-12-26</Date>
<Version>3.1.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="9">
<Date>2018-11-08</Date>
<Version>3.1.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="8">
<Date>2018-10-18</Date>
<Version>3.1.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="7">
<Date>2018-09-10</Date>
<Version>3.1.0</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="6">
<Date>2018-08-11</Date>
<Version>3.0.2</Version>
<Comment>Rebuild</Comment>
<Name>Ertuğrul Erata</Name>
<Email>ertugrulerata@gmail.com</Email>
</Update>
<Update release="5">
<Date>2018-02-03</Date>
<Version>3.0.2</Version>
<Comment>Rebuild</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="4">
<Date>2017-10-14</Date>
<Version>3.0.2</Version>
<Comment>Version bump</Comment>
<Name>Mustafa Cinasl</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="3">
<Date>2017-07-17</Date>
<Version>3.0.93</Version>
<Comment>Version bump</Comment>
<Name>Ali Algul</Name>
<Email>aligulle3801@gmail.com</Email>
</Update>
<Update release="2">
<Date>2017-06-30</Date>
<Version>3.0.1</Version>
<Comment>Version bump.</Comment>
<Name>Kamil Atlı</Name>
<Email>suvari@pisilinux.org</Email>
</Update>
<Update release="1">
<Date>2017-01-06</Date>
<Version>3.0.0</Version>