summaryrefslogtreecommitdiff
path: root/dev-db/libdbi-drivers
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-06-13 00:08:30 +0100
committerV3n3RiX <venerix@koprulu.sector>2024-06-13 00:08:30 +0100
commit0ebcd2cbf178600b5eb36b2f24cdbb3d2f4a9000 (patch)
tree941e6ba8c256dd27e9f9ca634f08d4bf0278798e /dev-db/libdbi-drivers
parentf0ddcad13515f66d2f3bf827d33c277bdba7e1dd (diff)
gentoo auto-resync : 13:06:2024 - 00:08:29
Diffstat (limited to 'dev-db/libdbi-drivers')
-rw-r--r--dev-db/libdbi-drivers/Manifest4
-rw-r--r--dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-buffer-overflow-sqlite.patch14
-rw-r--r--dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-c99.patch11
-rw-r--r--dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-fortify-source-sqlite.patch13
-rw-r--r--dev-db/libdbi-drivers/libdbi-drivers-0.9.0-r3.ebuild90
5 files changed, 132 insertions, 0 deletions
diff --git a/dev-db/libdbi-drivers/Manifest b/dev-db/libdbi-drivers/Manifest
index 7381c404f9ed..3d5d3c3f2ab8 100644
--- a/dev-db/libdbi-drivers/Manifest
+++ b/dev-db/libdbi-drivers/Manifest
@@ -1,7 +1,11 @@
+AUX libdbi-drivers-0.9.0-buffer-overflow-sqlite.patch 452 BLAKE2B 4f0a651fb9a909a4625271ceaa4870ae3d17bc6228c3a199befb078085f5d7e8b4d6e635f748132c85ac564194b4eed45d0a1feea1cb980db7429033021127b5 SHA512 2b3595112cdee094eb5950708abcac87fe90ea8ab654e14f8fca2b08ee18505e64881b4f6a5980d353d932b0ea9088a653d4ed26288db879c27d68eb19374979
+AUX libdbi-drivers-0.9.0-c99.patch 266 BLAKE2B 41c5fc21157f28233c5b90ed225704f2ff7d6e00bea43ff8e8c1c915987d667136b9eede345c3bb850b9631a60d6a1a7f767d481f0aedff720ce0735afcad729 SHA512 fe81ca38fc36d5a78521d79c4481b5a67e83046a5e2b256b45b4ec72e1df37f5d0958c1199f796b5d6c81d2a58f8aff7407bc343056669d11b0d58248821f973
AUX libdbi-drivers-0.9.0-clang16-build-fix.patch 2363 BLAKE2B a635d3bd7a4b06d95150cbc0590ea64d4d5f28f34b93f4e559e867de6960d11d74e20d6a86b2ce36c47808dce8c7d59c43bb1f2ab4dfcca2738aba64a088bcfb SHA512 8b3094a92943ed02091648e3566ef2715a2e8a831ac6913615f2868949d0cbac7f02e82199b3abe61a946d862c51d8e25f6b5043e9cf827462d97155ebef1d8e
AUX libdbi-drivers-0.9.0-doc-build-fix.patch 694 BLAKE2B 95207e6fbd947c01a1c3a99806f09e3f932b6d7b6fe1b55ffeb98ce73a54b7f984ffe9811c834e53e961500ae688b0548599b3f9b47a5d1e083eedf5c7ed650d SHA512 0ff58a08909327db91ebd0dfad7ac88ebb17156bbb7afc8bfc8a3711fee37708a7ad715ed50b5085cdd15d3cdb5c06de3a0779694104fb6332a1e9c2f51f5b0e
+AUX libdbi-drivers-0.9.0-fortify-source-sqlite.patch 451 BLAKE2B cf41debe291737ec418d0a96b5d839ac2ae44cfe487982dbb18ec5658b275da673d7f6066c6113af0ffbe622ad26595033aeb244f38702e920fcdd38619f2279 SHA512 d2e9e14fcff631fdada7bbc063aa5266d5f17fe5589405707867cc6eb95dc198ec62adc9d3b615c5ca29d31853644913aa82503ae6161be06d5924d8c1430b56
AUX libdbi-drivers-0.9.0-slibtool-libdir.patch 564 BLAKE2B 7effa5db121872b079af2919b56857fda040f9712a10789ba3e4c4352a0b172127026f1df9c2f93071cf78a14f05431557e23e63b74f52df87710942d9c14711 SHA512 9f4ca8fd4147ed1c619c2d7ac40b4d67e67f3f6f940568647dd1782a705a52cd3d10241b2c4039ad8cca2ecc7186841640ffa44fd56d5fc9d19a7e8f3fc974ba
DIST libdbi-drivers-0.9.0.tar.gz 1829864 BLAKE2B 2071c0cc21b1b4eeda926d5ce36f6dde03ede206dac91780aabafcb7c5b399f4b9580910e5ede08c9f0bf026f4af2088d1d0e8c1835b86273a7739b2946ed3c3 SHA512 f4d3aaa71014697c53012a10bf9f0af398bcf5ee5872af165f8f43a682d2fb3045a9172ffea0e068dcbfcad52494878c037d8d90fadfaf176936e42f7f1e85c1
EBUILD libdbi-drivers-0.9.0-r1.ebuild 2243 BLAKE2B 45a77565c172b685eceb001e4d60cadb8b3a120f5778a67bdc27ff6017d946787e4189f3e6db99a7c87b1c396611b7779312e1b7d0a26f467bdd0a00e31ed1dd SHA512 bd5d7e8bdbde99ce2304c537f2a3059d22f6f04a9b364c7430be4a7a97c65c4e8ce5452aaf663e22c7818a0ca0658839229cfeb14ee1d3638c1f210d9e87780d
EBUILD libdbi-drivers-0.9.0-r2.ebuild 2165 BLAKE2B 913337e185c5a912987cafa8de77a380b54261ff4d041068b5e4d33339db8f281c9625e6e30eaf1eeb7fa8588f01fe598c0e7c8178e684f6740f34d9aed89a13 SHA512 0057ca42127698863f40557c18cd993d0f07a7b105eff63b269982679369d665943155d127599b70a5463cd9cb2c3d23375afaa44bd7d8dae6ddd422e34f3e0b
+EBUILD libdbi-drivers-0.9.0-r3.ebuild 2313 BLAKE2B 299e55229011975e065f7a087da17e03dec94d1b812436409e16a215eca3c394939f3c0352882d73f057ca8852477d6957952d9f36f53c82c051ac93851bea6a SHA512 b39dcf721881a9433abcac0642e0edfb0f51d5933ff30a05dbf76a6f8869c0254fb260a2a17354604175911d9295c3472b8185c694869772e0ee4c316d51f137
MISC metadata.xml 303 BLAKE2B 0157e37665116984034696663a1469b658cbcbd59bb144dc8972f6a1994330835bc6e787dc490c877eff0495004cc10f336b61a77d9057a50a757bed7e2423b5 SHA512 590af573bc7adf876ea969185568ae84dc41b9484d9efa9e89b5b6cde1f7af787e54b5c17f75731db4a42e615c1e1731e784a4dd309e03e7ca9b2850bcc34edf
diff --git a/dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-buffer-overflow-sqlite.patch b/dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-buffer-overflow-sqlite.patch
new file mode 100644
index 000000000000..3bec6d958bc6
--- /dev/null
+++ b/dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-buffer-overflow-sqlite.patch
@@ -0,0 +1,14 @@
+https://bugs.gentoo.org/933427
+https://sourceforge.net/p/libdbi-drivers/libdbi-drivers/ci/7657c4c688c021d5f42a38e998c876d1739d5d8f
+--- a/drivers/sqlite3/dbd_sqlite3.c
++++ b/drivers/sqlite3/dbd_sqlite3.c
+@@ -585,7 +585,8 @@
+ unsigned char *temp;
+ size_t len;
+
+- if ((temp = malloc(from_length*2)) == NULL) {
++ /* allocate an extra byte for NULL and two for the quotes */
++ if ((temp = malloc(2*from_length+1+2)) == NULL) {
+ return 0;
+ }
+
diff --git a/dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-c99.patch b/dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-c99.patch
new file mode 100644
index 000000000000..c75e9f405aec
--- /dev/null
+++ b/dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-c99.patch
@@ -0,0 +1,11 @@
+https://bugs.gentoo.org/920460
+--- a/drivers/firebird/dbd_firebird.c
++++ b/drivers/firebird/dbd_firebird.c
+@@ -43,6 +43,7 @@
+ #include <string.h>
+ #include <time.h>
+ #include <ibase.h>
++#include <ctype.h>
+
+ #include "dbd_firebird.h"
+ #include "firebird_charsets.h"
diff --git a/dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-fortify-source-sqlite.patch b/dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-fortify-source-sqlite.patch
new file mode 100644
index 000000000000..9624a8c039b6
--- /dev/null
+++ b/dev-db/libdbi-drivers/files/libdbi-drivers-0.9.0-fortify-source-sqlite.patch
@@ -0,0 +1,13 @@
+https://bugs.gentoo.org/933427
+https://sourceforge.net/p/libdbi-drivers/libdbi-drivers/ci/24f48b86c8988ee3aaebc5f303d71e9d789f77b6/
+--- a/drivers/sqlite3/dbd_sqlite3.c
++++ b/drivers/sqlite3/dbd_sqlite3.c
+@@ -1451,7 +1451,7 @@ static int getTables(char** tables, int
+ break;
+ }
+
+- word_lower[item-start+1];
++ char word_lower[item-start+1];
+ strncpy(word_lower,start,item-start);
+ word_lower[item-start] = '\0';
+ int i = 0;
diff --git a/dev-db/libdbi-drivers/libdbi-drivers-0.9.0-r3.ebuild b/dev-db/libdbi-drivers/libdbi-drivers-0.9.0-r3.ebuild
new file mode 100644
index 000000000000..d82a8c964d2e
--- /dev/null
+++ b/dev-db/libdbi-drivers/libdbi-drivers-0.9.0-r3.ebuild
@@ -0,0 +1,90 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools
+
+DESCRIPTION="The libdbi-drivers project maintains drivers for libdbi"
+HOMEPAGE="https://libdbi-drivers.sourceforge.net/"
+SRC_URI="https://downloads.sourceforge.net/project/${PN}/${PN}/${P}/${P}.tar.gz"
+
+LICENSE="LGPL-2.1+"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
+IUSE="doc firebird mysql oci8 postgres +sqlite static-libs"
+
+REQUIRED_USE="|| ( mysql postgres sqlite firebird oci8 )"
+RESTRICT="firebird? ( bindist )"
+
+RDEPEND="
+ >=dev-db/libdbi-0.9.0
+ firebird? ( dev-db/firebird )
+ mysql? ( dev-db/mysql-connector-c:= )
+ postgres? ( dev-db/postgresql:* )
+ sqlite? ( dev-db/sqlite:3 )
+"
+DEPEND="${RDEPEND}"
+BDEPEND="doc? ( app-text/openjade )"
+
+DOCS=( AUTHORS ChangeLog NEWS README README.osx TODO )
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-0.9.0-doc-build-fix.patch
+ "${FILESDIR}"/${PN}-0.9.0-slibtool-libdir.patch
+ "${FILESDIR}"/${PN}-0.9.0-clang16-build-fix.patch
+ "${FILESDIR}"/${PN}-0.9.0-fortify-source-sqlite.patch
+ "${FILESDIR}"/${PN}-0.9.0-buffer-overflow-sqlite.patch
+ "${FILESDIR}"/${PN}-0.9.0-c99.patch
+)
+
+pkg_setup() {
+ use oci8 && [[ -z "${ORACLE_HOME}" ]] && die "\$ORACLE_HOME is not set!"
+}
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+src_configure() {
+ local myconf=""
+ # WARNING: the configure script does NOT work correctly
+ # --without-$driver does NOT work
+ # so do NOT use `use_with...`
+ # Future additions:
+ # msql
+ # freetds
+ # ingres
+ # db2
+ use mysql && myconf+=" --with-mysql"
+ use postgres && myconf+=" --with-pgsql"
+ use sqlite && myconf+=" --with-sqlite3"
+ use firebird && myconf+=" --with-firebird"
+ if use oci8; then
+ [[ -z "${ORACLE_HOME}" ]] && die "\$ORACLE_HOME is not set!"
+ myconf+=" --with-oracle-dir=${ORACLE_HOME} --with-oracle"
+ fi
+
+ econf \
+ $(use_enable doc docs) \
+ $(use_enable static-libs static) \
+ --with-dbi-libdir=/usr/$(get_libdir) \
+ ${myconf}
+}
+
+src_test() {
+ if [[ -z "${WANT_INTERACTIVE_TESTS}" ]]; then
+ ewarn "Tests disabled due to interactivity."
+ ewarn "Run with WANT_INTERACTIVE_TESTS=1 if you want them."
+ return 0
+ fi
+ einfo "Running interactive tests"
+ emake check
+}
+
+src_install() {
+ default
+
+ find "${ED}" -name '*.la' -type f -delete || die
+}