diff options
Diffstat (limited to 'dev-db')
39 files changed, 3557 insertions, 211 deletions
diff --git a/dev-db/Manifest.gz b/dev-db/Manifest.gz Binary files differindex 0f3d5c2dc155..192f8f629209 100644 --- a/dev-db/Manifest.gz +++ b/dev-db/Manifest.gz diff --git a/dev-db/citus/Manifest b/dev-db/citus/Manifest index 4d02384fa509..9d398785586e 100644 --- a/dev-db/citus/Manifest +++ b/dev-db/citus/Manifest @@ -1,8 +1,10 @@ DIST citus-12.0.1.tar.gz 6740395 BLAKE2B ca004f8026d94c1ed70c9c7450726287aff415c13b80b93d25a19fbae9a79cbbeaec51521fc7922d5574c75bddb9537d42d656121ca586f4512afe773be5bf76 SHA512 db9b882c63ef6ab848a85d547390d4fc61b97056485dcc8fa51c289a302b78d0de959e29c27a91c494fd3e20491f6a96e96436d8766d02b2770f0e375b94564e -DIST citus-12.1.5.tar.gz 6912425 BLAKE2B ec08387ed6883ecd27f432843ae1068fdc657b62e4bd74e2feb4f806ccf7f3954c600cb5dce27db90ef3fccfd9ddf43bd88bb73fd44c8f39c8517999264e3255 SHA512 267cf5e52a23eabd3ac86eedb9929fbeae09b16279db5656d328ddbf64879fe3691e82fb0d15efb216e3c254b37cb3b6a5ca9c5097fc5f075c8e7b9ec3337a93 DIST citus-12.1.6.tar.gz 6920293 BLAKE2B 193bbf890709e8926253112e10084ab566af9ad4bd3b802e9eff792580c8ac8f5caa04fe17f1c04d306dea5047a85e60fba2ddc074ffbfd2bec9a407d789321f SHA512 f2b19ba915d2eb52393b3b1a6800977d7f592319ffdbf2491d35fb2cf2221766400dce954198306f1edb91affd9bc6e53c683dd3116fe8b7ae0895fed254b6d5 +DIST citus-12.1.7.tar.gz 6923683 BLAKE2B 114dbb30d0e353f3d368db13ab265082f952774fa013a7c7d7848e4c3686a6d3c4b47d259ddf3660e58d3e59c2b0802c51edac3df28c44717e2ba30ae063cd7c SHA512 3c24bfde6e1786c324a5fbd64ede70b557966e15a0852c1497af21a5e12cd10e46798ff0e3042fb23fccb3ccbc5f6ccdfbcdbf96ac6a50ec511d9df6740977e1 +DIST citus-13.0.1.tar.gz 6901310 BLAKE2B 21c4bb728f8aed546bf92429487b503a1f69f02e2e9b6ff93a7494820733f3b2f9af63b3773de8fa47a25f37011b55ded746ca007a59a3b5332e6ccd6170945f SHA512 dc7ec7b28d654726457e8cd9a74078fc58e7d8792246baec7f09a6d595a4277a60ab2ddcd4068607c253281e68959a1f9b7a42b817849e797be5a24631d480b7 EBUILD citus-12.0.1.ebuild 584 BLAKE2B 152c7a153df6d52c8835d54ad414406207005ab4812c48e75bd22d02cc2bc94a20d935558b6b3087213d76b11bada869d3f526b5e96c6727de3a051b936be3bc SHA512 bec170f41b98cc4d86e7cb7ea8efdde635aa6895dde62ac4e4daff06b82af0159339947f1c6477aaf4b0c7f95c4b241faa42b7731fab848c2798db8077181c00 -EBUILD citus-12.1.5.ebuild 587 BLAKE2B 5809698fa280ab814b6487401e0f4599eb69f38fe3203b73ce1b32f6533d2149319c75c03e34aee6b23ecbeb9d6c18d730d01f57068a4f4bf8795c5aae1ae19f SHA512 b41baaed95939faf6f3661544f6e1efc2ba5c9453723c0db41686cd912f642551a1be3618f5e2f60397c6cd01226036ca19b3414ec2af1ae5ba0e49d5aa94769 EBUILD citus-12.1.6.ebuild 587 BLAKE2B 5809698fa280ab814b6487401e0f4599eb69f38fe3203b73ce1b32f6533d2149319c75c03e34aee6b23ecbeb9d6c18d730d01f57068a4f4bf8795c5aae1ae19f SHA512 b41baaed95939faf6f3661544f6e1efc2ba5c9453723c0db41686cd912f642551a1be3618f5e2f60397c6cd01226036ca19b3414ec2af1ae5ba0e49d5aa94769 +EBUILD citus-12.1.7.ebuild 605 BLAKE2B f989b5b36ce8daedadb4e9bd03aa0a7433df2e926eb775883956214088e36b96413900a1f944d0d47a23e4ac683f1f96ef332b0d4ed8058307e2601a983f1206 SHA512 2e997930cdad2254fa5f5d0f0915b46c0cb29101aaf8d4879fb02b9c842cd04bb4c20be49f1b5887737e754d10d9bb82ecc0778f86947e85b90a11dfcea28b89 +EBUILD citus-13.0.1.ebuild 605 BLAKE2B 0c9f064dbf0f5754cbdcfe949d1af1e30b6468b7c81348ce073bba531f8438bcebe33990d48f239f450aebd518aa3f1ea36b3662c2d7b567fa48dde634fd9c7e SHA512 4c155175af7a11242a0285c4b3821f5675fc45b8a249fd1b2ea7c09125eddce7bf5b353057b84382498b0626b92fa5dab17ac1116ec7929194f8feec72c93dee EBUILD citus-9999.ebuild 551 BLAKE2B 326c90fff472b883d97b5bebaea32404fec6755b893c16789bbfb9513b946c15db3eece57a7c3af747cdec3a942c6d55432a555375625f362a40a26064203312 SHA512 d742fa8d64c18316ab371ba146f2969c3ce4401e611ecf17038488cc2e178617681866c3e67bac8ce68f5985f1cfca939f33806000b6798bbc1bfd38c7f99434 MISC metadata.xml 361 BLAKE2B 4661dce471924e095b993bcb2cd32627e08535138f7c2b65b7471342a27cddeda67733d87e50924bf9702594299b158318ac11c59f2d75f2df94880852e4d69e SHA512 3337957bcc132440bb973175a4974800601de71f3effa8dab48edf2847ecd91da8c4790f8a094505c11375700fd0241b9b3f8727a99c54b06de1c30a6e6cf8af diff --git a/dev-db/citus/citus-12.1.5.ebuild b/dev-db/citus/citus-12.1.7.ebuild index c485f555445b..1bbb3bc173b5 100644 --- a/dev-db/citus/citus-12.1.5.ebuild +++ b/dev-db/citus/citus-12.1.7.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -28,5 +28,5 @@ DEPEND="${POSTGRES_DEP} RDEPEND="${DEPEND}" src_configure() { - postgres-multi_foreach econf + postgres-multi_foreach econf --without-libcurl } diff --git a/dev-db/citus/citus-13.0.1.ebuild b/dev-db/citus/citus-13.0.1.ebuild new file mode 100644 index 000000000000..d21d1b932005 --- /dev/null +++ b/dev-db/citus/citus-13.0.1.ebuild @@ -0,0 +1,32 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +POSTGRES_COMPAT=( 15 16 17 ) + +inherit postgres-multi + +DESCRIPTION="Open-source postgresql extension for clustering/multi-node setups" +HOMEPAGE="https://www.citusdata.com/" + +SRC_URI="https://github.com/citusdata/citus/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + +IUSE="" +LICENSE="POSTGRESQL AGPL-3" + +KEYWORDS="~amd64" + +SLOT=0 + +RESTRICT="test" + +DEPEND="${POSTGRES_DEP} + app-arch/lz4 + app-arch/zstd + " +RDEPEND="${DEPEND}" + +src_configure() { + postgres-multi_foreach econf --without-libcurl +} diff --git a/dev-db/dbeaver-bin/Manifest b/dev-db/dbeaver-bin/Manifest index 627c1480c30c..6826e88be5b1 100644 --- a/dev-db/dbeaver-bin/Manifest +++ b/dev-db/dbeaver-bin/Manifest @@ -1,4 +1,7 @@ -DIST dbeaver-ce-24.3.2-linux.gtk.aarch64-nojdk.tar.gz 88491639 BLAKE2B 4d5332e9a885ff6caf0cafefc7a5f76990e87639e7838fecb1b30415ee1ddd45b95d3dd605308ed81a77987ac631668b3bfb83597e62ca2370761a0614c8e80e SHA512 2e441ea51f25124f56e5b2a0d06f146a323a038c838db4be90b3822f06cdf9c004f4b67c756f293d7cc10cd38184ad99881193c9863d743da4ca902526d97246 -DIST dbeaver-ce-24.3.2-linux.gtk.x86_64-nojdk.tar.gz 88525311 BLAKE2B fc4dd9c803d76042cc0ccc9f2af1387846b72f6e485986bb2df3748ea6a6d6bdaef0a94b06bd86e4d931f1b840371a238c0b1077860ec83faf62c65a9d106703 SHA512 7525c5a0288e0a5df068d91a99d471cab64525f9aa1e623564a1a668cc9a9a0bf22833c8b3f540c657953c23f8c1f066b7d8a349c7facfd3ff29d9d3e6c36307 -EBUILD dbeaver-bin-24.3.2.ebuild 1347 BLAKE2B 01478ada7aeded7d676cbf06adb46e916794c89d3bd870fb01393a62d35fbdb0570917030da9c840d77f231fae57b07cc9d464284e11f2cd07fbd12986a537d7 SHA512 5e1d108d48417cb3fda5e27be9c7e9b9c121ec1d36450c411994c59b73500bd4b2370f2a5316b90ead620334c5a8cf1ab494ad56bcb7c2026a681a80de7ae499 +DIST dbeaver-ce-24.3.3-linux.gtk.aarch64-nojdk.tar.gz 88658617 BLAKE2B 82a68747bf70692f9489d340e45a3ff860ad5c612400c6c040377cb8087accc798dd1689c8f573f60ff5ef586a04bb543d6e8eb621371d6973cf58ae9a28c428 SHA512 71f978eecdf5fb634f6a3c164cc8b7301508847efb5faa9efb0745278acc0f74b6e9a973fb9127b06c2854d1ab433842bd2882872cbd42c8f6375489f9440f84 +DIST dbeaver-ce-24.3.3-linux.gtk.x86_64-nojdk.tar.gz 88694419 BLAKE2B 5e63f5c82b1d57c0c2f9e76c39aff4837e7e1ff5da0147f9b5f089985a380f1f901cc2f752b90dfe65643a9a9f097b6f4579b363011be4436adeab9d3f2cbe6b SHA512 14c9ec29933b7235e60df717348e1ed0736e8e67d64fa09c31560a22a7072f39179ecf4637b65636733fe27c5872f702063c4dcbb2048ea0c94a6670e059405f +DIST dbeaver-ce-24.3.4-linux.gtk.aarch64-nojdk.tar.gz 88952315 BLAKE2B 6ae1b7f68dd2f2cbc63ad933c5f7a71a1bd73307e1691412e68e72c387a76b85c28adfbe9d5ad210c5af907dd4b34e2f9b32a7c6e6bba71d4ca6a5accd0e84ae SHA512 9786d74a7bbaae5961afc65f2084eb45c1566bb095fb0f7953d901638ba3675f63409c32d1aaaa850408debb75618d738cf30594f9c79a10b66524697805cf8e +DIST dbeaver-ce-24.3.4-linux.gtk.x86_64-nojdk.tar.gz 88986573 BLAKE2B b2c01856323f58e5e3454e3888c7532ac74252c77be887deae5cd4e28e58ff81c5dd65cdd95f2b2d095d7f63a09053c828cd9044ad0429fac84076d8785ddafa SHA512 0ae85fe8f3bdc7299b1b7ed069ee3aca7902e4302e750824b89ddf8a6211b763227f547546c9f5bb533e3f2ecee1955a475b1f64f62838b5675fdce07c7255fb +EBUILD dbeaver-bin-24.3.3.ebuild 1347 BLAKE2B 01478ada7aeded7d676cbf06adb46e916794c89d3bd870fb01393a62d35fbdb0570917030da9c840d77f231fae57b07cc9d464284e11f2cd07fbd12986a537d7 SHA512 5e1d108d48417cb3fda5e27be9c7e9b9c121ec1d36450c411994c59b73500bd4b2370f2a5316b90ead620334c5a8cf1ab494ad56bcb7c2026a681a80de7ae499 +EBUILD dbeaver-bin-24.3.4.ebuild 1347 BLAKE2B 01478ada7aeded7d676cbf06adb46e916794c89d3bd870fb01393a62d35fbdb0570917030da9c840d77f231fae57b07cc9d464284e11f2cd07fbd12986a537d7 SHA512 5e1d108d48417cb3fda5e27be9c7e9b9c121ec1d36450c411994c59b73500bd4b2370f2a5316b90ead620334c5a8cf1ab494ad56bcb7c2026a681a80de7ae499 MISC metadata.xml 444 BLAKE2B d614defd513043df0e48068edb26a12e87836aeb5147088e7d6133a7a1c0082ed2ba21019c0685a8a445f914e489e3dc6a1f26117ea9d186991bc7dd9f2db495 SHA512 731b4bc1af75124f7e1e78870c9f689acebf36960a741b1f4be24b5179de19b26fc982276bc115216c40d0789b048e6db900ad33e945ec2b94b471366f13db22 diff --git a/dev-db/dbeaver-bin/dbeaver-bin-24.3.2.ebuild b/dev-db/dbeaver-bin/dbeaver-bin-24.3.3.ebuild index 6884c8f5a48a..6884c8f5a48a 100644 --- a/dev-db/dbeaver-bin/dbeaver-bin-24.3.2.ebuild +++ b/dev-db/dbeaver-bin/dbeaver-bin-24.3.3.ebuild diff --git a/dev-db/dbeaver-bin/dbeaver-bin-24.3.4.ebuild b/dev-db/dbeaver-bin/dbeaver-bin-24.3.4.ebuild new file mode 100644 index 000000000000..6884c8f5a48a --- /dev/null +++ b/dev-db/dbeaver-bin/dbeaver-bin-24.3.4.ebuild @@ -0,0 +1,53 @@ +# Copyright 2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit desktop wrapper xdg + +MY_PN=${PN%-*} + +DESCRIPTION="Free universal database tool (community edition)" +HOMEPAGE="https://dbeaver.io/" +SRC_URI=" + amd64? ( https://dbeaver.io/files/${PV}/dbeaver-ce-${PV}-linux.gtk.x86_64-nojdk.tar.gz ) + arm64? ( https://dbeaver.io/files/${PV}/dbeaver-ce-${PV}-linux.gtk.aarch64-nojdk.tar.gz ) +" +S=${WORKDIR}/${MY_PN} + +LICENSE="Apache-2.0 EPL-1.0 BSD" +SLOT="0" +KEYWORDS="-* ~amd64 ~arm64" + +RDEPEND=">=virtual/jre-17:*" + +QA_PREBUILT=" + opt/${MY_PN}-ce.* +" + +src_prepare() { + sed -e "s/^Icon=.*/Icon=${MY_PN}/" \ + -e 's:/usr/share/dbeaver:/opt/dbeaver:g' \ + -e "s:^Exec=.*:Exec=${EPREFIX}/usr/bin/${MY_PN}:" \ + -i "${MY_PN}-ce.desktop" || die + default +} + +src_install() { + doicon -s 128 "${MY_PN}.png" + newicon icon.xpm "${MY_PN}.xpm" + domenu "${MY_PN}-ce.desktop" + + local DOCS=( readme.txt ) + einstalldocs + + # Remove unused plugins for other platforms + rm -rv plugins/com.sun.jna_5.15.0.v20240915-2000/com/sun/jna/{openbsd,dragonflybsd,freebsd,sunos,win32,darwin,aix}-* || die + + rm "${MY_PN}-ce.desktop" "${MY_PN}.png" icon.xpm readme.txt || die + insinto "/opt/${MY_PN}-ce" + doins -r ./* + fperms 755 "/opt/${MY_PN}-ce/${MY_PN}" + + make_wrapper "${MY_PN}" "/opt/${MY_PN}-ce/${MY_PN}" "/opt/${MY_PN}-ce" +} diff --git a/dev-db/etcd/Manifest b/dev-db/etcd/Manifest index 1dab700823cc..2d93f106671c 100644 --- a/dev-db/etcd/Manifest +++ b/dev-db/etcd/Manifest @@ -12,8 +12,11 @@ DIST etcd-3.5.15-deps.tar.xz 5885840 BLAKE2B 378d8136da0ca3486433ee2d55f2d65e569 DIST etcd-3.5.15.tar.gz 4113649 BLAKE2B b65ae93875cefffc09ff0c61eda485abd3a32691b0b8bb2d957c109c2e43cb36d26a51c4d81b7dadb9e96452dfdbfb626dfc5a151678154339d7e08324c15efb SHA512 1b22376fcda4c182ea0388b97f3b5a6a2fd62f753c2f4c13d06c3b53e9b7fb8efb2b20177f1724a5775f5ecc13bfcaabe6b308d4ee205dea86f7311fbe3a2900 DIST etcd-3.5.17-deps.tar.xz 5651912 BLAKE2B bd5293b0e125082736b785534eb7fb4a7f32e4427419f1b298a5dcb9d07ced41b1435e9cd8db2a1c05f81318416436d2ad3f4a8f2815801e6973039a8a5ed716 SHA512 70b50559e2c3be40fadc2462087db8e773858c948cc5e7d9441845a70c6f6ded022b12a4f24b2959748825fbec0772e73694f907b3aec1b3e713ca9beefc1944 DIST etcd-3.5.17.tar.gz 4124391 BLAKE2B 9602c31369cfd5604ac7283307b712ffb5468e6264731a78d6a598752d533b18906d22d44aafe70027da217b85220376972b5305fad562f0a80704f30637381c SHA512 6d1cae12f7352c7075eeec2273e70870ac89d7e92c313e5cf2c2316b0c93813047f7412756712169faf48657efefec98062ba03853fcd11c8b08d4d587752291 +DIST etcd-3.5.18-deps.tar.xz 46453448 BLAKE2B 677370cb6d9064f8474adbfc5030b46f3367198cb8defc9242be00423c570f8c9bc5358d6dbe9d8cfee8e7797a2f8c93e7b4c8cbee4702c59287005cd7885fef SHA512 f1ed36d49f199fff4b0ee920870c3ac66dee0dcb5e92fa24a3861d841bdcfa99b210b292138116de9aafeec424c7663111f9bb0ad87910e1314031eb501f4aeb +DIST etcd-3.5.18.tar.gz 4128059 BLAKE2B 32f867170bf1195d019dcf562bff9104db00f6ccff6b91bf12a4c95a63a5d92dda6984437bed819240be7bd8d4e2b507904251f636e945c5847ef93e72f1dd63 SHA512 0d72c40d575997d70d9d4964e7ff4be75c77e13a40ea08fcc020fddc64dc420338f1853d5a51a2dbe3f4c2881ae196a7aa32565e4b41dbda77bc2b6ae2313104 EBUILD etcd-3.4.31.ebuild 2044 BLAKE2B 6e527a0a48a368426300a7b24f73651e56074260684ead38996a418e2cc51490a0ee5621cafc767bf426c385d44bf9be9cff3b296d75849c9d0c8d2fd2f9db2c SHA512 ad5b18908d458864acbaf9e4ac570b5dda321bec9f989549d25aaec3682e0819b086f015f12fd10ae69e4895466152610d74c0cd062cb37e9b99051e7ce1d429 EBUILD etcd-3.5.12.ebuild 2095 BLAKE2B c476ec700d5a1b1642dd364924302e63fe01d4cb52a7bb5f21e9e92f6e1545660c75d5a8f6f5e427b77d2594d6ee8ec4559c05104f7757ce515ff7b0bb441de0 SHA512 4575ff154dfcd068dcd39aa82c460f50fcbee8a8f51857d2b20b6ee46c18f9cefa0327eff770e28d91b00b11539e71fdd9ba8eeefd1278fc1b68c51bdd15e16d EBUILD etcd-3.5.15.ebuild 2188 BLAKE2B 1830c6d33dafe08816432fb509e28ece04c4ccff7ac41e4b246b89efeb4af9512fa792b404aecdb9baa346d83f85a4b2721d689f08232728d0ae536bf8e1f480 SHA512 fd8863e639c6b21e58c2d5a08b26d4bd8a5deb8609d1b1027ce417379654bd982e242db55f23f32b07f9bbd2eceed5d375ab2888af0b699926bf70f927ddc82a -EBUILD etcd-3.5.17.ebuild 2188 BLAKE2B da310b239a1982e2c25d05ec0a31ca1b351fa94893a417d21cdf74a838c1f37476d612cf0245779cc28ced2a09f16972e0ea2481b19cc94ed8ab505276458205 SHA512 52658452075d8e40a4a8d1d02059df6046a30f9ae8ad6800ba91320262a99af8cb2a9f5911ab50bec9c450eb4a0da18f047b142adb08a8f505ed3b33bccfef6e +EBUILD etcd-3.5.17.ebuild 2187 BLAKE2B a8574dc581e11de3393074ced4e891e75cb28d82945bd7967feb322bdd2df1a7bf66a3ca443657d837b798e3d977bad075dcd9d90da946bfaacc2581b3115cea SHA512 0fb7227e9231f10d21e7ac1d5fab89273ead6fd4cbae9231c2ff1caee939374ed2a8aebbb2262bb5a308472699ba6fa24c01bb2d8c9cdab0ab60c1984e190095 +EBUILD etcd-3.5.18.ebuild 2188 BLAKE2B f20f3fe1ab24b189b187beb0be39ebba44f36a3c423bdf6d82e281492353b246ceeb1d35f369eb4f36547584ccf7940991f5b03b9710a5de95ce55a5ae94bc78 SHA512 d2ba4b2b245b3af5234d63af9c98e9cb8e2a721fcea1b7e4b278d344a0bc5c50bf11de6e5ea84ad1494b1df81a19ed0f3845f0a2e4778d134c686c7686cf6306 MISC metadata.xml 421 BLAKE2B 5498a48643720f59f55d3b37d21fa80a4d8c984e7dc0e9beaccdb4f08d53819025e5849e481a7ce14fc519de15fdbed622f3c3912335cf81a678c522ba367b32 SHA512 ed8b5d3b552fdc284301ed63b941c2ce87cc808718dc15191597932d6543606907a175c929416f51193c63e12d79fef7993d0f91d9d0f70aacf75447c3744b73 diff --git a/dev-db/etcd/etcd-3.5.17.ebuild b/dev-db/etcd/etcd-3.5.17.ebuild index 2843adb5c129..7b30921ef4e9 100644 --- a/dev-db/etcd/etcd-3.5.17.ebuild +++ b/dev-db/etcd/etcd-3.5.17.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -13,7 +13,7 @@ SRC_URI+=" https://dev.gentoo.org/~zmedico/dist/${P}-deps.tar.xz" LICENSE="Apache-2.0" LICENSE+=" BSD BSD-2 MIT" SLOT="0" -KEYWORDS="~amd64 ~loong ~riscv" +KEYWORDS="amd64 ~loong ~riscv" IUSE="doc +server" COMMON_DEPEND="server? ( diff --git a/dev-db/etcd/etcd-3.5.18.ebuild b/dev-db/etcd/etcd-3.5.18.ebuild new file mode 100644 index 000000000000..86439836af48 --- /dev/null +++ b/dev-db/etcd/etcd-3.5.18.ebuild @@ -0,0 +1,80 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit go-module systemd tmpfiles +GIT_COMMIT=5bca08ec1 + +DESCRIPTION="Highly-available key value store for shared configuration and service discovery" +HOMEPAGE="https://github.com/etcd-io/etcd" +SRC_URI="https://github.com/etcd-io/etcd/archive/v${PV}.tar.gz -> ${P}.tar.gz" +SRC_URI+=" https://dev.gentoo.org/~zmedico/dist/${P}-deps.tar.xz" + +LICENSE="Apache-2.0" +LICENSE+=" BSD BSD-2 MIT" +SLOT="0" +KEYWORDS="~amd64 ~loong ~riscv" +IUSE="doc +server" + +COMMON_DEPEND="server? ( + acct-group/etcd + acct-user/etcd + )" +DEPEND="${COMMON_DEPEND}" +RDEPEND="${COMMON_DEPEND}" + +# Unit tests attempt to download go modules. +RESTRICT="test" + +src_prepare() { + export FORCE_HOST_GO=1 GO_BUILD_FLAGS="-v -x" + default + sed -e "s|GIT_SHA=.*|GIT_SHA=${GIT_COMMIT}|" \ + -i "${S}"/build.sh || die + sed -e 's:\(for p in \)shellcheck :\1 :' \ + -e 's:^ goword \\$:\\:' \ + -e 's:^ gofmt \\$:\\:' \ + -e 's:^ govet \\$:\\:' \ + -e 's:^ revive \\$:\\:' \ + -e 's:^ mod_tidy \\$:\\:' \ + -e "s|GO_BUILD_FLAGS=\"[^\"]*\"|GO_BUILD_FLAGS=\"${GO_BUILD_FLAGS}\"|" \ + -e "s|go test |go test ${GO_BUILD_FLAGS} |" \ + -e 's|PASSES=${PASSES:-"fmt bom dep build unit"}|PASSES=${PASSES:-"fmt dep unit"}|' \ + -i ./test.sh || die +} + +src_compile() { + ./build.sh || die +} + +src_test() { + ./test || die +} + +src_install() { + dobin bin/etcdctl + use doc && dodoc -r Documentation + if use server; then + insinto /etc/${PN} + sed -e 's|^data-dir:|\0 /var/lib/etcd|' -i etcd.conf.yml.sample || die + newins etcd.conf.yml.sample etcd.conf.yml + dobin bin/etcd + dodoc README.md + systemd_newunit "${FILESDIR}/${PN}.service-r1" "${PN}.service" + newtmpfiles "${FILESDIR}/${PN}.tmpfiles.d.conf" ${PN}.conf + newinitd "${FILESDIR}"/${PN}.initd-r1 ${PN} + newconfd "${FILESDIR}"/${PN}.confd-r1 ${PN} + insinto /etc/logrotate.d + newins "${FILESDIR}/${PN}.logrotated" "${PN}" + keepdir /var/lib/${PN} /var/log/${PN} + fowners ${PN}:${PN} /var/lib/${PN} /var/log/${PN} + fperms 0700 /var/lib/${PN} + fperms 0755 /var/log/${PN} + fi +} + +pkg_postinst() { + if use server; then + tmpfiles_process ${PN}.conf + fi +} diff --git a/dev-db/freetds/Manifest b/dev-db/freetds/Manifest index 7b35b86fa956..ba7f400610e2 100644 --- a/dev-db/freetds/Manifest +++ b/dev-db/freetds/Manifest @@ -3,5 +3,5 @@ DIST freetds-1.4.23.tar.bz2 2402595 BLAKE2B aca65226d09ff95094c79330f10d19a5e833 DIST freetds-1.4.24.tar.bz2 2402973 BLAKE2B ba6f31fe117c11abc0e0365bf0d10061e793bb9313774a5e2d9b6766fef54abbec6c1c27480a875438008a592f6ab9942bd41a19a4dd7388ca3c2728bf1b2a65 SHA512 f564c81abaec28a6c55476121fff47e8957af654197ed679cfebdbeaa4dfe5d0f9d5f900cd03b4260efc3da3f9cd41ee370fadb6b59da9f41d9006760e9609d9 EBUILD freetds-1.4.17.ebuild 1443 BLAKE2B 50839c8c282f5dd4a1f6464d62ff594a37ca58523b40dc959c770808166be50eb6260c05c0a3f595eb840ab9330e74a3408a1bd4d89fc4f0e67b6f4a1e7ef059 SHA512 c381099fcf8decf905eb5922f7ec9bba6e8cc2d240bc6d8bdd1b30b5d76b0e76c17d9d71b386336a28f7b52b7f1dbdc9acb65b285ad1aad58f00044d8edd1120 EBUILD freetds-1.4.23.ebuild 1716 BLAKE2B 2523ac3919aad8090761937e0a49f21d6b0def7582a30a3978d00a1737340ab76c0164e7d4e33056083957fe0607ba108acdfe0c55ebe42d7ccebbebaca5b32c SHA512 c23816f7be243364aefea7061a01811d185dd7f3ed554284447335f95b8678d0a5e000f1aca29ee998527952f5174b8ab60e9b9a8eb7a833d95d59149a1acc01 -EBUILD freetds-1.4.24.ebuild 1716 BLAKE2B 2523ac3919aad8090761937e0a49f21d6b0def7582a30a3978d00a1737340ab76c0164e7d4e33056083957fe0607ba108acdfe0c55ebe42d7ccebbebaca5b32c SHA512 c23816f7be243364aefea7061a01811d185dd7f3ed554284447335f95b8678d0a5e000f1aca29ee998527952f5174b8ab60e9b9a8eb7a833d95d59149a1acc01 +EBUILD freetds-1.4.24.ebuild 1709 BLAKE2B 7d65d043aabf8a279078fb9289dce007be1e24f11135d10dc36b32de1b0252dcc2e649c7813d890e0405bedb309eabd26e17f00cd33c4b9580eb3b4227cc8ea4 SHA512 b32a2f90814bb85a0560ef6b978a07d1c84848b6814615288d6cf233e14bacbdbaf02745d66020ca0aef4d48178efc92640538eac669639eacd15041b32fb5bc MISC metadata.xml 307 BLAKE2B ef2023a0b7e091f47fa6e6e8c225a905e7456cbcccedaab86c3c9aa237eeaf87e5cafed83650a6ca569b3cc70bcd14ad0badabd0e4bd1739b619dbd3c3877de4 SHA512 e5489d7a456f904586f31a9c1e4b51a83d6db0ad27a7964df0ddf5a2cf75d3ba1e22fd2765d25540987e35932005968aa321dee761b64550dab27620ab9be3d7 diff --git a/dev-db/freetds/freetds-1.4.24.ebuild b/dev-db/freetds/freetds-1.4.24.ebuild index 28268059925d..e6b7b539a4e2 100644 --- a/dev-db/freetds/freetds-1.4.24.ebuild +++ b/dev-db/freetds/freetds-1.4.24.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -9,7 +9,7 @@ SRC_URI="https://www.freetds.org/files/stable/${P}.tar.bz2" LICENSE="GPL-2" SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~ppc-macos" +KEYWORDS="~alpha amd64 arm arm64 ~hppa ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~ppc-macos" IUSE="debug gnutls iconv kerberos mssql iodbc odbc ssl static-libs" # iODBC and unixODBC are mutually-exclusive choices for # the ODBC driver manager. Future versions of FreeTDS diff --git a/dev-db/litecli/Manifest b/dev-db/litecli/Manifest index 67b48939d896..6027c8b38c44 100644 --- a/dev-db/litecli/Manifest +++ b/dev-db/litecli/Manifest @@ -1,5 +1,5 @@ DIST litecli-1.12.3.gh.tar.gz 884895 BLAKE2B eb4aeb8e268ae5d878aee960be68d86085ee87a1089d2f80e1f7be01c31b030ce12432656452867efc9a5b915b1c15ae69d1ab9b461a16586a1d76e001e4d51a SHA512 2b9dda031984d142a9341b19446d2cca366be98058ff57874e66fc60ee936b27f0b2900d7b00dffed058fd985028236148594372dac6a0010894d0502d7db04a DIST litecli-1.13.2.tar.gz 888874 BLAKE2B 88880027a9f6b30ce266c3e2989379121229a6332e9841822876c7ae76560f6b5b758cea2e7fac1b8355c1070e33f48fa6d18da329724474eb508fb9687535f1 SHA512 c1134e86d60390f70553984cc6c4bf166879c08f225da8162ea0c27e579b65051cb4bbc51be5894967f09bef807d1c721e6d3550ecfe2a25c7f73eb226373e73 EBUILD litecli-1.12.3.ebuild 934 BLAKE2B e9714145a29e3e0f83b5362a46434f996a670affa564246a8d3bbc1dc979c42db1b7c872bef61063c1bb57c29bc92cd599989366356c7d48cc910164c8f55824 SHA512 d426940c7c7d598b77c1321fa39401cc79bcbf2bf5b4acc9ca7d5cc5b119026e401030d5ec72e4ffe9aa01d0937a84684c3ac8c6166859bc3cf1c4109276a2df -EBUILD litecli-1.13.2.ebuild 939 BLAKE2B d92ebdd689de5e0714bd5a4d46b585c30dd47b5008097e4d9a36a95e0769e81973ea2745a82b9353b745fec18985034ce98a0f9c9694c9f4a764ebacb54d1a89 SHA512 4ed25ae07a20d76ac2518af67201ac9f18baee418c9a9f7cc2f56ea84734fb14eef6b88ea7d4a8fbd8ad4947af2429d0389a09a3b8e29a2ef2b377cb81202dc6 +EBUILD litecli-1.13.2.ebuild 937 BLAKE2B 509c095207acb63b2e99edd7b47f34fe9be8df1349450310267fbcfba557f224b35a4b7e03564d9b49ef4771011dbfeba9026a6f4b8dc67b00dd01a4d170f6be SHA512 22d103a2587909eb21cb59a5026e443915d6e161faba608ac6779bead147f15fd7b47d7360fd4678e050dc675253717f667076fa65f1f47b2b82cf9614f171de MISC metadata.xml 558 BLAKE2B d0cc893d86444b930e255201d88d240ff83d534ffd502065bac82633b1575b175a430b795cc7cec00c31cbea33880f452b379361b5ea5abddd5ee386a12ee17b SHA512 44172f757590bb2c27a00b8d919c3f994f7f28b88c08ecc0b3d63d145fc5e773656b762a3997f512d61e1563826a62a87f9eaa2107063db422e3f100347e912b diff --git a/dev-db/litecli/litecli-1.13.2.ebuild b/dev-db/litecli/litecli-1.13.2.ebuild index 41fd76e48ff5..ebd7f3787d5f 100644 --- a/dev-db/litecli/litecli-1.13.2.ebuild +++ b/dev-db/litecli/litecli-1.13.2.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -14,7 +14,7 @@ HOMEPAGE="https://litecli.com/ https://github.com/dbcli/litecli" LICENSE="BSD" SLOT="0" -KEYWORDS="~amd64 ~x86" +KEYWORDS="amd64 x86" RDEPEND=" >=dev-python/click-4.1[${PYTHON_USEDEP}] diff --git a/dev-db/mariadb/Manifest b/dev-db/mariadb/Manifest index 0bf583bc4a94..392caa7c795a 100644 --- a/dev-db/mariadb/Manifest +++ b/dev-db/mariadb/Manifest @@ -7,17 +7,21 @@ AUX my.cnf.distro-client 643 BLAKE2B 5ffd286907ee28c92c85bbcc9a6266555733f1115f2 AUX my.cnf.distro-server 998 BLAKE2B a7f2977a96d394cb7e24d72d82a1c21095c4b55607e5ca4a2c10619278796c328931a5ec076c15b60afef370c2e5da02ca0c628f330e876b4d2c984eeb54df5f SHA512 d9ab6f7fdfe08e6c242f84410ec680ef6aa6778c4bd55fee67c644e1a7d997446d8ef2129be6fc9833d16fe40cf17e09cdf0cf015f06bb145bbf9cfecb51e882 DIST mariadb-10.11.10-patches-01.tar.xz 5300 BLAKE2B 842dd7002220ab6c164e50adcb2c0184752c1080e4c2c2609c431d8867b2ccf5b910b61d3f9a5f1e9b979d34423a5dbab1c3bced1e5d8b2af780addc9baddff5 SHA512 23a8e6d58927cadd39c84653069880039c4cbe6226d920550f3abdd995c0656013fef994cf4d23d34902c3cce7aa92a2819d5ef7f7c23ee9eca8a2720f4f6afa DIST mariadb-10.11.10.tar.gz 104463642 BLAKE2B c6101ea5094c5bb78cf55ba37026d2e18f48e59a54eef1849051acc2c64111b82b9eba73b909fe0f07d111521433b42d84f6d155bcdf6e4ed50c186767b078db SHA512 3a8655384813ba515ce185e8a03427785fbea75b3226e2a1db02839dd66c22622ba27eeb2ca7b3d840bba43720a4393bbf71eb4b2b9e41ab837629e89a8b5976 +DIST mariadb-10.11.11.tar.gz 105754084 BLAKE2B d722867840e01faeff3a4d7b3cb8f18bec45c4cf1dc75b207c3068a943b7db3b6d956cd04b4d878658f4e3d721dd1e2c7429a9a2c10689b7ff602f33d18a929a SHA512 d9c154207a9f435ce08d5fbfe31814a739e577c656ef9996cf7e60c2cad8b4c07e2de8d94b6191fefa2b5cbde56437b586f85f144d3b4fcec8533449ed8411ac DIST mariadb-10.6.13-patches-01.tar.xz 4984 BLAKE2B 625d04310b02aad4fec4b633e9fab06636364f3c5ed3cb88e89acd4224786c3c9ed478b636ac699e77a888b73dab12cb279df41d6095e93e9c4ae3a159570286 SHA512 1e6ac167bfd77570e8ff5955aaa9a101d9387ac4857d856f1fb8c9a489c4c2a154481b9385584435e8dc95baef0dd3ef6831c7de2d6f004401cc338edcaa9d12 DIST mariadb-10.6.15.tar.gz 98204031 BLAKE2B 4534b82f1c1e16ce2c7c21879714e24b20fada36ef10a8a0dbe770c1d99055822fcaf146646b19b459cfd948bff0662d23f1f661a843919f90a354838bda7ee6 SHA512 61b5af8c2f8bd2f641aaa708941563d5f6ecc118acc9a154c009c3ae1d50e7360ae59241f87e5c2111775a3ffeb42a64f4853e9c7096b58d68a3695b5d0ef97c DIST mariadb-10.6.16-patches-01.tar.xz 4956 BLAKE2B a178930f7abe474e1419509c0bbabf783e1b931cfc3f4b4bddf426d9671d4e69e62a800d759f424f957562091c634049e594332ab15dc758e98d26c48ba69d1d SHA512 42969e6881cf2548c48fcce7f8439c9d56596ef038d55affcada45f4cd42a3666617f5786b69fe9ba42f11b06e85f43b722f2190aa7ed5badb461c48282751e5 DIST mariadb-10.6.17.tar.gz 99067793 BLAKE2B 9df7592eb11a92fc4cbf4f1913e11f7ae652effde44358ee930726473a40fc26e46e02dc79e8b16068df37c82afe6b3141305624174d2e44c53107065c57b1ee SHA512 e07cf3e90d93d6139969875b11d6df3210b2c9f69257688b392843a7caed0dc3b75ba8904384fd0a55c24ece624e04b68c005a3731ee68f3957787a27b52ad56 DIST mariadb-10.6.20-patches-01.tar.xz 5304 BLAKE2B dd038f4f60e9410965111fd912b5c59ad9bfb32e1a5be96279bcae77716c1a190d69c7bb56427e4e432cd544826377dae6703323515ea5d3632f9d65fd553965 SHA512 f8b492af00ae9ee968bc5bc294739570dc915c98d43eb23970f2a2686b4a8d0e3fa8728f230b01c58743845916e43cde3345ca2bea6a2fa307e4b5b49c58e5c9 DIST mariadb-10.6.20.tar.gz 102697156 BLAKE2B 8bd665406c3462890a783276f4946c92d8824f9b134ffc912908b8404c83aad2342f86391ff1a827420e0dc7221adfa0203eb76fceb1cd3dffc53acc421242cc SHA512 de5465551fa837b6834b8435a5f04f894c2c2d5d0fdb7a05373728e166755a384f19cebd4e87910240929d3657d361b3943616246b4fcf0d97cf706e317ece96 -DIST mariadb-11.4.4-patches-01.tar.xz 5300 BLAKE2B dbebe4e5068c8ce56dc11527e37aea16727723d7ac9351865e8761e95209900ca50782ab2ce44fd86ad2e70f59b6ffa9c0758f158c48870e343ce37bca37b9fb SHA512 af51163404c699e7580ffd1fa931f86dafa7e6471641ba40f7072a04b6f1f4df0e89cc89926be6062810d18c55b97e3c696367ae483fbabab0227e69d7866f99 -DIST mariadb-11.4.4.tar.gz 111017581 BLAKE2B 0680c7d0a93b60dc02bd5cba49fcc050245606edc6a14aead7995b5f4baa15d731b857d5f1ca4bec2febd1b0a0062c5162ff9a8231397a40c9a740db4e5264d0 SHA512 dfa4c137d67c11c997bf67bceb27d072c51831f35e2ad438fe2f234cb530eb74e3283429aef620036db06943d7309dec36a4d015f578fd2a1f933637681841fb +DIST mariadb-10.6.21.tar.gz 103982296 BLAKE2B 3ee32c333fcdf4f5514745095c9f168c94355c07e3388f9300f441ded4dfc97dc9f6b9b1c7958f78236614e11f73989c725cc19b3bd71d008a32dcbb9f639362 SHA512 fe74a6fbf409723d69b35481a57d00fb04a2c560ad503ae50ff7b9d41b650dda32fe997c50303428e79a546e5c7fe91872fe3436cc3b7323f13a7138e04f5a53 +DIST mariadb-11.4.5-patches-01.tar.xz 5712 BLAKE2B d155c2314908e14e2df3edb6b9410b62949d6562425c4f719b145553272e4b367c9a8503a63931c19ef0bfd6726685856dd78cd59672d489b70e460f00548ef9 SHA512 98381019ed4ad41bb52cb40842db8c6bd464d4b506926165aacd74a7c298cc819a6b4d5e6ab5750780bd273486118dfe6e8879d036537d996673431197d5d429 +DIST mariadb-11.4.5.tar.gz 112382453 BLAKE2B c6678b4ff0d087d73602956d345a222bbb8c27752fd9d6e0cf7edc77e02abfccfd3a5685158d61d3faeebd6830b546eeec8a23aee8d44d969a232c0a233ea2a1 SHA512 65b74e5443c2b7e8bc6a4c2a22838e3440bdbfef9c8fa6ed2b142e3ed0121d77a049c1054b05859ff8232386894ae0e7429d1a646ecf503e9c01c4952c83c51a EBUILD mariadb-10.11.10.ebuild 42933 BLAKE2B 65fd393487e0a401e22a215cfd5846b2fda891a168c0bcdb2b2c53bee9acca7325e13262ad30242be2c4f06da52445bcb3d99b7b0387bbf8f7d5c449dcb6dfa6 SHA512 069b9f5f0ce373868fa86735a3619c795167e7aff660648d270f38dc607c7d6006466e24282c05d985c0f4f5486e18706d9f028ac6ee01bb5de208acc13d0746 +EBUILD mariadb-10.11.11.ebuild 42943 BLAKE2B 46e5c678d4e30d91a96179cceb829622324259f37fe21084fd156525d8efa206e2d4e0d941dfc44855ca1eccdec5d7d1ec4b02372cf0314f5e6f79e9dc802509 SHA512 e3f20a79594e0bdb33decbb42e1d71ff8c8d5042a85492445ddcab2c7dcfd3ef07ea0af916efe40d1bac7ae8fc5e2fa198c4bd4f844457fdfedaeb1533f005b6 EBUILD mariadb-10.6.15.ebuild 42828 BLAKE2B 3d02a9a306819fee4d70481d97f8d2ae246864477a54a71199e69419f26e09ed20c7c3d7805940784c5d5e277d49c7b27b38211c001167b496324f6aec37681c SHA512 7ff2877e1254c86190595ac6283f1a2b37f63eb37c579fe53b1eb05e51a7ea1f8dae9444e31964bb7b0caee03524d74f5bb3d03aebe6ea4ea222bd82f781ec64 EBUILD mariadb-10.6.17.ebuild 42881 BLAKE2B 1aa3df34c120f431a6713ee196310f4fff3357a9309ea2f70bbfeb5e03eb25e15941c1cd6501ac91222f28c71b2f5f8eda3a989e74d4496552648a4d967a330d SHA512 9287cce1af28095569a5fe8464fbd2585b045b537d19df86fe96183ef72bce3282a74f315af49c6fc49f4f3674a24652f433c0091c7f2440bc65d8a09e72188e EBUILD mariadb-10.6.20.ebuild 42758 BLAKE2B 0594e11bdae6fe1417253d099ed2ddd5a6f9c8303b203950a2f027bcde8a092ef3e1715cf37d6cabf97a72a23ee92031bef26eeabef28b4f431a2dd0c4d005d1 SHA512 2fc023f42a4c2d40d4ae64af31515a656d4a8b0c20a9f2be3dcfae5630984747a216f6e748eb0548a36557adf9c8ec14c80699e908dc261e8c721d7da7f0ece4 -EBUILD mariadb-11.4.4.ebuild 42928 BLAKE2B e201fadfeaad71c0798a533c505f2caf63fb7a066d862bcf2747c0b132f4705af6d7fa76283099e470d21afa6404dff7522a42555e74cc6689f86a4bfac9a145 SHA512 9f22b43a551f7f30c00702e9bc59b4d1bd0bf25c5a33e5ef2eee155521fd72a844873bd07ae6407b44dce8fb1c99f68196c7e8e7cb99693654ea90cbaceeae39 +EBUILD mariadb-10.6.21.ebuild 42767 BLAKE2B 99aa8b259cd94bc236721160163055a61eebd9dfeb10c7aa9a23ec5d0e7fef6424b7f8d6f37a001e3fb38862c568df10b039fd57b02a86e7286cb5e07469b282 SHA512 cf50a30b86966a7806d8f45ff78054a1a7c6a967f0d20a89465a31205adfc10a2c7c12ab504a59d3ce4b4dbae43cd39c0303aa4f9f7b86dee4f9428af34b1f55 +EBUILD mariadb-11.4.5.ebuild 43007 BLAKE2B 15201b5f3d425e5a9413d2e85e0aeb753d6bd56fad7738eca972fd8a4d364a12503a3303131e574b414008cd7cb89699a037fff7274191439caae24d245f85d0 SHA512 d805ccca375ddcff9bdaedab828b45092b8db0133e057a628cbd2e271cc1b30c03ad357c8138bf2cb65fdb9428e13b0a22c81d06b3d115750774b0ee259fb565 MISC metadata.xml 2415 BLAKE2B 15e491cb0881203b21f66652af9e420582e3992a610bde08dfae2d076c417b298529eafd659adaa4cdeecd70b0c10c83796f8dfd8fbdede7489c48fdd2bdb015 SHA512 ecc641157ada5ad6d84b534b6a40e27e59ef428668d61f3908817735d31d4828dd0327343bf4ad13a5f6a1bc306cc46137388489176c3116f2a0e0946471b49b diff --git a/dev-db/mariadb/mariadb-11.4.4.ebuild b/dev-db/mariadb/mariadb-10.11.11.ebuild index 70b4bbbc8a0a..24e67f7a73e6 100644 --- a/dev-db/mariadb/mariadb-11.4.4.ebuild +++ b/dev-db/mariadb/mariadb-10.11.11.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -13,7 +13,7 @@ DESCRIPTION="An enhanced, drop-in replacement for MySQL" HOMEPAGE="https://mariadb.org/" SRC_URI=" mirror://mariadb/${P}/source/${P}.tar.gz - https://dev.gentoo.org/~arkamar/distfiles/${P}-patches-01.tar.xz + https://dev.gentoo.org/~arkamar/distfiles/${PN}-10.11.10-patches-01.tar.xz " # Shorten the path because the socket path length must be shorter than 107 chars # and we will run a mysql server during test phase @@ -21,7 +21,7 @@ S="${WORKDIR}/mysql" LICENSE="GPL-2 LGPL-2.1+" SLOT="$(ver_cut 1-2)/${SUBSLOT:-0}" -#KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~riscv ~x86" +KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86" IUSE="+backup bindist columnstore cracklib debug extraengine galera innodb-lz4 innodb-lzo innodb-snappy jdbc jemalloc kerberos latin1 mroonga numa odbc oqgraph pam +perl profiling rocksdb selinux +server sphinx @@ -116,11 +116,11 @@ RDEPEND="${COMMON_DEPEND} !dev-db/mariadb:10.8 !dev-db/mariadb:10.9 !dev-db/mariadb:10.10 - !dev-db/mariadb:10.11 !dev-db/mariadb:11.0 !dev-db/mariadb:11.1 !dev-db/mariadb:11.2 !dev-db/mariadb:11.3 + !dev-db/mariadb:11.4 selinux? ( sec-policy/selinux-mysql ) server? ( columnstore? ( dev-db/mariadb-connector-c ) diff --git a/dev-db/mariadb/mariadb-10.6.21.ebuild b/dev-db/mariadb/mariadb-10.6.21.ebuild new file mode 100644 index 000000000000..d5cad1321758 --- /dev/null +++ b/dev-db/mariadb/mariadb-10.6.21.ebuild @@ -0,0 +1,1339 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +SUBSLOT="18" + +JAVA_PKG_OPT_USE="jdbc" + +inherit systemd flag-o-matic prefix toolchain-funcs \ + multiprocessing java-pkg-opt-2 cmake + +DESCRIPTION="An enhanced, drop-in replacement for MySQL" +HOMEPAGE="https://mariadb.org/" +SRC_URI=" + mirror://mariadb/${P}/source/${P}.tar.gz + https://dev.gentoo.org/~arkamar/distfiles/${PN}-10.6.20-patches-01.tar.xz +" +# Shorten the path because the socket path length must be shorter than 107 chars +# and we will run a mysql server during test phase +S="${WORKDIR}/mysql" + +LICENSE="GPL-2 LGPL-2.1+" +SLOT="$(ver_cut 1-2)/${SUBSLOT:-0}" +KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86" +IUSE="+backup bindist columnstore cracklib debug extraengine galera innodb-lz4 + innodb-lzo innodb-snappy jdbc jemalloc kerberos latin1 mroonga + numa odbc oqgraph pam +perl profiling rocksdb selinux +server sphinx + sst-rsync sst-mariabackup static systemd systemtap s3 tcmalloc + test xml yassl" + +RESTRICT="!bindist? ( bindist ) !test? ( test )" + +REQUIRED_USE="jdbc? ( extraengine server !static ) + ?? ( tcmalloc jemalloc ) + static? ( yassl !pam ) + test? ( extraengine )" + +# Be warned, *DEPEND are version-dependant +# These are used for both runtime and compiletime +COMMON_DEPEND=" + >=dev-libs/libpcre2-10.34:= + >=sys-apps/texinfo-4.7-r1 + sys-libs/ncurses:0= + >=sys-libs/zlib-1.2.3:0= + virtual/libcrypt:= + !bindist? ( + sys-libs/binutils-libs:0= + >=sys-libs/readline-4.1:0= + ) + jemalloc? ( dev-libs/jemalloc:0= ) + kerberos? ( virtual/krb5 ) + kernel_linux? ( + dev-libs/libaio:0= + sys-libs/liburing:= + sys-process/procps:0= + ) + server? ( + app-arch/bzip2 + app-arch/xz-utils + backup? ( app-arch/libarchive:0= ) + columnstore? ( + app-arch/snappy:= + dev-libs/boost:= + dev-libs/libxml2:2= + ) + cracklib? ( sys-libs/cracklib:0= ) + extraengine? ( + odbc? ( dev-db/unixODBC:0= ) + xml? ( dev-libs/libxml2:2= ) + ) + innodb-lz4? ( app-arch/lz4 ) + innodb-lzo? ( dev-libs/lzo ) + innodb-snappy? ( app-arch/snappy:= ) + mroonga? ( app-text/groonga-normalizer-mysql >=app-text/groonga-7.0.4 ) + numa? ( sys-process/numactl ) + oqgraph? ( + dev-libs/boost:= + dev-libs/judy:0= + ) + pam? ( sys-libs/pam:0= ) + s3? ( net-misc/curl ) + systemd? ( sys-apps/systemd:= ) + ) + systemtap? ( >=dev-debug/systemtap-1.3:0= ) + tcmalloc? ( dev-util/google-perftools:0= ) + yassl? ( net-libs/gnutls:0= ) + !yassl? ( + >=dev-libs/openssl-1.0.0:0= + ) +" +BDEPEND="app-alternatives/yacc" +DEPEND="${COMMON_DEPEND} + server? ( + extraengine? ( jdbc? ( >=virtual/jdk-1.8 ) ) + test? ( acct-group/mysql acct-user/mysql ) + ) + static? ( sys-libs/ncurses[static-libs] ) +" +RDEPEND="${COMMON_DEPEND} + !dev-db/mysql !dev-db/mariadb-galera !dev-db/percona-server !dev-db/mysql-cluster + !dev-db/mariadb:0 + !dev-db/mariadb:5.5 + !dev-db/mariadb:10.1 + !dev-db/mariadb:10.2 + !dev-db/mariadb:10.3 + !dev-db/mariadb:10.4 + !dev-db/mariadb:10.5 + !dev-db/mariadb:10.7 + !dev-db/mariadb:10.8 + !dev-db/mariadb:10.9 + !dev-db/mariadb:10.10 + !dev-db/mariadb:10.11 + !dev-db/mariadb:11.0 + !dev-db/mariadb:11.1 + !dev-db/mariadb:11.2 + !dev-db/mariadb:11.3 + !dev-db/mariadb:11.4 + !<virtual/mysql-5.6-r11 + !<virtual/libmysqlclient-18-r1 + selinux? ( sec-policy/selinux-mysql ) + server? ( + columnstore? ( dev-db/mariadb-connector-c ) + extraengine? ( jdbc? ( >=virtual/jre-1.8 ) ) + galera? ( + sys-apps/iproute2 + =sys-cluster/galera-26* + sst-rsync? ( sys-process/lsof ) + sst-mariabackup? ( net-misc/socat[ssl] ) + ) + !prefix? ( dev-db/mysql-init-scripts acct-group/mysql acct-user/mysql ) + ) +" +# For other stuff to bring us in +# dev-perl/DBD-MariaDB is needed by some scripts installed by MySQL +PDEPEND="perl? ( dev-perl/DBD-MariaDB )" + +QA_CONFIG_IMPL_DECL_SKIP=( + # These don't exist on Linux + pthread_threadid_np + getthrid +) + +mysql_init_vars() { + MY_SHAREDSTATEDIR=${MY_SHAREDSTATEDIR="${EPREFIX}/usr/share/mariadb"} + MY_SYSCONFDIR=${MY_SYSCONFDIR="${EPREFIX}/etc/mysql"} + MY_LOCALSTATEDIR=${MY_LOCALSTATEDIR="${EPREFIX}/var/lib/mysql"} + MY_LOGDIR=${MY_LOGDIR="${EPREFIX}/var/log/mysql"} + + if [[ -z "${MY_DATADIR}" ]] ; then + MY_DATADIR="" + if [[ -f "${MY_SYSCONFDIR}/my.cnf" ]] ; then + MY_DATADIR=$(my_print_defaults mysqld 2>/dev/null \ + | sed -ne '/datadir/s|^--datadir=||p' \ + | tail -n1) + if [[ -z "${MY_DATADIR}" ]] ; then + MY_DATADIR=$(grep ^datadir "${MY_SYSCONFDIR}/my.cnf" \ + | sed -e 's/.*=\s*//' \ + | tail -n1) + fi + fi + if [[ -z "${MY_DATADIR}" ]] ; then + MY_DATADIR="${MY_LOCALSTATEDIR}" + einfo "Using default MY_DATADIR" + fi + elog "MySQL MY_DATADIR is ${MY_DATADIR}" + + if [[ -z "${PREVIOUS_DATADIR}" ]] ; then + if [[ -e "${MY_DATADIR}" ]] ; then + # If you get this and you're wondering about it, see bug #207636 + elog "MySQL datadir found in ${MY_DATADIR}" + elog "A new one will not be created." + PREVIOUS_DATADIR="yes" + else + PREVIOUS_DATADIR="no" + fi + export PREVIOUS_DATADIR + fi + else + if [[ ${EBUILD_PHASE} == "config" ]]; then + local new_MY_DATADIR + new_MY_DATADIR=$(my_print_defaults mysqld 2>/dev/null \ + | sed -ne '/datadir/s|^--datadir=||p' \ + | tail -n1) + + if [[ ( -n "${new_MY_DATADIR}" ) && ( "${new_MY_DATADIR}" != "${MY_DATADIR}" ) ]]; then + ewarn "MySQL MY_DATADIR has changed" + ewarn "from ${MY_DATADIR}" + ewarn "to ${new_MY_DATADIR}" + MY_DATADIR="${new_MY_DATADIR}" + fi + fi + fi + + export MY_SHAREDSTATEDIR MY_SYSCONFDIR + export MY_LOCALSTATEDIR MY_LOGDIR + export MY_DATADIR +} + +pkg_setup() { + if [[ ${MERGE_TYPE} != binary ]] ; then + if has test ${FEATURES} ; then + # Bug #213475 - MySQL _will_ object strenuously if your machine is named + # localhost. Also causes weird failures. + [[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost" + + if ! has userpriv ${FEATURES} ; then + die "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root." + fi + fi + fi + + java-pkg-opt-2_pkg_setup +} + +src_unpack() { + unpack ${A} + + mv -f "${WORKDIR}/${P/_rc/}" "${S}" || die +} + +src_prepare() { + eapply "${WORKDIR}"/mariadb-patches + eapply "${FILESDIR}"/${PN}-10.6.11-gssapi.patch + eapply "${FILESDIR}"/${PN}-10.6.12-gcc-13.patch + + eapply_user + + _disable_plugin() { + echo > "${S}/plugin/${1}/CMakeLists.txt" || die + } + _disable_engine() { + echo > "${S}/storage/${1}/CMakeLists.txt" || die + } + + if use jemalloc; then + echo "TARGET_LINK_LIBRARIES(mariadbd LINK_PUBLIC jemalloc)" >> "${S}/sql/CMakeLists.txt" + elif use tcmalloc; then + echo "TARGET_LINK_LIBRARIES(mariadbd LINK_PUBLIC tcmalloc)" >> "${S}/sql/CMakeLists.txt" + fi + + local plugin + local server_plugins=( handler_socket auth_socket feedback metadata_lock_info + locale_info qc_info server_audit sql_errlog auth_ed25519 ) + local test_plugins=( audit_null auth_examples daemon_example fulltext + debug_key_management example_key_management versioning ) + if ! use server; then # These plugins are for the server + for plugin in "${server_plugins[@]}" ; do + _disable_plugin "${plugin}" + done + fi + + if ! use test; then # These plugins are only used during testing + for plugin in "${test_plugins[@]}" ; do + _disable_plugin "${plugin}" + done + _disable_engine test_sql_discovery + echo > "${S}/plugin/auth_pam/testing/CMakeLists.txt" || die + fi + + _disable_engine example + + if ! use oqgraph ; then # avoids extra library checks + _disable_engine oqgraph + fi + + if use mroonga ; then + # Remove the bundled groonga + # There is no CMake flag, it simply checks for existance + rm -r "${S}"/storage/mroonga/vendor/groonga || die "could not remove packaged groonga" + else + _disable_engine mroonga + fi + + # Fix static bindings in galera replication + sed -i -e 's~add_library(wsrep_api_v26$~add_library(wsrep_api_v26 STATIC~' \ + "${S}"/wsrep-lib/wsrep-API/CMakeLists.txt || die + sed -i -e 's~add_library(wsrep-lib$~add_library(wsrep-lib STATIC~' \ + "${S}"/wsrep-lib/src/CMakeLists.txt || die + + # Fix galera_recovery.sh script + sed -i -e "s~@bindir@/my_print_defaults~${EPREFIX}/usr/libexec/mariadb/my_print_defaults~" \ + scripts/galera_recovery.sh || die + + sed -i -e 's~ \$basedir/lib/\*/mariadb19/plugin~~' \ + "${S}"/scripts/mysql_install_db.sh || die + + cmake_src_prepare + java-pkg-opt-2_src_prepare +} + +src_configure() { + # bug #855233 (MDEV-11914, MDEV-25633) at least + filter-lto + # bug 508724 mariadb cannot use ld.gold + tc-ld-is-gold && tc-ld-force-bfd + # Bug #114895, bug #110149 + filter-flags "-O" "-O[01]" + + # It fails on alpha without this + use alpha && append-ldflags "-Wl,--no-relax" + + # bug #945352 + append-cflags -std=gnu17 + + append-cxxflags -felide-constructors + + # bug #283926, with GCC4.4, this is required to get correct behavior. + append-flags -fno-strict-aliasing + + CMAKE_BUILD_TYPE="RelWithDebInfo" + + # debug hack wrt #497532 + local mycmakeargs=( + -DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')" + -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')" + -DMYSQL_DATADIR="${EPREFIX}/var/lib/mysql" + -DSYSCONFDIR="${EPREFIX}/etc/mysql" + -DINSTALL_BINDIR=bin + -DINSTALL_DOCDIR=share/doc/${PF} + -DINSTALL_DOCREADMEDIR=share/doc/${PF} + -DINSTALL_INCLUDEDIR=include/mysql + -DINSTALL_INFODIR=share/info + -DINSTALL_LIBDIR=$(get_libdir) + -DINSTALL_MANDIR=share/man + -DINSTALL_MYSQLSHAREDIR=share/mariadb + -DINSTALL_PLUGINDIR=$(get_libdir)/mariadb/plugin + -DINSTALL_SCRIPTDIR=bin + -DINSTALL_MYSQLDATADIR="${EPREFIX}/var/lib/mysql" + -DINSTALL_SBINDIR=sbin + -DINSTALL_SUPPORTFILESDIR="${EPREFIX}/usr/share/mariadb" + -DWITH_COMMENT="Gentoo Linux ${PF}" + -DWITH_UNIT_TESTS=$(usex test ON OFF) + -DWITH_LIBEDIT=0 + -DWITH_ZLIB=system + -DWITHOUT_LIBWRAP=1 + -DENABLED_LOCAL_INFILE=1 + -DMYSQL_UNIX_ADDR="${EPREFIX}/var/run/mysqld/mysqld.sock" + -DINSTALL_UNIX_ADDRDIR="${EPREFIX}/var/run/mysqld/mysqld.sock" + -DWITH_DEFAULT_COMPILER_OPTIONS=0 + -DWITH_DEFAULT_FEATURE_SET=0 + -DINSTALL_SYSTEMD_UNITDIR="$(systemd_get_systemunitdir)" + # The build forces this to be defined when cross-compiling. We pass it + # all the time for simplicity and to make sure it is actually correct. + -DSTACK_DIRECTION=$(tc-stack-grows-down && echo -1 || echo 1) + -DPKG_CONFIG_EXECUTABLE="${EPREFIX}/usr/bin/$(tc-getPKG_CONFIG)" + -DPLUGIN_AUTH_GSSAPI=$(usex kerberos DYNAMIC NO) + -DAUTH_GSSAPI_PLUGIN_TYPE=$(usex kerberos DYNAMIC OFF) + -DCONC_WITH_EXTERNAL_ZLIB=YES + -DWITH_EXTERNAL_ZLIB=YES + -DSUFFIX_INSTALL_DIR="" + -DWITH_UNITTEST=OFF + -DWITHOUT_CLIENTLIBS=YES + -DCLIENT_PLUGIN_DIALOG=OFF + -DCLIENT_PLUGIN_AUTH_GSSAPI_CLIENT=OFF + -DCLIENT_PLUGIN_CLIENT_ED25519=OFF + -DCLIENT_PLUGIN_MYSQL_CLEAR_PASSWORD=STATIC + -DCLIENT_PLUGIN_CACHING_SHA2_PASSWORD=OFF + ) + if use test ; then + mycmakeargs+=( -DINSTALL_MYSQLTESTDIR=share/mariadb/mysql-test ) + else + mycmakeargs+=( -DINSTALL_MYSQLTESTDIR='' ) + fi + + if ! use yassl ; then + mycmakeargs+=( -DWITH_SSL=system -DCLIENT_PLUGIN_SHA256_PASSWORD=STATIC ) + else + mycmakeargs+=( -DWITH_SSL=bundled ) + fi + + # bfd.h is only used starting with 10.1 and can be controlled by NOT_FOR_DISTRIBUTION + mycmakeargs+=( + -DWITH_READLINE=$(usex bindist 1 0) + -DNOT_FOR_DISTRIBUTION=$(usex bindist 0 1) + -DENABLE_DTRACE=$(usex systemtap) + ) + + if use server ; then + # Connect and Federated{,X} must be treated special + # otherwise they will not be built as plugins + if ! use extraengine ; then + mycmakeargs+=( + -DPLUGIN_CONNECT=NO + -DPLUGIN_FEDERATED=NO + -DPLUGIN_FEDERATEDX=NO + ) + fi + + mycmakeargs+=( + -DWITH_PCRE=system + -DPLUGIN_OQGRAPH=$(usex oqgraph DYNAMIC NO) + -DPLUGIN_SPHINX=$(usex sphinx YES NO) + -DPLUGIN_AUTH_PAM=$(usex pam YES NO) + -DPLUGIN_AWS_KEY_MANAGEMENT=NO + -DPLUGIN_CRACKLIB_PASSWORD_CHECK=$(usex cracklib YES NO) + -DPLUGIN_SEQUENCE=$(usex extraengine YES NO) + -DPLUGIN_SPIDER=$(usex extraengine YES NO) + -DPLUGIN_S3=$(usex s3 YES NO) + -DPLUGIN_COLUMNSTORE=$(usex columnstore YES NO) + -DCONNECT_WITH_MYSQL=1 + -DCONNECT_WITH_LIBXML2=$(usex xml) + -DCONNECT_WITH_ODBC=$(usex odbc) + -DCONNECT_WITH_JDBC=$(usex jdbc) + # Build failure and autodep wrt bug 639144 + -DCONNECT_WITH_MONGO=OFF + -DWITH_WSREP=$(usex galera) + -DWITH_INNODB_LZ4=$(usex innodb-lz4 ON OFF) + -DWITH_INNODB_LZO=$(usex innodb-lzo ON OFF) + -DWITH_INNODB_SNAPPY=$(usex innodb-snappy ON OFF) + -DPLUGIN_MROONGA=$(usex mroonga DYNAMIC NO) + -DPLUGIN_AUTH_GSSAPI=$(usex kerberos DYNAMIC NO) + -DWITH_MARIABACKUP=$(usex backup ON OFF) + -DWITH_LIBARCHIVE=$(usex backup ON OFF) + -DINSTALL_SQLBENCHDIR="" + -DPLUGIN_ROCKSDB=$(usex rocksdb DYNAMIC NO) + # systemd is only linked to for server notification + -DWITH_SYSTEMD=$(usex systemd yes no) + -DWITH_NUMA=$(usex numa ON OFF) + ) + + if use test ; then + # This is needed for the new client lib which tests a real, open server + mycmakeargs+=( -DSKIP_TESTS=ON ) + fi + + if [[ ( -n ${MYSQL_DEFAULT_CHARSET} ) && ( -n ${MYSQL_DEFAULT_COLLATION} ) ]]; then + ewarn "You are using a custom charset of ${MYSQL_DEFAULT_CHARSET}" + ewarn "and a collation of ${MYSQL_DEFAULT_COLLATION}." + ewarn "You MUST file bugs without these variables set." + + mycmakeargs+=( + -DDEFAULT_CHARSET=${MYSQL_DEFAULT_CHARSET} + -DDEFAULT_COLLATION=${MYSQL_DEFAULT_COLLATION} + ) + + elif ! use latin1 ; then + mycmakeargs+=( + -DDEFAULT_CHARSET=utf8mb4 + -DDEFAULT_COLLATION=utf8mb4_unicode_520_ci + ) + else + mycmakeargs+=( + -DDEFAULT_CHARSET=latin1 + -DDEFAULT_COLLATION=latin1_swedish_ci + ) + fi + mycmakeargs+=( + -DEXTRA_CHARSETS=all + -DMYSQL_USER=mysql + -DDISABLE_SHARED=$(usex static YES NO) + -DWITH_DEBUG=$(usex debug) + -DWITH_EMBEDDED_SERVER=OFF + -DWITH_PROFILING=$(usex profiling) + ) + + if use static; then + mycmakeargs+=( -DWITH_PIC=1 ) + fi + + if use jemalloc || use tcmalloc ; then + mycmakeargs+=( -DWITH_SAFEMALLOC=OFF ) + fi + + # Storage engines + mycmakeargs+=( + -DWITH_ARCHIVE_STORAGE_ENGINE=1 + -DWITH_BLACKHOLE_STORAGE_ENGINE=1 + -DWITH_CSV_STORAGE_ENGINE=1 + -DWITH_HEAP_STORAGE_ENGINE=1 + -DWITH_INNOBASE_STORAGE_ENGINE=1 + -DWITH_MYISAMMRG_STORAGE_ENGINE=1 + -DWITH_MYISAM_STORAGE_ENGINE=1 + -DWITH_PARTITION_STORAGE_ENGINE=1 + ) + else + mycmakeargs+=( + -DWITHOUT_SERVER=1 + -DWITH_EMBEDDED_SERVER=OFF + -DEXTRA_CHARSETS=none + -DINSTALL_SQLBENCHDIR= + -DWITH_SYSTEMD=no + ) + fi + + cmake_src_configure +} + +src_compile() { + cmake_src_compile +} + +# Official test instructions: +# USE='extraengine perl server' \ +# FEATURES='test userpriv' \ +# ebuild mariadb-X.X.XX.ebuild \ +# digest clean package +src_test() { + _disable_test() { + local rawtestname bug reason + rawtestname="${1}" ; shift + bug="${1}" ; shift + reason="${@}" + ewarn "test '${rawtestname}' disabled: '${reason}' (BUG#${bug})" + echo "${rawtestname} : BUG#${bug} ${reason}" >> "${T}/disabled.def" + } + + local TESTDIR="${BUILD_DIR}/mysql-test" + local retstatus_tests + + if ! use server ; then + einfo "Skipping server tests due to minimal build." + return 0 + fi + + # Ensure that parallel runs don't die + export MTR_BUILD_THREAD="$((${RANDOM} % 100))" + + if [[ -z "${MTR_PARALLEL}" ]] ; then + local -x MTR_PARALLEL=$(makeopts_jobs) + + if [[ ${MTR_PARALLEL} -gt 4 ]] ; then + # Running multiple tests in parallel usually require higher ulimit + # and fs.aio-max-nr setting. In addition, tests like main.multi_update + # are known to hit timeout when system is busy. + # To avoid test failure we will limit MTR_PARALLEL to 4 instead of + # using "auto". + local info_msg="Parallel MySQL test suite jobs limited to 4 (MAKEOPTS=${MTR_PARALLEL})" + info_msg+=" to avoid test failures. Set MTR_PARALLEL if you know what you are doing!" + einfo "${info_msg}" + unset info_msg + MTR_PARALLEL=4 + fi + else + einfo "MTR_PARALLEL is set to '${MTR_PARALLEL}'" + fi + + # Try to increase file limits to increase test coverage + if ! ulimit -n 16500 1>/dev/null 2>&1 ; then + # Upper limit comes from parts.partition_* tests + ewarn "For maximum test coverage please raise open file limit to 16500 (ulimit -n 16500) before calling the package manager." + + if ! ulimit -n 4162 1>/dev/null 2>&1 ; then + # Medium limit comes from '[Warning] Buffered warning: Could not + # increase number of max_open_files to more than 3000 (request: 4162)' + ewarn "For medium test coverage please raise open file limit to 4162 (ulimit -n 4162) before calling the package manager." + + if ! ulimit -n 3000 1>/dev/null 2>&1 ; then + ewarn "For minimum test coverage please raise open file limit to 3000 (ulimit -n 3000) before calling the package manager." + else + einfo "Will run test suite with open file limit set to 3000 (minimum test coverage)." + fi + else + einfo "Will run test suite with open file limit set to 4162 (medium test coverage)." + fi + else + einfo "Will run test suite with open file limit set to 16500 (best test coverage)." + fi + + # create directories because mysqladmin might run out of order + mkdir -p "${T}"/var-tests{,/log} || die + + if [[ ! -f "${S}/mysql-test/unstable-tests" ]] ; then + touch "${S}"/mysql-test/unstable-tests || die + fi + + cp "${S}"/mysql-test/unstable-tests "${T}/disabled.def" || die + + local -a disabled_tests + disabled_tests+=( "compat/oracle.plugin;0;Needs example plugin which Gentoo disables" ) + disabled_tests+=( "innodb_gis.1;25095;Known rounding error with latest AMD processors" ) + disabled_tests+=( "innodb_gis.gis;25095;Known rounding error with latest AMD processors" ) + disabled_tests+=( "main.gis;25095;Known rounding error with latest AMD processors" ) + disabled_tests+=( "main.explain_non_select;0;Sporadically failing test" ) + disabled_tests+=( "main.func_time;0;Dependent on time test was written" ) + disabled_tests+=( "main.mysql_upgrade;27044;Sporadically failing test" ) + disabled_tests+=( "main.plugin_auth;0;Needs client libraries built" ) + disabled_tests+=( "main.selectivity_no_engine;26320;Sporadically failing test" ) + disabled_tests+=( "main.stat_tables;0;Sporadically failing test" ) + disabled_tests+=( "main.stat_tables_innodb;0;Sporadically failing test" ) + disabled_tests+=( "main.upgrade_MDEV-19650;25096;Known to be broken" ) + disabled_tests+=( "mariabackup.*;0;Broken test suite" ) + disabled_tests+=( "perfschema.nesting;23458;Known to be broken" ) + disabled_tests+=( "perfschema.prepared_statements;0;Broken test suite" ) + disabled_tests+=( "perfschema.privilege_table_io;27045;Sporadically failing test" ) + disabled_tests+=( "plugins.auth_ed25519;0;Needs client libraries built" ) + disabled_tests+=( "plugins.cracklib_password_check;0;False positive due to varying policies" ) + disabled_tests+=( "plugins.two_password_validations;0;False positive due to varying policies" ) + disabled_tests+=( "roles.acl_statistics;0;False positive due to a user count mismatch caused by previous test" ) + disabled_tests+=( "spider.*;0;Fails with network sandbox" ) + disabled_tests+=( "sys_vars.wsrep_on_without_provider;25625;Known to be broken" ) + + if ! use latin1 ; then + disabled_tests+=( "funcs_1.is_columns_mysql;0;Requires USE=latin1" ) + disabled_tests+=( "main.information_schema;0;Requires USE=latin1" ) + disabled_tests+=( "main.sp2;24177;Requires USE=latin1" ) + disabled_tests+=( "main.system_mysql_db;0;Requires USE=latin1" ) + disabled_tests+=( "main.upgrade_MDEV-19650;24178;Requires USE=latin1" ) + fi + + local test_infos_str test_infos_arr + for test_infos_str in "${disabled_tests[@]}" ; do + IFS=';' read -r -a test_infos_arr <<< "${test_infos_str}" + + if [[ ${#test_infos_arr[@]} != 3 ]] ; then + die "Invalid test data set, not matching format: ${test_infos_str}" + fi + + _disable_test "${test_infos_arr[0]}" "${test_infos_arr[1]}" "${test_infos_arr[2]}" + done + unset test_infos_str test_infos_arr + + # run mysql-test tests + pushd "${TESTDIR}" &>/dev/null || die + perl mysql-test-run.pl --force --vardir="${T}/var-tests" --reorder --skip-test-list="${T}/disabled.def" + retstatus_tests=$? + + popd &>/dev/null || die + + # Cleanup is important for these testcases. + pkill -9 -f "${S}/ndb" 2>/dev/null + pkill -9 -f "${S}/sql" 2>/dev/null + + local failures="" + [[ ${retstatus_tests} -eq 0 ]] || failures="${failures} tests" + + [[ -z "${failures}" ]] || die "Test failures: ${failures}" + einfo "Tests successfully completed" +} + +src_install() { + cmake_src_install + + # Remove an unnecessary, private config header which will never match between ABIs and is not meant to be used + if [[ -f "${ED}/usr/include/mysql/server/private/config.h" ]] ; then + rm "${ED}/usr/include/mysql/server/private/config.h" || die + fi + + # Make sure the vars are correctly initialized + mysql_init_vars + + # Convenience links + einfo "Making Convenience links for mysqlcheck multi-call binary" + dosym "mysqlcheck" "/usr/bin/mysqlanalyze" + dosym "mysqlcheck" "/usr/bin/mysqlrepair" + dosym "mysqlcheck" "/usr/bin/mysqloptimize" + + # INSTALL_LAYOUT=STANDALONE causes cmake to create a /usr/data dir + if [[ -d "${ED}/usr/data" ]] ; then + rm -Rf "${ED}/usr/data" || die + fi + + # Unless they explicitly specific USE=test, then do not install the + # testsuite. It DOES have a use to be installed, esp. when you want to do a + # validation of your database configuration after tuning it. + if ! use test ; then + rm -rf "${D}/${MY_SHAREDSTATEDIR}/mysql-test" + fi + + # Configuration stuff + einfo "Building default configuration ..." + insinto "${MY_SYSCONFDIR#${EPREFIX}}" + [[ -f "${S}/scripts/mysqlaccess.conf" ]] && doins "${S}"/scripts/mysqlaccess.conf + cp "${FILESDIR}/my.cnf-10.2" "${TMPDIR}/my.cnf" || die + eprefixify "${TMPDIR}/my.cnf" + doins "${TMPDIR}/my.cnf" + insinto "${MY_SYSCONFDIR#${EPREFIX}}/mariadb.d" + cp "${FILESDIR}/my.cnf.distro-client" "${TMPDIR}/50-distro-client.cnf" || die + eprefixify "${TMPDIR}/50-distro-client.cnf" + doins "${TMPDIR}/50-distro-client.cnf" + + if use server ; then + mycnf_src="my.cnf.distro-server" + sed -e "s!@DATADIR@!${MY_DATADIR}!g" \ + "${FILESDIR}/${mycnf_src}" \ + > "${TMPDIR}/my.cnf.ok" || die + if use prefix ; then + sed -i -r -e '/^user[[:space:]]*=[[:space:]]*mysql$/d' \ + "${TMPDIR}/my.cnf.ok" || die + fi + if use latin1 ; then + sed -i \ + -e "/character-set/s|utf8|latin1|g" \ + "${TMPDIR}/my.cnf.ok" || die + fi + eprefixify "${TMPDIR}/my.cnf.ok" + newins "${TMPDIR}/my.cnf.ok" 50-distro-server.cnf + + einfo "Including support files and sample configurations" + docinto "support-files" + local script + for script in \ + "${S}"/support-files/magic + do + [[ -f "$script" ]] && dodoc "${script}" + done + + docinto "scripts" + for script in "${S}"/scripts/mysql* ; do + [[ ( -f "$script" ) && ( "${script%.sh}" == "${script}" ) ]] && dodoc "${script}" + done + # Manually install supporting files that conflict with other packages + # but are needed for galera and initial installation + exeinto /usr/libexec/mariadb + doexe "${BUILD_DIR}/extra/my_print_defaults" "${BUILD_DIR}/extra/perror" + + if use pam ; then + keepdir /usr/$(get_libdir)/mariadb/plugin/auth_pam_tool_dir + fi + fi + + # Conflicting files + conflicting_files=() + + # We prefer my_print_defaults from dev-db/mysql-connector-c + conflicting_files=( "${ED}/usr/share/man/man1/my_print_defaults.1" ) + + # Remove bundled mytop in favor of dev-db/mytop + conflicting_files+=( "${ED}/usr/bin/mytop" ) + conflicting_files+=( "${ED}/usr/share/man/man1/mytop.1" ) + + local conflicting_file + for conflicting_file in "${conflicting_files[@]}" ; do + if [[ -e "${conflicting_file}" ]] ; then + rm -v "${conflicting_file}" || die + fi + done + + # Fix a dangling symlink when galera is not built + if [[ -L "${ED}/usr/bin/wsrep_sst_rsync_wan" ]] && ! use galera ; then + rm "${ED}/usr/bin/wsrep_sst_rsync_wan" || die + fi + + # Remove dangling symlink + rm "${ED}/usr/$(get_libdir)/libmariadb.a" || die + + # Remove broken SST scripts that are incompatible + local scriptremove + for scriptremove in wsrep_sst_xtrabackup wsrep_sst_xtrabackup-v2 ; do + if [[ -e "${ED}/usr/bin/${scriptremove}" ]] ; then + rm "${ED}/usr/bin/${scriptremove}" || die + fi + done +} + +pkg_preinst() { + java-pkg-opt-2_pkg_preinst +} + +pkg_postinst() { + # Make sure the vars are correctly initialized + mysql_init_vars + + # Create log directory securely if it does not exist + [[ -d "${ROOT}/${MY_LOGDIR}" ]] || install -d -m0750 -o mysql -g mysql "${ROOT}/${MY_LOGDIR}" + + if use server ; then + if use pam; then + einfo + elog "This install includes the PAM authentication plugin." + elog "To activate and configure the PAM plugin, please read:" + elog "https://mariadb.com/kb/en/mariadb/pam-authentication-plugin/" + einfo + chown mysql:mysql "${EROOT}/usr/$(get_libdir)/mariadb/plugin/auth_pam_tool_dir" || die + fi + + if [[ -z "${REPLACING_VERSIONS}" ]] ; then + einfo + elog "You might want to run:" + elog "\"emerge --config =${CATEGORY}/${PF}\"" + elog "if this is a new install." + elog + elog "If you are switching server implentations, you should run the" + elog "mysql_upgrade tool." + einfo + else + einfo + elog "If you are upgrading major versions, you should run the" + elog "mysql_upgrade tool." + einfo + fi + + if use galera ; then + einfo + elog "Be sure to edit the my.cnf file to activate your cluster settings." + elog "This should be done after running \"emerge --config =${CATEGORY}/${PF}\"" + elog "The first time the cluster is activated, you should add" + elog "--wsrep-new-cluster to the options in /etc/conf.d/mysql for one node." + elog "This option should then be removed for subsequent starts." + einfo + if [[ -n "${REPLACING_VERSIONS}" ]] ; then + local rver + for rver in ${REPLACING_VERSIONS} ; do + if ver_test "${rver}" -lt "10.4.0" ; then + ewarn "Upgrading galera from a previous version requires admin restart of the entire cluster." + ewarn "Please refer to https://mariadb.com/kb/en/library/changes-improvements-in-mariadb-104/#galera-4" + ewarn "for more information" + fi + done + fi + fi + fi + + # Note about configuration change + einfo + elog "This version of mariadb reorganizes the configuration from a single my.cnf" + elog "to several files in /etc/mysql/${PN}.d." + elog "Please backup any changes you made to /etc/mysql/my.cnf" + elog "and add them as a new file under /etc/mysql/${PN}.d with a .cnf extension." + elog "You may have as many files as needed and they are read alphabetically." + elog "Be sure the options have the appropriate section headers, i.e. [mysqld]." + einfo +} + +pkg_config() { + _getoptval() { + local section="${1}" + local option="--${2}" + local extra_options="${3}" + local cmd=( + "${my_print_defaults_binary}" + "${extra_options}" + "${section}" + ) + + local values=() + local parameters=( $(eval "${cmd[@]}" 2>/dev/null) ) + for parameter in "${parameters[@]}" + do + # my_print_defaults guarantees output of options, one per line, + # in the form that they would be specified on the command line. + # So checking for --option=* should be safe. + case ${parameter} in + ${option}=*) + values+=( "${parameter#*=}" ) + ;; + esac + done + + if [[ ${#values[@]} -gt 0 ]] ; then + # Option could have been set multiple times + # in which case only the last occurrence + # contains the current value + echo "${values[-1]}" + fi + } + + _mktemp_dry() { + # emktemp has no --dry-run option + local template="${1}" + + if [[ -z "${template}" ]] ; then + if [[ -z "${T}" ]] ; then + template="/tmp/XXXXXXX" + else + template="${T}/XXXXXXX" + fi + fi + + local template_wo_X=${template//X/} + local n_X + let n_X=${#template}-${#template_wo_X} + if [[ ${n_X} -lt 3 ]] ; then + echo "${FUNCNAME[0]}: too few X's in template '${template}'" >&2 + return + fi + + local attempts=0 + local character tmpfile + while [[ true ]] ; do + let attempts=attempts+1 + + new_file= + while read -n1 character ; do + if [[ "${character}" == "X" ]] ; then + tmpfile+="${RANDOM:0:1}" + else + tmpfile+="${character}" + fi + done < <(echo -n "${template}") + + if [[ ! -f "${tmpfile}" ]] + then + echo "${tmpfile}" + return + fi + + if [[ ${attempts} -ge 100 ]] ; then + echo "${FUNCNAME[0]}: Cannot create temporary file after 100 attempts." >&2 + return + fi + done + } + + local mysql_binary="${EROOT}/usr/bin/mysql" + if [[ ! -x "${mysql_binary}" ]] ; then + die "'${mysql_binary}' not found! Please re-install ${CATEGORY}/${PN}!" + fi + + local mysqld_binary="${EROOT}/usr/sbin/mysqld" + if [[ ! -x "${mysqld_binary}" ]] ; then + die "'${mysqld_binary}' not found! Please re-install ${CATEGORY}/${PN}!" + fi + + local mysql_install_db_binary="${EROOT}/usr/bin/mysql_install_db" + if [[ ! -x "${mysql_install_db_binary}" ]] ; then + die "'${mysql_install_db_binary}' not found! Please re-install ${CATEGORY}/${PN}!" + fi + + local my_print_defaults_binary="${EROOT}/usr/bin/my_print_defaults" + if [[ ! -x "${my_print_defaults_binary}" ]] ; then + die "'${my_print_defaults_binary}' not found! Please re-install dev-db/mysql-connector-c!" + fi + + if [[ -z "${MYSQL_USER}" ]] ; then + MYSQL_USER=mysql + if use prefix ; then + MYSQL_USER=$(id -u -n 2>/dev/null) + if [[ -z "${MYSQL_USER}" ]] ; then + die "Failed to determine current username!" + fi + fi + fi + + if [[ -z "${MYSQL_GROUP}" ]] ; then + MYSQL_GROUP=mysql + if use prefix ; then + MYSQL_GROUP=$(id -g -n 2>/dev/null) + if [[ -z "${MYSQL_GROUP}" ]] ; then + die "Failed to determine current user groupname!" + fi + fi + fi + + # my_print_defaults needs to read stuff in $HOME/.my.cnf + local -x HOME="${EROOT}/root" + + # Make sure the vars are correctly initialized + mysql_init_vars + + # Read currently set data directory + MY_DATADIR="$(_getoptval mysqld datadir "--defaults-file='${MY_SYSCONFDIR}/my.cnf'")" + + # Bug #213475 - MySQL _will_ object strenously if your machine is named + # localhost. Also causes weird failures. + [[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost" + + if [[ -z "${MY_DATADIR}" ]] ; then + die "Sorry, unable to find MY_DATADIR!" + elif [[ -d "${MY_DATADIR}/mysql" ]] ; then + ewarn "Looks like your data directory '${MY_DATADIR}' is already initialized!" + ewarn "Please rename or delete its content if you wish to initialize a new data directory." + die "${PN} data directory at '${MY_DATADIR}' looks already initialized!" + fi + + MYSQL_TMPDIR="$(_getoptval mysqld tmpdir "--defaults-file='${MY_SYSCONFDIR}/my.cnf'")" + MYSQL_TMPDIR=${MYSQL_TMPDIR%/} + # These are dir+prefix + MYSQL_LOG_BIN="$(_getoptval mysqld log-bin "--defaults-file='${MY_SYSCONFDIR}/my.cnf'")" + MYSQL_LOG_BIN=${MYSQL_LOG_BIN%/*} + MYSQL_RELAY_LOG="$(_getoptval mysqld relay-log "--defaults-file='${MY_SYSCONFDIR}/my.cnf'")" + MYSQL_RELAY_LOG=${MYSQL_RELAY_LOG%/*} + + # Create missing directories. + # Always check if mysql user can write to directory even if we just + # created directory because a parent directory might be not + # accessible for that user. + PID_DIR="${EROOT}/run/mysqld" + if [[ ! -d "${PID_DIR}" ]] ; then + einfo "Creating ${PN} PID directory '${PID_DIR}' ..." + install -d -m 755 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${PID_DIR}" \ + || die "Failed to create PID directory '${PID_DIR}'!" + fi + + local _pid_dir_testfile="$(_mktemp_dry "${PID_DIR}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_pid_dir_testfile}" ]] \ + && die "_mktemp_dry() for '${PID_DIR}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_pid_dir_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_pid_dir_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into PID dir '${PID_DIR}'!" + else + rm "${_pid_dir_testfile}" || die + unset _pid_dir_testfile + fi + + if [[ ! -d "${MY_DATADIR}" ]] ; then + einfo "Creating ${PN} data directory '${MY_DATADIR}' ..." + install -d -m 770 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${MY_DATADIR}" \ + || die "Failed to create ${PN} data directory '${MY_DATADIR}'!" + fi + + local _my_datadir_testfile="$(_mktemp_dry "${MY_DATADIR}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_my_datadir_testfile}" ]] \ + && die "_mktemp_dry() for '${MY_DATADIR}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_my_datadir_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_my_datadir_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into data directory '${MY_DATADIR}'!" + else + rm "${_my_datadir_testfile}" || die + unset _my_datadir_testfile + fi + + if [[ -n "${MYSQL_TMPDIR}" && ! -d "${MYSQL_TMPDIR}" ]] ; then + einfo "Creating ${PN} tmpdir '${MYSQL_TMPDIR}' ..." + install -d -m 770 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${MYSQL_TMPDIR}" \ + || die "Failed to create ${PN} tmpdir '${MYSQL_TMPDIR}'!" + fi + + if [[ -z "${MYSQL_TMPDIR}" ]] ; then + MYSQL_TMPDIR="$(_mktemp_dry "${EROOT}/tmp/mysqld-tmp.XXXXXXXXX")" + [[ -z "${MYSQL_TMPDIR}" ]] \ + && die "_mktemp_dry() for '${MYSQL_TMPDIR}' failed!" + + mkdir "${MYSQL_TMPDIR}" || die + chown ${MYSQL_USER} "${MYSQL_TMPDIR}" || die + fi + + # Now we need to test MYSQL_TMPDIR... + local _my_tmpdir_testfile="$(_mktemp_dry "${MYSQL_TMPDIR}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_my_tmpdir_testfile}" ]] \ + && die "_mktemp_dry() for '${MYSQL_TMPDIR}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_my_tmpdir_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_my_tmpdir_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into tmpdir '${MYSQL_TMPDIR}'!" + else + rm "${_my_tmpdir_testfile}" || die + unset _my_tmpdir_testfile + fi + + if [[ "${MYSQL_LOG_BIN}" == /* && ! -d "${MYSQL_LOG_BIN}" ]] ; then + # Only create directory when MYSQL_LOG_BIN is an absolute path + einfo "Creating ${PN} log-bin directory '${MYSQL_LOG_BIN}' ..." + install -d -m 770 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${MYSQL_LOG_BIN}" \ + || die "Failed to create ${PN} log-bin directory '${MYSQL_LOG_BIN}'" + fi + + if [[ "${MYSQL_LOG_BIN}" == /* ]] ; then + # Only test when MYSQL_LOG_BIN is an absolute path + local _my_logbin_testfile="$(_mktemp_dry "${MYSQL_LOG_BIN}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_my_logbin_testfile}" ]] \ + && die "_mktemp_dry() for '${MYSQL_LOG_BIN}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_my_logbin_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_my_logbin_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into log-bin directory '${MYSQL_LOG_BIN}'!" + else + rm "${_my_logbin_testfile}" || die + unset _my_logbin_testfile + fi + fi + + if [[ "${MYSQL_RELAY_LOG}" == /* && ! -d "${MYSQL_RELAY_LOG}" ]] ; then + # Only create directory when MYSQL_RELAY_LOG is an absolute path + einfo "Creating ${PN} relay-log directory '${MYSQL_RELAY_LOG}' ..." + install -d -m 770 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${MYSQL_RELAY_LOG}" \ + || die "Failed to create ${PN} relay-log directory '${MYSQL_RELAY_LOG}'!" + fi + + if [[ "${MYSQL_RELAY_LOG}" == /* ]] ; then + # Only test when MYSQL_RELAY_LOG is an absolute path + local _my_relaylog_testfile="$(_mktemp_dry "${MYSQL_RELAY_LOG}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_my_relaylog_testfile}" ]] \ + && die "_mktemp_dry() for '${MYSQL_RELAY_LOG}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_my_relaylog_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_my_relaylog_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into relay-log directory '${MYSQL_RELAY_LOG}'!" + else + rm "${_my_relaylog_testfile}" || die + unset _my_relaylog_testfile + fi + fi + + local SETUP_TMPDIR=$(mktemp -d "/tmp/${PN}-config.XXXXXXXXX" 2>/dev/null) + [[ -z "${SETUP_TMPDIR}" ]] && die "Failed to create setup tmpdir" + + # Limit access + chmod 0770 "${SETUP_TMPDIR}" || die + chown ${MYSQL_USER} "${SETUP_TMPDIR}" || die + + local mysql_install_log="${SETUP_TMPDIR}/install_db.log" + local mysqld_logfile="${SETUP_TMPDIR}/mysqld.log" + + echo "" + einfo "Detected settings:" + einfo "==================" + einfo "MySQL User:\t\t\t\t${MYSQL_USER}" + einfo "MySQL Group:\t\t\t\t${MYSQL_GROUP}" + einfo "MySQL DATA directory:\t\t${MY_DATADIR}" + einfo "MySQL TMP directory:\t\t\t${MYSQL_TMPDIR}" + + if [[ "${MYSQL_LOG_BIN}" == /* ]] ; then + # Absolute path for binary log files specified + einfo "MySQL Binary Log File location:\t${MYSQL_LOG_BIN}" + fi + + if [[ "${MYSQL_RELAY_LOG}" == /* ]] ; then + # Absolute path for relay log files specified + einfo "MySQL Relay Log File location:\t${MYSQL_RELAY_LOG}" + fi + + einfo "PID DIR:\t\t\t\t${PID_DIR}" + einfo "Install db log:\t\t\t${mysql_install_log}" + einfo "Install server log:\t\t\t${mysqld_logfile}" + + echo + + if [[ -z "${MYSQL_ROOT_PASSWORD}" ]] ; then + local tmp_mysqld_password_source= + + for tmp_mysqld_password_source in mysql client ; do + einfo "Trying to get password for mysql 'root' user from '${tmp_mysqld_password_source}' section ..." + MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password)" + if [[ -n "${MYSQL_ROOT_PASSWORD}" ]] ; then + if [[ ${MYSQL_ROOT_PASSWORD} == *$'\n'* ]] ; then + ewarn "Ignoring password from '${tmp_mysqld_password_source}' section due to newline character (do you have multiple password options set?)!" + MYSQL_ROOT_PASSWORD= + continue + fi + + einfo "Found password in '${tmp_mysqld_password_source}' section!" + break + fi + done + + # Sometimes --show is required to display passwords in some implementations of my_print_defaults + if [[ "${MYSQL_ROOT_PASSWORD}" == '*****' ]] ; then + MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password --show)" + fi + + unset tmp_mysqld_password_source + fi + + if [[ -z "${MYSQL_ROOT_PASSWORD}" ]] ; then + local pwd1="a" + local pwd2="b" + + echo + einfo "No password for mysql 'root' user was specified via environment" + einfo "variable MYSQL_ROOT_PASSWORD and no password was found in config" + einfo "file like '${HOME}/.my.cnf'." + einfo "To continue please provide a password for the mysql 'root' user" + einfo "now on console:" + ewarn "NOTE: Please avoid [\"'\\_%] characters in the password!" + read -rsp " >" pwd1 ; echo + + einfo "Retype the password" + read -rsp " >" pwd2 ; echo + + if [[ "x${pwd1}" != "x${pwd2}" ]] ; then + die "Passwords are not the same!" + fi + + MYSQL_ROOT_PASSWORD="${pwd1}" + unset pwd1 pwd2 + + echo + fi + + local -a mysqld_options + + # Fix bug 446200. Don't reference host my.cnf, needs to come first, + # see http://bugs.mysql.com/bug.php?id=31312 + use prefix && mysqld_options+=( "--defaults-file='${MY_SYSCONFDIR}/my.cnf'" ) + + # Figure out which options we need to disable to do the setup + local helpfile="${TMPDIR}/mysqld-help" + "${EROOT}/usr/sbin/mysqld" --verbose --help >"${helpfile}" 2>/dev/null + + local opt optexp optfull + for opt in host-cache name-resolve networking slave-start \ + federated ssl log-bin relay-log slow-query-log external-locking \ + log-slave-updates \ + ; do + optexp="--(skip-)?${opt}" optfull="--loose-skip-${opt}" + grep -E -sq -- "${optexp}" "${helpfile}" && mysqld_options+=( "${optfull}" ) + done + + # Prepare timezones, see + # https://dev.mysql.com/doc/mysql/en/time-zone-support.html + local tz_sql="${SETUP_TMPDIR}/tz.sql" + + echo "USE mysql;" >"${tz_sql}" + "${EROOT}/usr/bin/mysql_tzinfo_to_sql" "${EROOT}/usr/share/zoneinfo" >> "${tz_sql}" 2>/dev/null + if [[ $? -ne 0 ]] ; then + die "mysql_tzinfo_to_sql failed!" + fi + + local cmd=( + "${mysql_install_db_binary}" + "${mysqld_options[@]}" + "--init-file='${tz_sql}'" + "--basedir='${EROOT}/usr'" + "--datadir='${MY_DATADIR}'" + "--tmpdir='${MYSQL_TMPDIR}'" + "--log-error='${mysql_install_log}'" + "--rpm" + "--cross-bootstrap" + "--skip-test-db" + "--user=${MYSQL_USER}" + ) + + einfo "Initializing ${PN} data directory: ${cmd[@]}" + eval "${cmd[@]}" >>"${mysql_install_log}" 2>&1 + + if [[ $? -ne 0 || ! -f "${MY_DATADIR}/mysql/user.frm" ]] ; then + grep -B5 -A999 -iE "(Aborting|ERROR|errno)" "${mysql_install_log}" 1>&2 + die "Failed to initialize ${PN} data directory. Please review '${mysql_install_log}'!" + fi + + local x=${RANDOM} + local socket="${PID_DIR}/mysqld.${x}.sock" + [[ -f "${socket}" ]] && die "Randomness failed; Socket ${socket} already exists!" + local pidfile="${PID_DIR}/mysqld.${x}.pid" + [[ -f "${pidfile}" ]] && die "Randomness failed; Pidfile ${pidfile} already exists!" + unset x + + cmd=( + "${mysqld_binary}" + "${mysqld_options[@]}" + "--basedir='${EROOT}/usr'" + "--datadir='${MY_DATADIR}'" + "--tmpdir='${MYSQL_TMPDIR}'" + --max_allowed_packet=8M + --net_buffer_length=16K + "--socket='${socket}'" + "--pid-file='${pidfile}'" + "--log-error='${mysqld_logfile}'" + "--user=${MYSQL_USER}" + ) + + einfo "Starting mysqld to finalize initialization: ${cmd[@]}" + eval "${cmd[@]}" >>"${mysqld_logfile}" 2>&1 & + + echo -n "Waiting for mysqld to accept connections " + local maxtry=15 + while [[ ! -S "${socket}" && "${maxtry}" -gt 1 ]] ; do + maxtry=$((${maxtry}-1)) + echo -n "." + sleep 1 + done + + if [[ -S "${socket}" ]] ; then + # Even with a socket we don't know if mysqld will abort + # start due to an error so just wait a little bit more... + maxtry=5 + while [[ -S "${socket}" && "${maxtry}" -gt 1 ]] ; do + maxtry=$((${maxtry}-1)) + echo -n "." + sleep 1 + done + fi + + echo + + if [[ ! -S "${socket}" ]] ; then + grep -B5 -A999 -iE "(Aborting|ERROR|errno)" "${mysqld_logfile}" 1>&2 + die "mysqld was unable to start from initialized data directory. Please review '${mysqld_logfile}'!" + fi + + local mysql_logfile="${SETUP_TMPDIR}/set_root_pw.log" + touch "${mysql_logfile}" || die + + ebegin "Setting root password" + # Do this from memory, as we don't want clear text passwords in temp files + local sql="ALTER USER 'root'@'localhost' IDENTIFIED BY '${MYSQL_ROOT_PASSWORD}'" + cmd=( + "${mysql_binary}" + --no-defaults + "--socket='${socket}'" + -hlocalhost + "-e \"${sql}\"" + ) + eval "${cmd[@]}" >"${mysql_logfile}" 2>&1 + local rc=$? + eend ${rc} + + if [[ ${rc} -ne 0 ]] ; then + # Poor man's solution which tries to avoid having password + # in log. NOTE: sed can fail if user didn't follow advice + # and included character which will require escaping... + sed -i -e "s/${MYSQL_ROOT_PASSWORD}/*****/" "${mysql_logfile}" 2>/dev/null + + grep -B5 -A999 -iE "(Aborting|ERROR|errno)" "${mysql_logfile}" + die "Failed to set ${PN} root password. Please review '${mysql_logfile}'!" + fi + + # Stop the server + if [[ -f "${pidfile}" ]] && pgrep -F "${pidfile}" &>/dev/null ; then + echo -n "Stopping the server " + pkill -F "${pidfile}" &>/dev/null + + maxtry=10 + while [[ -f "${pidfile}" ]] && pgrep -F "${pidfile}" &>/dev/null ; do + maxtry=$((${maxtry}-1)) + echo -n "." + sleep 1 + done + + echo + + if [[ -f "${pidfile}" ]] && pgrep -F "${pidfile}" &>/dev/null ; then + # We somehow failed to stop server. + # However, not a fatal error. Just warn the user. + ewarn "WARNING: mysqld[$(cat "${pidfile}")] is still running!" + fi + fi + + rm -r "${SETUP_TMPDIR}" || die + + einfo "${PN} data directory at '${MY_DATADIR}' successfully initialized!" +} diff --git a/dev-db/mariadb/mariadb-11.4.5.ebuild b/dev-db/mariadb/mariadb-11.4.5.ebuild new file mode 100644 index 000000000000..4dd61ea1f812 --- /dev/null +++ b/dev-db/mariadb/mariadb-11.4.5.ebuild @@ -0,0 +1,1344 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +SUBSLOT="18" + +JAVA_PKG_OPT_USE="jdbc" + +inherit systemd flag-o-matic prefix toolchain-funcs \ + multiprocessing java-pkg-opt-2 cmake + +DESCRIPTION="An enhanced, drop-in replacement for MySQL" +HOMEPAGE="https://mariadb.org/" +SRC_URI=" + mirror://mariadb/${P}/source/${P}.tar.gz + https://dev.gentoo.org/~arkamar/distfiles/${P}-patches-01.tar.xz +" +# Shorten the path because the socket path length must be shorter than 107 chars +# and we will run a mysql server during test phase +S="${WORKDIR}/mysql" + +LICENSE="GPL-2 LGPL-2.1+" +SLOT="$(ver_cut 1-2)/${SUBSLOT:-0}" +KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86" +IUSE="+backup bindist columnstore cracklib debug extraengine galera innodb-lz4 + innodb-lzo innodb-snappy jdbc jemalloc kerberos latin1 mroonga + numa odbc oqgraph pam +perl profiling rocksdb selinux +server sphinx + sst-rsync sst-mariabackup static systemd systemtap s3 tcmalloc + test xml yassl" + +RESTRICT="!bindist? ( bindist ) !test? ( test )" + +REQUIRED_USE="jdbc? ( extraengine server !static ) + ?? ( tcmalloc jemalloc ) + static? ( yassl !pam ) + test? ( extraengine )" + +# Be warned, *DEPEND are version-dependant +# These are used for both runtime and compiletime +# +# libfmt-10 contains a bug which was fixed in libfmt-11, see +# https://jira.mariadb.org/browse/MDEV-32815, bug 946074 +# libfmt-11.1 works with FMT_STATIC_THOUSANDS_SEPARATOR +# differently, bug 946924 +COMMON_DEPEND=" + dev-libs/libfmt:= + || ( + <dev-libs/libfmt-10 + =dev-libs/libfmt-11.0* + ) + >=dev-libs/libpcre2-10.34:= + >=sys-apps/texinfo-4.7-r1 + sys-libs/ncurses:0= + >=sys-libs/zlib-1.2.3:0= + virtual/libcrypt:= + !bindist? ( + sys-libs/binutils-libs:0= + >=sys-libs/readline-4.1:0= + ) + jemalloc? ( dev-libs/jemalloc:0= ) + kerberos? ( virtual/krb5 ) + kernel_linux? ( + dev-libs/libaio:0= + sys-libs/liburing:= + sys-process/procps:0= + ) + server? ( + app-arch/bzip2 + app-arch/xz-utils + backup? ( app-arch/libarchive:0= ) + columnstore? ( + app-arch/snappy:= + dev-libs/boost:= + dev-libs/libxml2:2= + ) + cracklib? ( sys-libs/cracklib:0= ) + extraengine? ( + odbc? ( dev-db/unixODBC:0= ) + xml? ( dev-libs/libxml2:2= ) + ) + innodb-lz4? ( app-arch/lz4 ) + innodb-lzo? ( dev-libs/lzo ) + innodb-snappy? ( app-arch/snappy:= ) + mroonga? ( app-text/groonga-normalizer-mysql >=app-text/groonga-7.0.4 ) + numa? ( sys-process/numactl ) + oqgraph? ( + dev-libs/boost:= + dev-libs/judy:0= + ) + pam? ( sys-libs/pam:0= ) + s3? ( net-misc/curl ) + systemd? ( sys-apps/systemd:= ) + ) + systemtap? ( >=dev-debug/systemtap-1.3:0= ) + tcmalloc? ( dev-util/google-perftools:0= ) + yassl? ( net-libs/gnutls:0= ) + !yassl? ( + >=dev-libs/openssl-1.0.0:0= + ) +" +BDEPEND="app-alternatives/yacc" +DEPEND="${COMMON_DEPEND} + server? ( + extraengine? ( jdbc? ( >=virtual/jdk-1.8 ) ) + test? ( acct-group/mysql acct-user/mysql ) + ) + static? ( sys-libs/ncurses[static-libs] ) +" +RDEPEND="${COMMON_DEPEND} + !dev-db/mysql !dev-db/percona-server + !dev-db/mariadb:10.3 + !dev-db/mariadb:10.4 + !dev-db/mariadb:10.5 + !dev-db/mariadb:10.6 + !dev-db/mariadb:10.7 + !dev-db/mariadb:10.8 + !dev-db/mariadb:10.9 + !dev-db/mariadb:10.10 + !dev-db/mariadb:10.11 + !dev-db/mariadb:11.0 + !dev-db/mariadb:11.1 + !dev-db/mariadb:11.2 + !dev-db/mariadb:11.3 + selinux? ( sec-policy/selinux-mysql ) + server? ( + columnstore? ( dev-db/mariadb-connector-c ) + extraengine? ( jdbc? ( >=virtual/jre-1.8 ) ) + galera? ( + sys-apps/iproute2 + =sys-cluster/galera-26* + sst-rsync? ( sys-process/lsof ) + sst-mariabackup? ( net-misc/socat[ssl] ) + ) + !prefix? ( dev-db/mysql-init-scripts acct-group/mysql acct-user/mysql ) + ) +" +# For other stuff to bring us in +# dev-perl/DBD-MariaDB is needed by some scripts installed by MySQL +PDEPEND="perl? ( dev-perl/DBD-MariaDB )" + +mysql_init_vars() { + MY_SHAREDSTATEDIR=${MY_SHAREDSTATEDIR="${EPREFIX}/usr/share/mariadb"} + MY_SYSCONFDIR=${MY_SYSCONFDIR="${EPREFIX}/etc/mysql"} + MY_LOCALSTATEDIR=${MY_LOCALSTATEDIR="${EPREFIX}/var/lib/mysql"} + MY_LOGDIR=${MY_LOGDIR="${EPREFIX}/var/log/mysql"} + + if [[ -z "${MY_DATADIR}" ]] ; then + MY_DATADIR="" + if [[ -f "${MY_SYSCONFDIR}/my.cnf" ]] ; then + MY_DATADIR=$(my_print_defaults mysqld 2>/dev/null \ + | sed -ne '/datadir/s|^--datadir=||p' \ + | tail -n1) + if [[ -z "${MY_DATADIR}" ]] ; then + MY_DATADIR=$(grep ^datadir "${MY_SYSCONFDIR}/my.cnf" \ + | sed -e 's/.*=\s*//' \ + | tail -n1) + fi + fi + if [[ -z "${MY_DATADIR}" ]] ; then + MY_DATADIR="${MY_LOCALSTATEDIR}" + einfo "Using default MY_DATADIR" + fi + elog "MySQL MY_DATADIR is ${MY_DATADIR}" + + if [[ -z "${PREVIOUS_DATADIR}" ]] ; then + if [[ -e "${MY_DATADIR}" ]] ; then + # If you get this and you're wondering about it, see bug #207636 + elog "MySQL datadir found in ${MY_DATADIR}" + elog "A new one will not be created." + PREVIOUS_DATADIR="yes" + else + PREVIOUS_DATADIR="no" + fi + export PREVIOUS_DATADIR + fi + else + if [[ ${EBUILD_PHASE} == "config" ]]; then + local new_MY_DATADIR + new_MY_DATADIR=$(my_print_defaults mysqld 2>/dev/null \ + | sed -ne '/datadir/s|^--datadir=||p' \ + | tail -n1) + + if [[ ( -n "${new_MY_DATADIR}" ) && ( "${new_MY_DATADIR}" != "${MY_DATADIR}" ) ]]; then + ewarn "MySQL MY_DATADIR has changed" + ewarn "from ${MY_DATADIR}" + ewarn "to ${new_MY_DATADIR}" + MY_DATADIR="${new_MY_DATADIR}" + fi + fi + fi + + export MY_SHAREDSTATEDIR MY_SYSCONFDIR + export MY_LOCALSTATEDIR MY_LOGDIR + export MY_DATADIR +} + +pkg_setup() { + if [[ ${MERGE_TYPE} != binary ]] ; then + if has test ${FEATURES} ; then + # Bug #213475 - MySQL _will_ object strenuously if your machine is named + # localhost. Also causes weird failures. + [[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost" + + if ! has userpriv ${FEATURES} ; then + die "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root." + fi + fi + fi + + java-pkg-opt-2_pkg_setup +} + +src_unpack() { + unpack ${A} + + mv -f "${WORKDIR}/${P/_rc/}" "${S}" || die +} + +src_prepare() { + eapply "${WORKDIR}"/mariadb-patches + eapply "${FILESDIR}"/${PN}-10.6.11-gssapi.patch + eapply "${FILESDIR}"/${PN}-10.6.12-gcc-13.patch + + eapply_user + + _disable_plugin() { + echo > "${S}/plugin/${1}/CMakeLists.txt" || die + } + _disable_engine() { + echo > "${S}/storage/${1}/CMakeLists.txt" || die + } + + if use jemalloc; then + echo "TARGET_LINK_LIBRARIES(mariadbd LINK_PUBLIC jemalloc)" >> "${S}/sql/CMakeLists.txt" + elif use tcmalloc; then + echo "TARGET_LINK_LIBRARIES(mariadbd LINK_PUBLIC tcmalloc)" >> "${S}/sql/CMakeLists.txt" + fi + + local plugin + local server_plugins=( handler_socket auth_socket feedback metadata_lock_info + locale_info qc_info server_audit sql_errlog auth_ed25519 ) + local test_plugins=( audit_null auth_examples daemon_example fulltext + debug_key_management example_key_management versioning ) + if ! use server; then # These plugins are for the server + for plugin in "${server_plugins[@]}" ; do + _disable_plugin "${plugin}" + done + fi + + if ! use test; then # These plugins are only used during testing + for plugin in "${test_plugins[@]}" ; do + _disable_plugin "${plugin}" + done + _disable_engine test_sql_discovery + echo > "${S}/plugin/auth_pam/testing/CMakeLists.txt" || die + fi + + _disable_engine example + + if ! use oqgraph ; then # avoids extra library checks + _disable_engine oqgraph + fi + + if use mroonga ; then + # Remove the bundled groonga + # There is no CMake flag, it simply checks for existance + rm -r "${S}"/storage/mroonga/vendor/groonga || die "could not remove packaged groonga" + else + _disable_engine mroonga + fi + + # Fix static bindings in galera replication + sed -i -e 's~add_library(wsrep_api_v26$~add_library(wsrep_api_v26 STATIC~' \ + "${S}"/wsrep-lib/wsrep-API/CMakeLists.txt || die + sed -i -e 's~add_library(wsrep-lib$~add_library(wsrep-lib STATIC~' \ + "${S}"/wsrep-lib/src/CMakeLists.txt || die + + # Fix galera_recovery.sh script + sed -i -e "s~@bindir@/my_print_defaults~${EPREFIX}/usr/libexec/mariadb/my_print_defaults~" \ + scripts/galera_recovery.sh || die + + sed -i -e 's~ \$basedir/lib/\*/mariadb19/plugin~~' \ + "${S}"/scripts/mysql_install_db.sh || die + + cmake_src_prepare + java-pkg-opt-2_src_prepare +} + +src_configure() { + # bug #855233 (MDEV-11914, MDEV-25633) at least + filter-lto + # bug 508724 mariadb cannot use ld.gold + tc-ld-is-gold && tc-ld-force-bfd + # Bug #114895, bug #110149 + filter-flags "-O" "-O[01]" + + # It fails on alpha without this + use alpha && append-ldflags "-Wl,--no-relax" + + # bug #945352 + append-cflags -std=gnu17 + + append-cxxflags -felide-constructors + + # bug #283926, with GCC4.4, this is required to get correct behavior. + append-flags -fno-strict-aliasing + + CMAKE_BUILD_TYPE="RelWithDebInfo" + + # debug hack wrt #497532 + local mycmakeargs=( + -DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')" + -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')" + -DMYSQL_DATADIR="${EPREFIX}/var/lib/mysql" + -DSYSCONFDIR="${EPREFIX}/etc/mysql" + -DINSTALL_BINDIR=bin + -DINSTALL_DOCDIR=share/doc/${PF} + -DINSTALL_DOCREADMEDIR=share/doc/${PF} + -DINSTALL_INCLUDEDIR=include/mysql + -DINSTALL_INFODIR=share/info + -DINSTALL_LIBDIR=$(get_libdir) + -DINSTALL_MANDIR=share/man + -DINSTALL_MYSQLSHAREDIR=share/mariadb + -DINSTALL_PLUGINDIR=$(get_libdir)/mariadb/plugin + -DINSTALL_SCRIPTDIR=bin + -DINSTALL_MYSQLDATADIR="${EPREFIX}/var/lib/mysql" + -DINSTALL_SBINDIR=sbin + -DINSTALL_SUPPORTFILESDIR="${EPREFIX}/usr/share/mariadb" + -DWITH_COMMENT="Gentoo Linux ${PF}" + -DWITH_UNIT_TESTS=$(usex test ON OFF) + -DWITH_LIBEDIT=0 + -DWITH_LIBFMT=system + -DWITH_ZLIB=system + -DWITHOUT_LIBWRAP=1 + -DENABLED_LOCAL_INFILE=1 + -DMYSQL_UNIX_ADDR="${EPREFIX}/var/run/mysqld/mysqld.sock" + -DINSTALL_UNIX_ADDRDIR="${EPREFIX}/var/run/mysqld/mysqld.sock" + -DWITH_DEFAULT_COMPILER_OPTIONS=0 + -DWITH_DEFAULT_FEATURE_SET=0 + -DINSTALL_SYSTEMD_UNITDIR="$(systemd_get_systemunitdir)" + # The build forces this to be defined when cross-compiling. We pass it + # all the time for simplicity and to make sure it is actually correct. + -DSTACK_DIRECTION=$(tc-stack-grows-down && echo -1 || echo 1) + -DPKG_CONFIG_EXECUTABLE="${EPREFIX}/usr/bin/$(tc-getPKG_CONFIG)" + -DPLUGIN_AUTH_GSSAPI=$(usex kerberos DYNAMIC NO) + -DAUTH_GSSAPI_PLUGIN_TYPE=$(usex kerberos DYNAMIC OFF) + -DCONC_WITH_EXTERNAL_ZLIB=YES + -DWITH_EXTERNAL_ZLIB=YES + -DSUFFIX_INSTALL_DIR="" + -DWITH_UNITTEST=OFF + -DWITHOUT_CLIENTLIBS=YES + -DCLIENT_PLUGIN_DIALOG=$(usex test DYNAMIC OFF) + -DCLIENT_PLUGIN_AUTH_GSSAPI_CLIENT=OFF + -DCLIENT_PLUGIN_CLIENT_ED25519=$(usex test DYNAMIC OFF) + -DCLIENT_PLUGIN_MYSQL_CLEAR_PASSWORD=STATIC + -DCLIENT_PLUGIN_CACHING_SHA2_PASSWORD=OFF + ) + if use test ; then + mycmakeargs+=( -DINSTALL_MYSQLTESTDIR=share/mariadb/mysql-test ) + else + mycmakeargs+=( -DINSTALL_MYSQLTESTDIR='' ) + fi + + if ! use yassl ; then + mycmakeargs+=( -DWITH_SSL=system -DCLIENT_PLUGIN_SHA256_PASSWORD=STATIC ) + else + mycmakeargs+=( -DWITH_SSL=bundled ) + fi + + if use systemtap && has_version "dev-debug/systemtap[-dtrace-symlink(+)]" ; then + mycmakeargs+=( + -DDTRACE="${BROOT}"/usr/bin/stap-dtrace + ) + fi + + # bfd.h is only used starting with 10.1 and can be controlled by NOT_FOR_DISTRIBUTION + mycmakeargs+=( + -DWITH_READLINE=$(usex bindist 1 0) + -DNOT_FOR_DISTRIBUTION=$(usex bindist 0 1) + -DENABLE_DTRACE=$(usex systemtap) + ) + + if use server ; then + # Connect and Federated{,X} must be treated special + # otherwise they will not be built as plugins + if ! use extraengine ; then + mycmakeargs+=( + -DPLUGIN_CONNECT=NO + -DPLUGIN_FEDERATED=NO + -DPLUGIN_FEDERATEDX=NO + ) + fi + + mycmakeargs+=( + -DWITH_PCRE=system + -DPLUGIN_OQGRAPH=$(usex oqgraph DYNAMIC NO) + -DPLUGIN_SPHINX=$(usex sphinx YES NO) + -DPLUGIN_AUTH_PAM=$(usex pam YES NO) + -DPLUGIN_AWS_KEY_MANAGEMENT=NO + -DPLUGIN_CRACKLIB_PASSWORD_CHECK=$(usex cracklib YES NO) + -DPLUGIN_SEQUENCE=$(usex extraengine YES NO) + -DPLUGIN_SPIDER=$(usex extraengine YES NO) + -DPLUGIN_S3=$(usex s3 YES NO) + -DPLUGIN_COLUMNSTORE=$(usex columnstore YES NO) + -DCONNECT_WITH_MYSQL=1 + -DCONNECT_WITH_LIBXML2=$(usex xml) + -DCONNECT_WITH_ODBC=$(usex odbc) + -DCONNECT_WITH_JDBC=$(usex jdbc) + # Build failure and autodep wrt bug 639144 + -DCONNECT_WITH_MONGO=OFF + -DWITH_WSREP=$(usex galera) + -DWITH_INNODB_LZ4=$(usex innodb-lz4 ON OFF) + -DWITH_INNODB_LZO=$(usex innodb-lzo ON OFF) + -DWITH_INNODB_SNAPPY=$(usex innodb-snappy ON OFF) + -DPLUGIN_MROONGA=$(usex mroonga DYNAMIC NO) + -DPLUGIN_AUTH_GSSAPI=$(usex kerberos DYNAMIC NO) + -DWITH_MARIABACKUP=$(usex backup ON OFF) + -DWITH_LIBARCHIVE=$(usex backup ON OFF) + -DINSTALL_SQLBENCHDIR="" + -DPLUGIN_ROCKSDB=$(usex rocksdb DYNAMIC NO) + # systemd is only linked to for server notification + -DWITH_SYSTEMD=$(usex systemd yes no) + -DWITH_NUMA=$(usex numa ON OFF) + ) + + if use test ; then + # This is needed for the new client lib which tests a real, open server + mycmakeargs+=( -DSKIP_TESTS=ON ) + fi + + if [[ ( -n ${MYSQL_DEFAULT_CHARSET} ) && ( -n ${MYSQL_DEFAULT_COLLATION} ) ]]; then + ewarn "You are using a custom charset of ${MYSQL_DEFAULT_CHARSET}" + ewarn "and a collation of ${MYSQL_DEFAULT_COLLATION}." + ewarn "You MUST file bugs without these variables set." + + mycmakeargs+=( + -DDEFAULT_CHARSET=${MYSQL_DEFAULT_CHARSET} + -DDEFAULT_COLLATION=${MYSQL_DEFAULT_COLLATION} + ) + + elif ! use latin1 ; then + mycmakeargs+=( + -DDEFAULT_CHARSET=utf8mb4 + -DDEFAULT_COLLATION=utf8mb4_unicode_520_ci + ) + else + mycmakeargs+=( + -DDEFAULT_CHARSET=latin1 + -DDEFAULT_COLLATION=latin1_swedish_ci + ) + fi + mycmakeargs+=( + -DEXTRA_CHARSETS=all + -DMYSQL_USER=mysql + -DDISABLE_SHARED=$(usex static YES NO) + -DWITH_DEBUG=$(usex debug) + -DWITH_EMBEDDED_SERVER=OFF + -DWITH_PROFILING=$(usex profiling) + ) + + if use static; then + mycmakeargs+=( -DWITH_PIC=1 ) + fi + + if use jemalloc || use tcmalloc ; then + mycmakeargs+=( -DWITH_SAFEMALLOC=OFF ) + fi + + # Storage engines + mycmakeargs+=( + -DWITH_ARCHIVE_STORAGE_ENGINE=1 + -DWITH_BLACKHOLE_STORAGE_ENGINE=1 + -DWITH_CSV_STORAGE_ENGINE=1 + -DWITH_HEAP_STORAGE_ENGINE=1 + -DWITH_INNOBASE_STORAGE_ENGINE=1 + -DWITH_MYISAMMRG_STORAGE_ENGINE=1 + -DWITH_MYISAM_STORAGE_ENGINE=1 + -DWITH_PARTITION_STORAGE_ENGINE=1 + ) + else + mycmakeargs+=( + -DWITHOUT_SERVER=1 + -DWITH_EMBEDDED_SERVER=OFF + -DEXTRA_CHARSETS=none + -DINSTALL_SQLBENCHDIR= + -DWITH_SYSTEMD=no + ) + fi + + cmake_src_configure +} + +src_compile() { + cmake_src_compile +} + +# Official test instructions: +# USE='extraengine perl server' \ +# FEATURES='test userpriv' \ +# ebuild mariadb-X.X.XX.ebuild \ +# digest clean package +src_test() { + _disable_test() { + local rawtestname bug reason + rawtestname="${1}" ; shift + bug="${1}" ; shift + reason="${@}" + ewarn "test '${rawtestname}' disabled: '${reason}' (BUG#${bug})" + echo "${rawtestname} : BUG#${bug} ${reason}" >> "${T}/disabled.def" + } + + local TESTDIR="${BUILD_DIR}/mysql-test" + local retstatus_tests + + if ! use server ; then + einfo "Skipping server tests due to minimal build." + return 0 + fi + + # Ensure that parallel runs don't die + export MTR_BUILD_THREAD="$((${RANDOM} % 100))" + + if [[ -z "${MTR_PARALLEL}" ]] ; then + local -x MTR_PARALLEL=$(makeopts_jobs) + + if [[ ${MTR_PARALLEL} -gt 4 ]] ; then + # Running multiple tests in parallel usually require higher ulimit + # and fs.aio-max-nr setting. In addition, tests like main.multi_update + # are known to hit timeout when system is busy. + # To avoid test failure we will limit MTR_PARALLEL to 4 instead of + # using "auto". + local info_msg="Parallel MySQL test suite jobs limited to 4 (MAKEOPTS=${MTR_PARALLEL})" + info_msg+=" to avoid test failures. Set MTR_PARALLEL if you know what you are doing!" + einfo "${info_msg}" + unset info_msg + MTR_PARALLEL=4 + fi + else + einfo "MTR_PARALLEL is set to '${MTR_PARALLEL}'" + fi + + # Try to increase file limits to increase test coverage + if ! ulimit -n 16500 1>/dev/null 2>&1 ; then + # Upper limit comes from parts.partition_* tests + ewarn "For maximum test coverage please raise open file limit to 16500 (ulimit -n 16500) before calling the package manager." + + if ! ulimit -n 4162 1>/dev/null 2>&1 ; then + # Medium limit comes from '[Warning] Buffered warning: Could not + # increase number of max_open_files to more than 3000 (request: 4162)' + ewarn "For medium test coverage please raise open file limit to 4162 (ulimit -n 4162) before calling the package manager." + + if ! ulimit -n 3000 1>/dev/null 2>&1 ; then + ewarn "For minimum test coverage please raise open file limit to 3000 (ulimit -n 3000) before calling the package manager." + else + einfo "Will run test suite with open file limit set to 3000 (minimum test coverage)." + fi + else + einfo "Will run test suite with open file limit set to 4162 (medium test coverage)." + fi + else + einfo "Will run test suite with open file limit set to 16500 (best test coverage)." + fi + + # create directories because mysqladmin might run out of order + mkdir -p "${T}"/var-tests{,/log} || die + + if [[ ! -f "${S}/mysql-test/unstable-tests" ]] ; then + touch "${S}"/mysql-test/unstable-tests || die + fi + + cp "${S}"/mysql-test/unstable-tests "${T}/disabled.def" || die + + local -a disabled_tests + disabled_tests+=( "compat/oracle.plugin;0;Needs example plugin which Gentoo disables" ) + disabled_tests+=( "innodb_gis.1;25095;Known rounding error with latest AMD processors" ) + disabled_tests+=( "innodb_gis.gis;25095;Known rounding error with latest AMD processors" ) + disabled_tests+=( "main.gis;25095;Known rounding error with latest AMD processors" ) + disabled_tests+=( "main.explain_non_select;0;Sporadically failing test" ) + disabled_tests+=( "main.func_time;0;Dependent on time test was written" ) + disabled_tests+=( "main.mysql_upgrade;27044;Sporadically failing test" ) + disabled_tests+=( "main.plugin_auth;0;Needs client libraries built" ) + disabled_tests+=( "main.selectivity_no_engine;26320;Sporadically failing test" ) + disabled_tests+=( "main.stat_tables;0;Sporadically failing test" ) + disabled_tests+=( "main.stat_tables_innodb;0;Sporadically failing test" ) + disabled_tests+=( "main.upgrade_MDEV-19650;25096;Known to be broken" ) + disabled_tests+=( "mariabackup.*;0;Broken test suite" ) + disabled_tests+=( "perfschema.nesting;23458;Known to be broken" ) + disabled_tests+=( "perfschema.prepared_statements;0;Broken test suite" ) + disabled_tests+=( "perfschema.privilege_table_io;27045;Sporadically failing test" ) + disabled_tests+=( "plugins.cracklib_password_check;0;False positive due to varying policies" ) + disabled_tests+=( "plugins.two_password_validations;0;False positive due to varying policies" ) + disabled_tests+=( "roles.acl_statistics;0;False positive due to a user count mismatch caused by previous test" ) + disabled_tests+=( "spider.*;0;Fails with network sandbox" ) + disabled_tests+=( "sys_vars.wsrep_on_without_provider;25625;Known to be broken" ) + disabled_tests+=( "sysschema.v_privileges_by_table_by_level;0;Fails with network sandbox, see MDEV-36030") + + if ! use latin1 ; then + disabled_tests+=( "funcs_1.is_columns_mysql;0;Requires USE=latin1" ) + disabled_tests+=( "main.information_schema;0;Requires USE=latin1" ) + disabled_tests+=( "main.sp2;24177;Requires USE=latin1" ) + disabled_tests+=( "main.system_mysql_db;0;Requires USE=latin1" ) + disabled_tests+=( "main.upgrade_MDEV-19650;24178;Requires USE=latin1" ) + fi + + local test_infos_str test_infos_arr + for test_infos_str in "${disabled_tests[@]}" ; do + IFS=';' read -r -a test_infos_arr <<< "${test_infos_str}" + + if [[ ${#test_infos_arr[@]} != 3 ]] ; then + die "Invalid test data set, not matching format: ${test_infos_str}" + fi + + _disable_test "${test_infos_arr[0]}" "${test_infos_arr[1]}" "${test_infos_arr[2]}" + done + unset test_infos_str test_infos_arr + + # run mysql-test tests + pushd "${TESTDIR}" &>/dev/null || die + perl mysql-test-run.pl --force --vardir="${T}/var-tests" --reorder --skip-test-list="${T}/disabled.def" + retstatus_tests=$? + + popd &>/dev/null || die + + # Cleanup is important for these testcases. + pkill -9 -f "${S}/ndb" 2>/dev/null + pkill -9 -f "${S}/sql" 2>/dev/null + + local failures="" + [[ ${retstatus_tests} -eq 0 ]] || failures="${failures} tests" + + [[ -z "${failures}" ]] || die "Test failures: ${failures}" + einfo "Tests successfully completed" +} + +src_install() { + cmake_src_install + + # Remove an unnecessary, private config header which will never match between ABIs and is not meant to be used + if [[ -f "${ED}/usr/include/mysql/server/private/config.h" ]] ; then + rm "${ED}/usr/include/mysql/server/private/config.h" || die + fi + + # Make sure the vars are correctly initialized + mysql_init_vars + + # Convenience links + einfo "Making Convenience links for mysqlcheck multi-call binary" + dosym "mysqlcheck" "/usr/bin/mysqlanalyze" + dosym "mysqlcheck" "/usr/bin/mysqlrepair" + dosym "mysqlcheck" "/usr/bin/mysqloptimize" + + # INSTALL_LAYOUT=STANDALONE causes cmake to create a /usr/data dir + if [[ -d "${ED}/usr/data" ]] ; then + rm -Rf "${ED}/usr/data" || die + fi + + # Unless they explicitly specific USE=test, then do not install the + # testsuite. It DOES have a use to be installed, esp. when you want to do a + # validation of your database configuration after tuning it. + if ! use test ; then + rm -rf "${D}/${MY_SHAREDSTATEDIR}/mysql-test" + fi + + # Configuration stuff + einfo "Building default configuration ..." + insinto "${MY_SYSCONFDIR#${EPREFIX}}" + [[ -f "${S}/scripts/mysqlaccess.conf" ]] && doins "${S}"/scripts/mysqlaccess.conf + cp "${FILESDIR}/my.cnf-10.2" "${TMPDIR}/my.cnf" || die + eprefixify "${TMPDIR}/my.cnf" + doins "${TMPDIR}/my.cnf" + insinto "${MY_SYSCONFDIR#${EPREFIX}}/mariadb.d" + cp "${FILESDIR}/my.cnf.distro-client" "${TMPDIR}/50-distro-client.cnf" || die + eprefixify "${TMPDIR}/50-distro-client.cnf" + doins "${TMPDIR}/50-distro-client.cnf" + + if use server ; then + mycnf_src="my.cnf.distro-server" + sed -e "s!@DATADIR@!${MY_DATADIR}!g" \ + "${FILESDIR}/${mycnf_src}" \ + > "${TMPDIR}/my.cnf.ok" || die + if use prefix ; then + sed -i -r -e '/^user[[:space:]]*=[[:space:]]*mysql$/d' \ + "${TMPDIR}/my.cnf.ok" || die + fi + if use latin1 ; then + sed -i \ + -e "/character-set/s|utf8|latin1|g" \ + "${TMPDIR}/my.cnf.ok" || die + fi + eprefixify "${TMPDIR}/my.cnf.ok" + newins "${TMPDIR}/my.cnf.ok" 50-distro-server.cnf + + einfo "Including support files and sample configurations" + docinto "support-files" + local script + for script in \ + "${S}"/support-files/magic + do + [[ -f "$script" ]] && dodoc "${script}" + done + + docinto "scripts" + for script in "${S}"/scripts/mysql* ; do + [[ ( -f "$script" ) && ( "${script%.sh}" == "${script}" ) ]] && dodoc "${script}" + done + # Manually install supporting files that conflict with other packages + # but are needed for galera and initial installation + exeinto /usr/libexec/mariadb + doexe "${BUILD_DIR}/extra/my_print_defaults" "${BUILD_DIR}/extra/perror" + + if use pam ; then + keepdir /usr/$(get_libdir)/mariadb/plugin/auth_pam_tool_dir + fi + fi + + # Conflicting files + conflicting_files=() + + # We prefer my_print_defaults from dev-db/mysql-connector-c + conflicting_files=( "${ED}/usr/share/man/man1/my_print_defaults.1" ) + + # Remove bundled mytop in favor of dev-db/mytop + conflicting_files+=( "${ED}/usr/bin/mytop" ) + conflicting_files+=( "${ED}/usr/share/man/man1/mytop.1" ) + + local conflicting_file + for conflicting_file in "${conflicting_files[@]}" ; do + if [[ -e "${conflicting_file}" ]] ; then + rm -v "${conflicting_file}" || die + fi + done + + # Fix a dangling symlink when galera is not built + if [[ -L "${ED}/usr/bin/wsrep_sst_rsync_wan" ]] && ! use galera ; then + rm "${ED}/usr/bin/wsrep_sst_rsync_wan" || die + fi + + # Remove dangling symlink + rm "${ED}/usr/$(get_libdir)/libmariadb.a" || die + + # Remove broken SST scripts that are incompatible + local scriptremove + for scriptremove in wsrep_sst_xtrabackup wsrep_sst_xtrabackup-v2 ; do + if [[ -e "${ED}/usr/bin/${scriptremove}" ]] ; then + rm "${ED}/usr/bin/${scriptremove}" || die + fi + done +} + +pkg_preinst() { + java-pkg-opt-2_pkg_preinst +} + +pkg_postinst() { + # Make sure the vars are correctly initialized + mysql_init_vars + + # Create log directory securely if it does not exist + [[ -d "${ROOT}/${MY_LOGDIR}" ]] || install -d -m0750 -o mysql -g mysql "${ROOT}/${MY_LOGDIR}" + + if use server ; then + if use pam; then + einfo + elog "This install includes the PAM authentication plugin." + elog "To activate and configure the PAM plugin, please read:" + elog "https://mariadb.com/kb/en/mariadb/pam-authentication-plugin/" + einfo + chown mysql:mysql "${EROOT}/usr/$(get_libdir)/mariadb/plugin/auth_pam_tool_dir" || die + fi + + if [[ -z "${REPLACING_VERSIONS}" ]] ; then + einfo + elog "You might want to run:" + elog "\"emerge --config =${CATEGORY}/${PF}\"" + elog "if this is a new install." + elog + elog "If you are switching server implentations, you should run the" + elog "mysql_upgrade tool." + einfo + else + einfo + elog "If you are upgrading major versions, you should run the" + elog "mysql_upgrade tool." + einfo + fi + + if use galera ; then + einfo + elog "Be sure to edit the my.cnf file to activate your cluster settings." + elog "This should be done after running \"emerge --config =${CATEGORY}/${PF}\"" + elog "The first time the cluster is activated, you should add" + elog "--wsrep-new-cluster to the options in /etc/conf.d/mysql for one node." + elog "This option should then be removed for subsequent starts." + einfo + if [[ -n "${REPLACING_VERSIONS}" ]] ; then + local rver + for rver in ${REPLACING_VERSIONS} ; do + if ver_test "${rver}" -lt "10.4.0" ; then + ewarn "Upgrading galera from a previous version requires admin restart of the entire cluster." + ewarn "Please refer to https://mariadb.com/kb/en/library/changes-improvements-in-mariadb-104/#galera-4" + ewarn "for more information" + fi + done + fi + fi + fi + + # Note about configuration change + einfo + elog "This version of mariadb reorganizes the configuration from a single my.cnf" + elog "to several files in /etc/mysql/${PN}.d." + elog "Please backup any changes you made to /etc/mysql/my.cnf" + elog "and add them as a new file under /etc/mysql/${PN}.d with a .cnf extension." + elog "You may have as many files as needed and they are read alphabetically." + elog "Be sure the options have the appropriate section headers, i.e. [mysqld]." + einfo +} + +pkg_config() { + _getoptval() { + local section="${1}" + local option="--${2}" + local extra_options="${3}" + local cmd=( + "${my_print_defaults_binary}" + "${extra_options}" + "${section}" + ) + + local values=() + local parameters=( $(eval "${cmd[@]}" 2>/dev/null) ) + for parameter in "${parameters[@]}" + do + # my_print_defaults guarantees output of options, one per line, + # in the form that they would be specified on the command line. + # So checking for --option=* should be safe. + case ${parameter} in + ${option}=*) + values+=( "${parameter#*=}" ) + ;; + esac + done + + if [[ ${#values[@]} -gt 0 ]] ; then + # Option could have been set multiple times + # in which case only the last occurrence + # contains the current value + echo "${values[-1]}" + fi + } + + _mktemp_dry() { + # emktemp has no --dry-run option + local template="${1}" + + if [[ -z "${template}" ]] ; then + if [[ -z "${T}" ]] ; then + template="/tmp/XXXXXXX" + else + template="${T}/XXXXXXX" + fi + fi + + local template_wo_X=${template//X/} + local n_X + let n_X=${#template}-${#template_wo_X} + if [[ ${n_X} -lt 3 ]] ; then + echo "${FUNCNAME[0]}: too few X's in template '${template}'" >&2 + return + fi + + local attempts=0 + local character tmpfile + while [[ true ]] ; do + let attempts=attempts+1 + + new_file= + while read -n1 character ; do + if [[ "${character}" == "X" ]] ; then + tmpfile+="${RANDOM:0:1}" + else + tmpfile+="${character}" + fi + done < <(echo -n "${template}") + + if [[ ! -f "${tmpfile}" ]] + then + echo "${tmpfile}" + return + fi + + if [[ ${attempts} -ge 100 ]] ; then + echo "${FUNCNAME[0]}: Cannot create temporary file after 100 attempts." >&2 + return + fi + done + } + + local mysql_binary="${EROOT}/usr/bin/mysql" + if [[ ! -x "${mysql_binary}" ]] ; then + die "'${mysql_binary}' not found! Please re-install ${CATEGORY}/${PN}!" + fi + + local mysqld_binary="${EROOT}/usr/sbin/mysqld" + if [[ ! -x "${mysqld_binary}" ]] ; then + die "'${mysqld_binary}' not found! Please re-install ${CATEGORY}/${PN}!" + fi + + local mysql_install_db_binary="${EROOT}/usr/bin/mysql_install_db" + if [[ ! -x "${mysql_install_db_binary}" ]] ; then + die "'${mysql_install_db_binary}' not found! Please re-install ${CATEGORY}/${PN}!" + fi + + local my_print_defaults_binary="${EROOT}/usr/bin/my_print_defaults" + if [[ ! -x "${my_print_defaults_binary}" ]] ; then + die "'${my_print_defaults_binary}' not found! Please re-install dev-db/mysql-connector-c!" + fi + + if [[ -z "${MYSQL_USER}" ]] ; then + MYSQL_USER=mysql + if use prefix ; then + MYSQL_USER=$(id -u -n 2>/dev/null) + if [[ -z "${MYSQL_USER}" ]] ; then + die "Failed to determine current username!" + fi + fi + fi + + if [[ -z "${MYSQL_GROUP}" ]] ; then + MYSQL_GROUP=mysql + if use prefix ; then + MYSQL_GROUP=$(id -g -n 2>/dev/null) + if [[ -z "${MYSQL_GROUP}" ]] ; then + die "Failed to determine current user groupname!" + fi + fi + fi + + # my_print_defaults needs to read stuff in $HOME/.my.cnf + local -x HOME="${EROOT}/root" + + # Make sure the vars are correctly initialized + mysql_init_vars + + # Read currently set data directory + MY_DATADIR="$(_getoptval mysqld datadir "--defaults-file='${MY_SYSCONFDIR}/my.cnf'")" + + # Bug #213475 - MySQL _will_ object strenously if your machine is named + # localhost. Also causes weird failures. + [[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost" + + if [[ -z "${MY_DATADIR}" ]] ; then + die "Sorry, unable to find MY_DATADIR!" + elif [[ -d "${MY_DATADIR}/mysql" ]] ; then + ewarn "Looks like your data directory '${MY_DATADIR}' is already initialized!" + ewarn "Please rename or delete its content if you wish to initialize a new data directory." + die "${PN} data directory at '${MY_DATADIR}' looks already initialized!" + fi + + MYSQL_TMPDIR="$(_getoptval mysqld tmpdir "--defaults-file='${MY_SYSCONFDIR}/my.cnf'")" + MYSQL_TMPDIR=${MYSQL_TMPDIR%/} + # These are dir+prefix + MYSQL_LOG_BIN="$(_getoptval mysqld log-bin "--defaults-file='${MY_SYSCONFDIR}/my.cnf'")" + MYSQL_LOG_BIN=${MYSQL_LOG_BIN%/*} + MYSQL_RELAY_LOG="$(_getoptval mysqld relay-log "--defaults-file='${MY_SYSCONFDIR}/my.cnf'")" + MYSQL_RELAY_LOG=${MYSQL_RELAY_LOG%/*} + + # Create missing directories. + # Always check if mysql user can write to directory even if we just + # created directory because a parent directory might be not + # accessible for that user. + PID_DIR="${EROOT}/run/mysqld" + if [[ ! -d "${PID_DIR}" ]] ; then + einfo "Creating ${PN} PID directory '${PID_DIR}' ..." + install -d -m 755 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${PID_DIR}" \ + || die "Failed to create PID directory '${PID_DIR}'!" + fi + + local _pid_dir_testfile="$(_mktemp_dry "${PID_DIR}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_pid_dir_testfile}" ]] \ + && die "_mktemp_dry() for '${PID_DIR}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_pid_dir_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_pid_dir_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into PID dir '${PID_DIR}'!" + else + rm "${_pid_dir_testfile}" || die + unset _pid_dir_testfile + fi + + if [[ ! -d "${MY_DATADIR}" ]] ; then + einfo "Creating ${PN} data directory '${MY_DATADIR}' ..." + install -d -m 770 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${MY_DATADIR}" \ + || die "Failed to create ${PN} data directory '${MY_DATADIR}'!" + fi + + local _my_datadir_testfile="$(_mktemp_dry "${MY_DATADIR}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_my_datadir_testfile}" ]] \ + && die "_mktemp_dry() for '${MY_DATADIR}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_my_datadir_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_my_datadir_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into data directory '${MY_DATADIR}'!" + else + rm "${_my_datadir_testfile}" || die + unset _my_datadir_testfile + fi + + if [[ -n "${MYSQL_TMPDIR}" && ! -d "${MYSQL_TMPDIR}" ]] ; then + einfo "Creating ${PN} tmpdir '${MYSQL_TMPDIR}' ..." + install -d -m 770 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${MYSQL_TMPDIR}" \ + || die "Failed to create ${PN} tmpdir '${MYSQL_TMPDIR}'!" + fi + + if [[ -z "${MYSQL_TMPDIR}" ]] ; then + MYSQL_TMPDIR="$(_mktemp_dry "${EROOT}/tmp/mysqld-tmp.XXXXXXXXX")" + [[ -z "${MYSQL_TMPDIR}" ]] \ + && die "_mktemp_dry() for '${MYSQL_TMPDIR}' failed!" + + mkdir "${MYSQL_TMPDIR}" || die + chown ${MYSQL_USER} "${MYSQL_TMPDIR}" || die + fi + + # Now we need to test MYSQL_TMPDIR... + local _my_tmpdir_testfile="$(_mktemp_dry "${MYSQL_TMPDIR}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_my_tmpdir_testfile}" ]] \ + && die "_mktemp_dry() for '${MYSQL_TMPDIR}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_my_tmpdir_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_my_tmpdir_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into tmpdir '${MYSQL_TMPDIR}'!" + else + rm "${_my_tmpdir_testfile}" || die + unset _my_tmpdir_testfile + fi + + if [[ "${MYSQL_LOG_BIN}" == /* && ! -d "${MYSQL_LOG_BIN}" ]] ; then + # Only create directory when MYSQL_LOG_BIN is an absolute path + einfo "Creating ${PN} log-bin directory '${MYSQL_LOG_BIN}' ..." + install -d -m 770 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${MYSQL_LOG_BIN}" \ + || die "Failed to create ${PN} log-bin directory '${MYSQL_LOG_BIN}'" + fi + + if [[ "${MYSQL_LOG_BIN}" == /* ]] ; then + # Only test when MYSQL_LOG_BIN is an absolute path + local _my_logbin_testfile="$(_mktemp_dry "${MYSQL_LOG_BIN}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_my_logbin_testfile}" ]] \ + && die "_mktemp_dry() for '${MYSQL_LOG_BIN}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_my_logbin_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_my_logbin_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into log-bin directory '${MYSQL_LOG_BIN}'!" + else + rm "${_my_logbin_testfile}" || die + unset _my_logbin_testfile + fi + fi + + if [[ "${MYSQL_RELAY_LOG}" == /* && ! -d "${MYSQL_RELAY_LOG}" ]] ; then + # Only create directory when MYSQL_RELAY_LOG is an absolute path + einfo "Creating ${PN} relay-log directory '${MYSQL_RELAY_LOG}' ..." + install -d -m 770 -o ${MYSQL_USER} -g ${MYSQL_GROUP} "${MYSQL_RELAY_LOG}" \ + || die "Failed to create ${PN} relay-log directory '${MYSQL_RELAY_LOG}'!" + fi + + if [[ "${MYSQL_RELAY_LOG}" == /* ]] ; then + # Only test when MYSQL_RELAY_LOG is an absolute path + local _my_relaylog_testfile="$(_mktemp_dry "${MYSQL_RELAY_LOG}/.pkg_config-access-test.XXXXXXXXX")" + [[ -z "${_my_relaylog_testfile}" ]] \ + && die "_mktemp_dry() for '${MYSQL_RELAY_LOG}/.pkg_config-access-test.XXXXXXXXX' failed!" + + if use prefix ; then + touch "${_my_relaylog_testfile}" &>/dev/null + else + su -s /bin/sh -c "touch ${_my_relaylog_testfile}" ${MYSQL_USER} &>/dev/null + fi + + if [[ $? -ne 0 ]] ; then + die "${MYSQL_USER} user cannot write into relay-log directory '${MYSQL_RELAY_LOG}'!" + else + rm "${_my_relaylog_testfile}" || die + unset _my_relaylog_testfile + fi + fi + + local SETUP_TMPDIR=$(mktemp -d "/tmp/${PN}-config.XXXXXXXXX" 2>/dev/null) + [[ -z "${SETUP_TMPDIR}" ]] && die "Failed to create setup tmpdir" + + # Limit access + chmod 0770 "${SETUP_TMPDIR}" || die + chown ${MYSQL_USER} "${SETUP_TMPDIR}" || die + + local mysql_install_log="${SETUP_TMPDIR}/install_db.log" + local mysqld_logfile="${SETUP_TMPDIR}/mysqld.log" + + echo "" + einfo "Detected settings:" + einfo "==================" + einfo "MySQL User:\t\t\t\t${MYSQL_USER}" + einfo "MySQL Group:\t\t\t\t${MYSQL_GROUP}" + einfo "MySQL DATA directory:\t\t${MY_DATADIR}" + einfo "MySQL TMP directory:\t\t\t${MYSQL_TMPDIR}" + + if [[ "${MYSQL_LOG_BIN}" == /* ]] ; then + # Absolute path for binary log files specified + einfo "MySQL Binary Log File location:\t${MYSQL_LOG_BIN}" + fi + + if [[ "${MYSQL_RELAY_LOG}" == /* ]] ; then + # Absolute path for relay log files specified + einfo "MySQL Relay Log File location:\t${MYSQL_RELAY_LOG}" + fi + + einfo "PID DIR:\t\t\t\t${PID_DIR}" + einfo "Install db log:\t\t\t${mysql_install_log}" + einfo "Install server log:\t\t\t${mysqld_logfile}" + + echo + + if [[ -z "${MYSQL_ROOT_PASSWORD}" ]] ; then + local tmp_mysqld_password_source= + + for tmp_mysqld_password_source in mysql client ; do + einfo "Trying to get password for mysql 'root' user from '${tmp_mysqld_password_source}' section ..." + MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password)" + if [[ -n "${MYSQL_ROOT_PASSWORD}" ]] ; then + if [[ ${MYSQL_ROOT_PASSWORD} == *$'\n'* ]] ; then + ewarn "Ignoring password from '${tmp_mysqld_password_source}' section due to newline character (do you have multiple password options set?)!" + MYSQL_ROOT_PASSWORD= + continue + fi + + einfo "Found password in '${tmp_mysqld_password_source}' section!" + break + fi + done + + # Sometimes --show is required to display passwords in some implementations of my_print_defaults + if [[ "${MYSQL_ROOT_PASSWORD}" == '*****' ]] ; then + MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password --show)" + fi + + unset tmp_mysqld_password_source + fi + + if [[ -z "${MYSQL_ROOT_PASSWORD}" ]] ; then + local pwd1="a" + local pwd2="b" + + echo + einfo "No password for mysql 'root' user was specified via environment" + einfo "variable MYSQL_ROOT_PASSWORD and no password was found in config" + einfo "file like '${HOME}/.my.cnf'." + einfo "To continue please provide a password for the mysql 'root' user" + einfo "now on console:" + ewarn "NOTE: Please avoid [\"'\\_%] characters in the password!" + read -rsp " >" pwd1 ; echo + + einfo "Retype the password" + read -rsp " >" pwd2 ; echo + + if [[ "x${pwd1}" != "x${pwd2}" ]] ; then + die "Passwords are not the same!" + fi + + MYSQL_ROOT_PASSWORD="${pwd1}" + unset pwd1 pwd2 + + echo + fi + + local -a mysqld_options + + # Fix bug 446200. Don't reference host my.cnf, needs to come first, + # see http://bugs.mysql.com/bug.php?id=31312 + use prefix && mysqld_options+=( "--defaults-file='${MY_SYSCONFDIR}/my.cnf'" ) + + # Figure out which options we need to disable to do the setup + local helpfile="${TMPDIR}/mysqld-help" + "${EROOT}/usr/sbin/mysqld" --verbose --help >"${helpfile}" 2>/dev/null + + local opt optexp optfull + for opt in host-cache name-resolve networking slave-start \ + federated ssl log-bin relay-log slow-query-log external-locking \ + log-slave-updates \ + ; do + optexp="--(skip-)?${opt}" optfull="--loose-skip-${opt}" + grep -E -sq -- "${optexp}" "${helpfile}" && mysqld_options+=( "${optfull}" ) + done + + # Prepare timezones, see + # https://dev.mysql.com/doc/mysql/en/time-zone-support.html + local tz_sql="${SETUP_TMPDIR}/tz.sql" + + echo "USE mysql;" >"${tz_sql}" + "${EROOT}/usr/bin/mysql_tzinfo_to_sql" "${EROOT}/usr/share/zoneinfo" >> "${tz_sql}" 2>/dev/null + if [[ $? -ne 0 ]] ; then + die "mysql_tzinfo_to_sql failed!" + fi + + local cmd=( + "${mysql_install_db_binary}" + "${mysqld_options[@]}" + "--init-file='${tz_sql}'" + "--basedir='${EROOT}/usr'" + "--datadir='${MY_DATADIR}'" + "--tmpdir='${MYSQL_TMPDIR}'" + "--log-error='${mysql_install_log}'" + "--rpm" + "--cross-bootstrap" + "--skip-test-db" + "--user=${MYSQL_USER}" + ) + + einfo "Initializing ${PN} data directory: ${cmd[@]}" + eval "${cmd[@]}" >>"${mysql_install_log}" 2>&1 + + if [[ $? -ne 0 || ! -f "${MY_DATADIR}/mysql/user.frm" ]] ; then + grep -B5 -A999 -iE "(Aborting|ERROR|errno)" "${mysql_install_log}" 1>&2 + die "Failed to initialize ${PN} data directory. Please review '${mysql_install_log}'!" + fi + + local x=${RANDOM} + local socket="${PID_DIR}/mysqld.${x}.sock" + [[ -f "${socket}" ]] && die "Randomness failed; Socket ${socket} already exists!" + local pidfile="${PID_DIR}/mysqld.${x}.pid" + [[ -f "${pidfile}" ]] && die "Randomness failed; Pidfile ${pidfile} already exists!" + unset x + + cmd=( + "${mysqld_binary}" + "${mysqld_options[@]}" + "--basedir='${EROOT}/usr'" + "--datadir='${MY_DATADIR}'" + "--tmpdir='${MYSQL_TMPDIR}'" + --max_allowed_packet=8M + --net_buffer_length=16K + "--socket='${socket}'" + "--pid-file='${pidfile}'" + "--log-error='${mysqld_logfile}'" + "--user=${MYSQL_USER}" + ) + + einfo "Starting mysqld to finalize initialization: ${cmd[@]}" + eval "${cmd[@]}" >>"${mysqld_logfile}" 2>&1 & + + echo -n "Waiting for mysqld to accept connections " + local maxtry=15 + while [[ ! -S "${socket}" && "${maxtry}" -gt 1 ]] ; do + maxtry=$((${maxtry}-1)) + echo -n "." + sleep 1 + done + + if [[ -S "${socket}" ]] ; then + # Even with a socket we don't know if mysqld will abort + # start due to an error so just wait a little bit more... + maxtry=5 + while [[ -S "${socket}" && "${maxtry}" -gt 1 ]] ; do + maxtry=$((${maxtry}-1)) + echo -n "." + sleep 1 + done + fi + + echo + + if [[ ! -S "${socket}" ]] ; then + grep -B5 -A999 -iE "(Aborting|ERROR|errno)" "${mysqld_logfile}" 1>&2 + die "mysqld was unable to start from initialized data directory. Please review '${mysqld_logfile}'!" + fi + + local mysql_logfile="${SETUP_TMPDIR}/set_root_pw.log" + touch "${mysql_logfile}" || die + + ebegin "Setting root password" + # Do this from memory, as we don't want clear text passwords in temp files + local sql="ALTER USER 'root'@'localhost' IDENTIFIED BY '${MYSQL_ROOT_PASSWORD}'" + cmd=( + "${mysql_binary}" + --no-defaults + "--socket='${socket}'" + -hlocalhost + "-e \"${sql}\"" + ) + eval "${cmd[@]}" >"${mysql_logfile}" 2>&1 + local rc=$? + eend ${rc} + + if [[ ${rc} -ne 0 ]] ; then + # Poor man's solution which tries to avoid having password + # in log. NOTE: sed can fail if user didn't follow advice + # and included character which will require escaping... + sed -i -e "s/${MYSQL_ROOT_PASSWORD}/*****/" "${mysql_logfile}" 2>/dev/null + + grep -B5 -A999 -iE "(Aborting|ERROR|errno)" "${mysql_logfile}" + die "Failed to set ${PN} root password. Please review '${mysql_logfile}'!" + fi + + # Stop the server + if [[ -f "${pidfile}" ]] && pgrep -F "${pidfile}" &>/dev/null ; then + echo -n "Stopping the server " + pkill -F "${pidfile}" &>/dev/null + + maxtry=10 + while [[ -f "${pidfile}" ]] && pgrep -F "${pidfile}" &>/dev/null ; do + maxtry=$((${maxtry}-1)) + echo -n "." + sleep 1 + done + + echo + + if [[ -f "${pidfile}" ]] && pgrep -F "${pidfile}" &>/dev/null ; then + # We somehow failed to stop server. + # However, not a fatal error. Just warn the user. + ewarn "WARNING: mysqld[$(cat "${pidfile}")] is still running!" + fi + fi + + rm -r "${SETUP_TMPDIR}" || die + + einfo "${PN} data directory at '${MY_DATADIR}' successfully initialized!" +} diff --git a/dev-db/mongodb-compass-bin/Manifest b/dev-db/mongodb-compass-bin/Manifest index b70ad5664cb9..fe445d814c10 100644 --- a/dev-db/mongodb-compass-bin/Manifest +++ b/dev-db/mongodb-compass-bin/Manifest @@ -1,3 +1,3 @@ -DIST mongodb-compass_1.45.1_amd64.deb 114196516 BLAKE2B ce79b13a9e590cb305e8bbc88d5838b67805d207d09f1bf6ac99cde96f5b7c3549c8d53d0cb7fee082878e2ef0d12da5cadaf6c238eebd2f3c48ad7f963b5d82 SHA512 98989fdebee1e526276d7b35c3fac4d541c740c3beb3e71321672a225a0881465a15f1c179b7546f46a75f06fd7d739e19f849d2b5d5b661298258f1543d8074 -EBUILD mongodb-compass-bin-1.45.1.ebuild 865 BLAKE2B 84c360766335aca90d5a6e718569fb29ab8d8ce9df1331bc2961e5f29f41d690faed027c9482de6120268b868825342949c0edaee99d9714143e514e1e28069c SHA512 1482c6948db7d0fba85c0ef70e542c06d78bca8ba402a06dfb76fe0c1f0fed7cd19ef0b0ce41de03ef01413a54c7d1fc7231fcb36db2791770f0f1bca1249dfe +DIST mongodb-compass_1.45.2_amd64.deb 114271168 BLAKE2B ec330d75f86ec6bec81ffb57266b54833859785867e1fb375a1ae1f57de9a6fff7215da7f67766ed1bc603c4a12a43605701af8aa26e8672f57721abecd3403f SHA512 cd249a3bb7c3290031caba21af038281ca62a9a2aa4322f0dadc32411c1292c37f5f2d4cc1aa664e6d3c17fb5cbe366fc76d68304041758116f58064fe1bfb88 +EBUILD mongodb-compass-bin-1.45.2.ebuild 1278 BLAKE2B d41adef1d811f150fd37013ad076bb0b2ff2e43c05626ca7767649ae5924ea7daa87ba3d5efd2148f988caf1306455bf51cbecc7bd3ddcbca05d1386a07a2d77 SHA512 2e99db9007159b2e4e4099b0b2aa66eecac496359df19a5c73556ebbb8bccb6bda93c8ef44bc13e348b332a0659d03496e9e36e06e5ca3f1d81feb38978951ee MISC metadata.xml 334 BLAKE2B eab2f1899e5f4a2848417001fc41857c70844a4cbb01eea892f8a23b324c7faf0a11aa6066582add9e8493238728b3a4f6a3e57b676c7dd6a07484bb15c79909 SHA512 95bd0e74a4188839c2dcde628bd4635e6f216ffd1b54825571045c2199d8ae6e0a9fcaf93edfdf3506bb5b297fa720339b85780f8f910eb567e8e555004d0d5c diff --git a/dev-db/mongodb-compass-bin/mongodb-compass-bin-1.45.1.ebuild b/dev-db/mongodb-compass-bin/mongodb-compass-bin-1.45.2.ebuild index 019ffd14325c..a6af371e3ef6 100644 --- a/dev-db/mongodb-compass-bin/mongodb-compass-bin-1.45.1.ebuild +++ b/dev-db/mongodb-compass-bin/mongodb-compass-bin-1.45.2.ebuild @@ -14,6 +14,30 @@ LICENSE="SSPL-1" SLOT="0" KEYWORDS="-* ~amd64" +RDEPEND=" + dev-libs/nss + dev-libs/openssl:0/3 + media-libs/alsa-lib + media-libs/mesa + net-misc/curl + net-print/cups + sys-apps/dbus + sys-libs/glibc + sys-libs/zlib + virtual/secret-service + x11-libs/cairo + x11-libs/gtk+:3 + x11-libs/libdrm + x11-libs/libX11 + x11-libs/libxcb + x11-libs/libXcomposite + x11-libs/libXdamage + x11-libs/libXext + x11-libs/libXfixes + x11-libs/libxkbcommon + x11-libs/libXrandr + x11-libs/pango +" QA_PREBUILT=" usr/lib/mongodb-compass/.* " diff --git a/dev-db/repmgr/Manifest b/dev-db/repmgr/Manifest index 178fc20b06ba..3ba4aec31c48 100644 --- a/dev-db/repmgr/Manifest +++ b/dev-db/repmgr/Manifest @@ -1,6 +1,8 @@ AUX repmgr-5.1.0-fix-missing-getpwuid-clang16.patch 230 BLAKE2B 50ace0a1502aaebddf4c6758506403604d24c3da0d2086f0a42a1af5f1b8940fda6afa91292bd42f634fcbdf1a5c9bacfeb8ddf19bee4082f81edf4dd5eb1448 SHA512 06fdf835b05c08a53fb4ed66b35da096f11a00e213c25a992c93f13cb43c254122befd71f0c1ef09d98fbe01d37dd7b2ef596f502be0614408dc67a9a9e367a0 AUX repmgr-5.1.0-fno-common.patch 1400 BLAKE2B 268594514ebd8f995e15a78792a130f612bdd3144c4e1b0d883599990f25202fcec5122ea2bae9ef2fa3b796033d804fe765f5455cc9e83412b63ab714539f9a SHA512 2de347a9e2df871db3eb7c1e921cb369dcee62400d595be733f32e015a753eebf1429129b40f79134e8c0cfe8a2f8587bb629df9dd705f0dd7401fda1d40af28 DIST repmgr-5.1.0.tar.gz 426487 BLAKE2B 25157923f94b8bd27a2b57796f701e89e7d9acfc8dabc4368640068d5926934e5688b27147ae94b4bee7bad54d59353927b5b70cf5590c554c4eef35fadf29b9 SHA512 9fa8a43ee3920269d1c1d2e619939eb68cb7ba79effe11e87dd67c594bacfcde609949322ce968df328f3913111f27d0ebe2f7742a72e21f3df97b0e05c56cc7 +DIST repmgr-5.5.0.tar.gz 463431 BLAKE2B 12f118d47fc5b60e2037833c3f25c4c4e2d8616a2fe2285d3cdad4460f33f1534e78cf69a3f22af086fbcf09f94b2ca90cd6054e2a38a5ada9101c65de2b9452 SHA512 4ba75cf0d4263557c9ccdf73972c07ca06108d4a221a6d4e5cf9541a2bc2089c3aede17874c061798708902ff2e2a87d2d1f79b49cc5a1ef69a7bbccd76e79f2 EBUILD repmgr-5.1.0-r1.ebuild 1154 BLAKE2B c3331738e5fcb9dc36da294576fb36dd554c304c90556d87b17bdabc06e904859b2648cf86f52b7215e7b066b4fb25e7540d651a72cd6f6ad1f2105943871777 SHA512 52c14c607419d463afc3f89561abc2155dbdd3e40c76421722cd6a31ae97272e449c0229291d709f1870f85dba6311e335be8fef4659c67e6dc53081e98711de EBUILD repmgr-5.1.0.ebuild 1098 BLAKE2B c8dba92a0d6a8fc2eb4e3a8ac4eeb1ee33c92a6fba73b07c74b8c5904cedd8468101158419f833415213b28d588cbf259646fbe20ca2fa07865b1554d9e223d1 SHA512 2333e65af23c1009708bada5e61b934ada82f55bac3a25c005b7f71ba334fbb1311232dbb8fc603258bb05dbc59a27eefd29255c94e3f3f2d5fd4cc01c15f6f6 +EBUILD repmgr-5.5.0.ebuild 1081 BLAKE2B d289a8b070ee918b56f0dd824076c0a63286b31eb38bbf5b65b0cf876d1df4f2f1d03eea53258d6713b5c3eccd5db21cd337220ff365f330ff1daf82e2ef6f63 SHA512 a4cc60d84da52ff4472336e1f93ff25c897ebc434648791f25b91e4d5460787b2cefea6b12099a7f0a500cbefed727e88a9e7250ba88a00caeefee89e5d0c9fb MISC metadata.xml 219 BLAKE2B a270ed4d40f32df54032c9bffe34e24cb5c1db00d0084b1c8275595f3fffc3c0fa5518dfcde32b2f8d4b9b0fea636c60679a99bb2636cefc5c7ddf32b5f94a1c SHA512 7bb667bc481064e5afe1856084f0b8bcbcad41a8805d31d29ef5c698598ac615aa11872029ebdbb1eea70e80f2268162f69f0ea6d9b56a4ca5bb76e3d9c8918d diff --git a/dev-db/repmgr/repmgr-5.5.0.ebuild b/dev-db/repmgr/repmgr-5.5.0.ebuild new file mode 100644 index 000000000000..90f8ed3be877 --- /dev/null +++ b/dev-db/repmgr/repmgr-5.5.0.ebuild @@ -0,0 +1,49 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +POSTGRES_COMPAT=( 13 14 15 16 17 ) + +RESTRICT="test" + +DESCRIPTION="PostgreSQL Replication Manager" +HOMEPAGE="http://www.repmgr.org/" +SRC_URI="https://github.com/EnterpriseDB/repmgr/releases/download/v${PV}/${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +inherit postgres-multi + +DEPEND="${POSTGRES_DEP} + dev-libs/json-c" +RDEPEND="${DEPEND} + net-misc/rsync" + +PATCHES=( + "${FILESDIR}"/${PN}-5.1.0-fix-missing-getpwuid-clang16.patch +) + +src_configure() { + postgres-multi_foreach econf +} + +src_install() { + postgres-multi_foreach emake DESTDIR="${D}" USE_PGXS=1 install + #emake DESTDIR="${D}" USE_PGXS=1 install + dodoc CREDITS HISTORY COPYRIGHT *.md + + local PGSLOT="$(postgresql-config show)" + einfo "PGSLOT: ${PGSLOT}" + + dodir /usr/share/postgresql-${PGSLOT}/contrib + dodir /usr/$(get_libdir)/postgresql-${PGSLOT} + + insinto /etc + newins repmgr.conf.sample repmgr.conf + + fowners postgres:postgres /etc/repmgr.conf + ewarn "Remember to modify /etc/repmgr.conf" +} diff --git a/dev-db/rqlite/Manifest b/dev-db/rqlite/Manifest index 9069be0972de..1437fbfe4374 100644 --- a/dev-db/rqlite/Manifest +++ b/dev-db/rqlite/Manifest @@ -1,3 +1,5 @@ +DIST rqlite-8.36.10-deps.tar.xz 4080696 BLAKE2B c3903038a96065292209cd992bb368e7838ed824650d22b67ee0c85e1ccf33ed48d8a21b2be50c8044b95be514a8fcead6bc2c5bb9e53bb1e5e548c30dab72d8 SHA512 c93ddfdca210ca072f135a6639d9deb5a1493a256dcc2d18a18c6a6fa240dd6e04d4b76ab0e4dc205d550c961d42b68c5ba3abcc51f99f9948d4fb8e0bd4ba9a +DIST rqlite-8.36.10.tar.gz 775952 BLAKE2B b495ad8cdafe347e43721927380829ad2917ca8f5d51e6622b09bc571df333604641f55be8ec6e1b9c79040037bfc5d45e690dc482f63cf53bc500e730d84216 SHA512 eb0f381a0150bc94e20285a56a784270b4e4f1852edc48f82de5b2e64abfc314ed3a60f047f3fd9f3f3e503f1ebae8f5700ec5019c3fdd1b99a29d2159423bff DIST rqlite-8.36.2-deps.tar.xz 4080944 BLAKE2B a3de4bc297a7bb9a842cf08e4571c61731886bef138e583de5e994c8e65dcd9db52fc0891387ffd5e9e2d10eb602cfcd244cc0a5d38bb3f71fecfef20481fafc SHA512 1d01e587794e9aa5e2575f5542b38a5adc90cea68986b7cdba1e20a0ed07dee90bec20b8a59019a6ba89fcfa81e3aa573f172463e65fc214eb207662eac49c7d DIST rqlite-8.36.2.tar.gz 744888 BLAKE2B 7b4ca9905c6f3b7de3deeadeeaddf69756fa2d044fca9a640d19a47b79975427ccb12ab97d9ec6d0033f62bdd26b17778608296e697f813bc0508f9efaa95c1d SHA512 efd4fc2ab90f339e8ef209e373c5b251bcac61797cc8b5a1784657cb297ac39fb26ef3e96be921953284ff076ff67279cdb93f9fef454149059bf8ae60d73019 DIST rqlite-8.36.3-deps.tar.xz 4078736 BLAKE2B 7bfd590b33e14431831d1acd5b078030a3e94a845180c1144f48d429e26c0a5d5cf98585868fb5d88c96efd430bc833543f87b6a870d1a63550f728a2b7bec42 SHA512 e723a23392f12baa4fcd399f00417f57e142254511f74df027e9a8246c334ec53391d81e9bb3d9dc3a79304ae0ed45badf7563782f30423b093b976020ee359e @@ -6,8 +8,12 @@ DIST rqlite-8.36.5-deps.tar.xz 4081984 BLAKE2B a607643062279a256729687b1bbc821b2 DIST rqlite-8.36.5.tar.gz 749309 BLAKE2B 43bb5740cb153c6971d9a8dee598078969aa93bcd5d81d06baa8ddd83ab0c28737056d7442689c8907e288bdcb0d34475a6e7db96ca2d45d4b41d6e719a97487 SHA512 07eff0135ca8685fd6d48b13ba991232b515f0eaa9aa61b3f5d4ba6e38252f2430342cdbe89ecc96a09abf36c1f85511fcb08a34c0adf75f7f292c023e3d9927 DIST rqlite-8.36.6-deps.tar.xz 4082040 BLAKE2B 1ec6bb86f0daa2bcc3e4d723215e06e2ba06d5f8961c367afa688cf988a186dcbaaaf3905e37f358f05f4a8367e62c9cf2287425f782e0cd2135881ed25dc14c SHA512 9f9be57a9c2f0d01b987ec48775d3acbea23daee92be463ce8248e8022b7811a9bcd347da25847ef3c600b6e8df5160982614387574a4088216fc879babdc399 DIST rqlite-8.36.6.tar.gz 770581 BLAKE2B a55017838601bde4bd1a424fd161272c4fbc821e899c10fd9af66da6c83691d634558fdf08d2896070c4d16ce477013462826edc254297385ac4ddff232ed0cf SHA512 b61986724c8967820985abe209a20357f652ec92e88069ed763896b35354fd318a00f6928c682e0d03ce942428cc9e3fcb06511eec5d453a634cf51d360fe0fa +DIST rqlite-8.36.8-deps.tar.xz 4079916 BLAKE2B d8c34b7c9ec0b172af7f551093e811a5c829ab9c26430ec30ac0e9f5984d8fd9f49d50fb15c9fd8fed9c576a26fa5232854dcb7b2c49b226f74f210233246fee SHA512 3f6f1ecd7fb9f638535f4a19ac88a7b39a16f42ae16d2afbfc33ed3eadfd8b22facaf4693c1eeb810765a2e0caf845ee60a9d2f492adc0df75ca7249a69058b3 +DIST rqlite-8.36.8.tar.gz 776252 BLAKE2B c4375d64bc6558782f1835a1968d211cd7b8d662ea6c5951ac4abc4a008a018172f644ed9af437e61efd09f7e2568341e24dad991c07a6105c17caba81aa03f1 SHA512 8008dc190146b27bde6b0e7660bd290c70f26d2cf087a4a1d9faf1ea557c10cfecaa8660d1bf0d21c36fde57a07f8dd021a1eed9b141bf25a8763120592a0da0 +EBUILD rqlite-8.36.10.ebuild 973 BLAKE2B 64cd50d6a5f0c49ffc28e908efa49ff029b8986592a353e6e00d86dd7bad60cf796cd150d8fba7a199e8d0e5def45158430b9d1eccd372644e6a4c30588e78ec SHA512 0bc982b353725d00c60c22763c743460663b1a8165b3414be0c6f72965e0416d1d1fc607196c67b7a27ba8a133b9f17e0de3812d729c2cfc40cae18767687c4a EBUILD rqlite-8.36.2.ebuild 973 BLAKE2B cc23a70b409b7bed83b535b40d2cffafcdb504cb13fff9b3ce06ed741a7f13ddc5fc8096606b981a56e5823baa6f1b33639ac9f7a844014f56c586d29e43d459 SHA512 38166f329ae7fdd72e4eab479e4cb7ec473bae29050017bfbcbc4cc7cbd9178387f00347e2e11f69a4a6368a811d5b4c03fec010d8f3c432d2d892fe8bd6af7e EBUILD rqlite-8.36.3.ebuild 973 BLAKE2B 8dfa970c0f9f19fe2b10dc987b7636c3eb4817820576aa031b64fd4cfdf685575dc829e618355d6cefa3a6c31ed66feadf55b8d860f9c6a3be0b54bf1085f031 SHA512 3aa7973083ec7c6035b22f54a43c4414df6fae3a6e3c235574d008ac8b4c346444bdfb51df1748aa4cc3e4101ad874ad9de92c6db9f749aae79f29205fcffea5 EBUILD rqlite-8.36.5.ebuild 973 BLAKE2B c2b107704f59fda785266b4dc11ad4986f907fcd3b489a903829e1462f78e9cad0c204ba9550b5b4438c2a84ce99206e09c8d0d3f584c71b0417171015f27482 SHA512 604a62ee173a8883ac791463aff8f4b13ce67cea45903d809a349bbe2a60d719b268579481e62ab775750d8feb0a7081c11f29840ed6318c323baa588e3585df EBUILD rqlite-8.36.6.ebuild 973 BLAKE2B c2b107704f59fda785266b4dc11ad4986f907fcd3b489a903829e1462f78e9cad0c204ba9550b5b4438c2a84ce99206e09c8d0d3f584c71b0417171015f27482 SHA512 604a62ee173a8883ac791463aff8f4b13ce67cea45903d809a349bbe2a60d719b268579481e62ab775750d8feb0a7081c11f29840ed6318c323baa588e3585df +EBUILD rqlite-8.36.8.ebuild 973 BLAKE2B 64cd50d6a5f0c49ffc28e908efa49ff029b8986592a353e6e00d86dd7bad60cf796cd150d8fba7a199e8d0e5def45158430b9d1eccd372644e6a4c30588e78ec SHA512 0bc982b353725d00c60c22763c743460663b1a8165b3414be0c6f72965e0416d1d1fc607196c67b7a27ba8a133b9f17e0de3812d729c2cfc40cae18767687c4a MISC metadata.xml 305 BLAKE2B 43bc299dae9450677761bfaeaa02ac649ac4ecdbb35e3242c8525db13ef0471397a352b2a8aa751ec725ff8e9c86c2a8a19caf71bbe0de206f266d945f287561 SHA512 3dbddc6b5e4e6d8cd82beb722b5b45af6621e8fb84a1d3a1ec5c444026f595fd14babadc92084afe122202c9b940be21b2e1af145d24846de4225582e5e4d5de diff --git a/dev-db/rqlite/rqlite-8.36.10.ebuild b/dev-db/rqlite/rqlite-8.36.10.ebuild new file mode 100644 index 000000000000..bda6343912e9 --- /dev/null +++ b/dev-db/rqlite/rqlite-8.36.10.ebuild @@ -0,0 +1,45 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit go-module +EGIT_COMMIT=768eafc309ff05a57d041d2b19f67994ce83a5c5 + +DESCRIPTION="Replicated SQLite using the Raft consensus protocol" +HOMEPAGE="https://github.com/rqlite/rqlite https://www.philipotoole.com/tag/rqlite/" +SRC_URI="https://github.com/rqlite/rqlite/archive/v${PV}.tar.gz -> ${P}.tar.gz + https://dev.gentoo.org/~zmedico/dist/${P}-deps.tar.xz" + +LICENSE="MIT" +LICENSE+=" Apache-2.0 BSD CC0-1.0 MPL-2.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +src_unpack() { + default +} + +src_prepare() { + ln -sv ../vendor ./ || die + default +} + +src_compile() { + GOBIN="${S}/bin" \ + ego install \ + -ldflags="-X main.version=v${PV} + -X main.branch=master + -X main.commit=${EGIT_COMMIT} + -X main.buildtime=$(date +%Y-%m-%dT%T%z)" \ + ./cmd/... || die +} + +src_test() { + GOBIN="${S}/bin" \ + ego test ./... || die +} + +src_install() { + dobin bin/* + dodoc -r *.md DOC +} diff --git a/dev-db/rqlite/rqlite-8.36.8.ebuild b/dev-db/rqlite/rqlite-8.36.8.ebuild new file mode 100644 index 000000000000..bda6343912e9 --- /dev/null +++ b/dev-db/rqlite/rqlite-8.36.8.ebuild @@ -0,0 +1,45 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit go-module +EGIT_COMMIT=768eafc309ff05a57d041d2b19f67994ce83a5c5 + +DESCRIPTION="Replicated SQLite using the Raft consensus protocol" +HOMEPAGE="https://github.com/rqlite/rqlite https://www.philipotoole.com/tag/rqlite/" +SRC_URI="https://github.com/rqlite/rqlite/archive/v${PV}.tar.gz -> ${P}.tar.gz + https://dev.gentoo.org/~zmedico/dist/${P}-deps.tar.xz" + +LICENSE="MIT" +LICENSE+=" Apache-2.0 BSD CC0-1.0 MPL-2.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +src_unpack() { + default +} + +src_prepare() { + ln -sv ../vendor ./ || die + default +} + +src_compile() { + GOBIN="${S}/bin" \ + ego install \ + -ldflags="-X main.version=v${PV} + -X main.branch=master + -X main.commit=${EGIT_COMMIT} + -X main.buildtime=$(date +%Y-%m-%dT%T%z)" \ + ./cmd/... || die +} + +src_test() { + GOBIN="${S}/bin" \ + ego test ./... || die +} + +src_install() { + dobin bin/* + dodoc -r *.md DOC +} diff --git a/dev-db/sqlite/Manifest b/dev-db/sqlite/Manifest index f710b204a0dd..d244f358801f 100644 --- a/dev-db/sqlite/Manifest +++ b/dev-db/sqlite/Manifest @@ -1,10 +1,14 @@ AUX sqlite-3.45.1-ppc64-ptr.patch 986 BLAKE2B 8c97514a67601c1f51459c1d4ea683e023730b3fa66be7a238807f172ce19ebceeed8f81c9f6e4f3621c96eecd8f6ea3bd5669a8a5ee5b14cf2bebdb7338e0db SHA512 12c6384682a36cddfdde7d2cfdba8aad54441b816816abf139bb05c46f65e78548c5a9e4f7f8b8836bd95702455b93ed7e0afb868ab15fead20a84404f075615 AUX sqlite-3.47.1-buildtclext.patch 986 BLAKE2B ba43fd663a77a2a161a26f31ca3db0f4b08fae940a08b4bdfa7882a7945eef1b041f11d70cbe6754fe1bc58c533f2b5864e25a90c6d38e8f1c4f27f8cfc3bd91 SHA512 20ff9155832fc23984f91c3c7fc6ab775ab026fb4a3b7d97f00b67583702c81d714db1345a28050c1be39376d411b2faa137b25719d4d312ac42cf00c73ade47 +AUX sqlite-3.47.2-hwtime.h-Don-t-use-rdtsc-on-i486.patch 1114 BLAKE2B 00b386967c4b7051b762041f98555f078e7fe7427adc57efa7b1bd3c6cdee20e379b2d086535358014dd1bafbb97d552980620c29c4ea63047f2d3c68efa2907 SHA512 f3787a9628d73ccd8f4bad99e8d2f3c0153078c06b2864d9110b77e1aea6a22ee2db485d71aec9b94039bc5e2e4517eb194faac862b95775d70440e1857f7d4c DIST sqlite-doc-3460100.zip 10851427 BLAKE2B 7462e83ca84e3e9aac7236f575fd2bdddac7744ae700a63fe8fdc9d2df3157c59fd374d99a0526bd4d9f742005ee7a90f3d78057861d3c3fcba9f897630e48db SHA512 1ad7dfc938d182f69ea9367b4f5ead1d48b991626521249e8b58c9fb4c2553e348ce402de9cc81b0ad699d4c45c467de56a98ee39f9c3555c6fafff15fba41ce DIST sqlite-doc-3470200.zip 10957830 BLAKE2B cbc40dd440d1c5af4ad4333090a7306bd54ec43250a478b6900b8f74bd721035018ea7647f3a208d42cc0639827325be26a9412d17af7d390f4e584d4c6acf44 SHA512 48349d512b7cd9bc6f6a5da3a2b2285de159d4653667311adb0f5e6a970060db940a590c2d01b529afc1614065b22434d5b3ac4d8d0122d003d74926745ba56e +DIST sqlite-doc-3480000.zip 11391112 BLAKE2B d28531e5d3ac7802700636a669f165cb9fa2a6077422b1ba956b6b9e29db48941489b5a3bc1c4936723e59343e00c3edc9310db9724d914a30ac9aca775dc70d SHA512 d7cad0da8598a3abcacf0e05ba4e285ad1d790691e571e431f920abf1bf27c5a416408ff60ff051b01a65662c0e60bb63b9ba73872851fe63f379e834c5a0f04 DIST sqlite-src-3460100.zip 14276926 BLAKE2B df16ea944e317df8ed64fdfab289e3699ec71725ce55e2b30450adaeb41c061b4fba1eb8c41ba638b0edcd12b23264a1f9e413b69fd593c2b65fb1037d3fc8b2 SHA512 6d32a0db9f95d3cec34f02f3fd45b453bf7c422d4d4d9570790f641e7d190b8b31be8e8715afacc1b6e4417f15a4d15a0b28e608ae0b4b5f3054b075783b916e DIST sqlite-src-3470200.zip 14421983 BLAKE2B dcaea5be0099b2dad1b53403933f0037ace48b1f248040c1b5cc116ac2ad6c9b44c71b8efe3afd16bef01119b440d1a2ec9d553a22f855e0ba55793684f53d8d SHA512 a6280a02304bfae173d9e9ebf376b2d3624658f04af4d8e95d5a042e24cf0405a47c0a4023f4dbc2790716cd85e16b97fcc0a83c1534e6d554f4eb0bfb0a3ed3 +DIST sqlite-src-3480000.zip 14350897 BLAKE2B 1dafce5575cbf8eb4e7efb5c033322b887bcce38129756994da45b1d8e0cf136f337e6cb9fa3c4b5abcf1f68bff6763247bec1ad04975fc9de308e3b75fb4e54 SHA512 854832e9a5dc486a81934e36c1f1678ce50db55b8bd3c48ed2d569fb0bb7ce23d4b490c0a0f699274ff11ddf2000db4a620e064557084c54b217e7fdd836f4e1 EBUILD sqlite-3.46.1.ebuild 12792 BLAKE2B ca98f4e22e0ba7abdf3c1c8a785e82a6f64d19f186a68d9733fbe31db879c2d3d0b1b517b3ea3f0af5c678cd9c036a8702c4f3e87f3a20c5b4342e391fd720d9 SHA512 6633db1ba661ed8948e21ffb245f59f7507669224d3b827c16d4fc5332d9b2bd62f176066afc7f59ed5104b0a5d15dc4eb8ed91ba4ab55b2afb773d6026708a0 -EBUILD sqlite-3.47.2.ebuild 12813 BLAKE2B 5a292369ad42e33ba09cc14abe677e9dbbb3be51dfe2683ed702fe87ed051080998db2d467d4e786bb0e64db37ea19bfd3fc52d29324d17870b8070a0ab715c5 SHA512 10fb5442b44a2ed0706f0dc1de11179642b467368e61de03c6d585a7e44cad323830b8281c3367b1ba2b5444fe2ba87e4674bb12145b9f025e69a3fad43619aa -EBUILD sqlite-9999.ebuild 12715 BLAKE2B d79519648d078c7c19312f1df796e2e681c40f2992649fa21b146a5fd16d469656fe02c2a52292a1dff66b38d9ac8061cbc468b162a4051cef56b4d4f1a462cd SHA512 fc50a53d730f618f33c600bf7886e94176404908975da1e5f893916f36c86bf0c4135ee1469026d703483339994638076f0fdc884aa7bad802be2cfaf713dc92 +EBUILD sqlite-3.47.2-r1.ebuild 12880 BLAKE2B 6686cb865c8f3b68ea03077ef146753a3ae03bbc5dbce1e2224ca514c6b55b8bca6ec1702bd42984cbb96e4f6169e726e4748a931ddcc33e4af065e89d7f4b3e SHA512 c321faed21950909eb0abc4d32f22ab74e79f90577a25a6fad3f9f9c51f47b5337056a9a209f2781d0a45119a17c802165fbf0569748334011b43597c51aca47 +EBUILD sqlite-3.48.0-r1.ebuild 12904 BLAKE2B 6591d350c3e438a294ceb40f20dd4dc1afed28b8f792efb01ee4bcbf39824ec1ce289a7b052e6dcf100f0da58b2bb2e7dcc0a54364e593eedd86eb37223f5309 SHA512 58eb7c55b633ab9b0996be41dc8bf6373fcb842a75e9baa307d5bc2430776d78e7e54d1bc09bea20bcecf33f9baff374a43e026b6be234586040430f33d3fb03 +EBUILD sqlite-9999.ebuild 12795 BLAKE2B 6f9a80eb912680ef1d0f3fb183d0bd5327c9d312c11ca392312568861b104556ba54e8350611c7acc758360c42e33e2a0cbe3bc44d57c4be225e2d84a7cb69c6 SHA512 375ce352d2ddd96bfde025a82e9abff16c1713d5d6a8fc0d5ef15534d281f60a586e8d963d8a57c98ee2c7369e6fd3fc5eef9513cb5fea7a038dc8aa04876105 MISC metadata.xml 824 BLAKE2B 8ab2e8f230bf3a2b26077d90944bca7bf35ae905310205b90bf243365148488303256606c0ee7c3fb736300686466a1c2583bf103693c20063ca668fe9e52647 SHA512 ed4a89e3c2d633cb6ebf8bcbf3ca055d0d1b2ffd801ba559395f812faeaafdfedd97dae11a5a53a4c068e43026fbd4eed4cb12c8b89a7fda6dabe6f78a2e0b38 diff --git a/dev-db/sqlite/files/sqlite-3.47.2-hwtime.h-Don-t-use-rdtsc-on-i486.patch b/dev-db/sqlite/files/sqlite-3.47.2-hwtime.h-Don-t-use-rdtsc-on-i486.patch new file mode 100644 index 000000000000..499fe2d21bd9 --- /dev/null +++ b/dev-db/sqlite/files/sqlite-3.47.2-hwtime.h-Don-t-use-rdtsc-on-i486.patch @@ -0,0 +1,33 @@ +https://sqlite.org/forum/forumpost/45f76411c1 + +From 0f2389e42ec65fd925e1bce608f382f3b35ee0f6 Mon Sep 17 00:00:00 2001 +From: Sam James <sam@gentoo.org> +Date: Sat, 25 Jan 2025 12:10:24 +0000 +Subject: [PATCH] hwtime.h: Don't use rdtsc on i486 + +If -DSQLITE_ENABLE_STMT_SCANSTATUS is passed, rdtsc is used for profiling +purposes, but that's not available on i486 CPUs (e.g. Soekris 4501 / AMD Elan +in the linked bug). + +Just look for i586 instead of i386. For the i386/i486 case, it's fine if we +use the stub implementation. This feels cleaner than toggling functionality +in the ebuild, even if it's unlikely anyone on i486 is going to use that. + +Thanks to amonakov who found the problem quickly and the relevant part of SQLite. + +Bug: https://bugs.gentoo.org/948671 +Signed-off-by: Sam James <sam@gentoo.org> +--- a/src/hwtime.h ++++ b/src/hwtime.h +@@ -24,7 +24,7 @@ + */ + #if !defined(__STRICT_ANSI__) && \ + (defined(__GNUC__) || defined(_MSC_VER)) && \ +- (defined(i386) || defined(__i386__) || defined(_M_IX86)) ++ (defined(i586) || defined(__i586__) || defined(_M_IX86)) + + #if defined(__GNUC__) + +-- +2.48.1 + diff --git a/dev-db/sqlite/sqlite-3.47.2.ebuild b/dev-db/sqlite/sqlite-3.47.2-r1.ebuild index ca490c5917e3..044a48ee68f5 100644 --- a/dev-db/sqlite/sqlite-3.47.2.ebuild +++ b/dev-db/sqlite/sqlite-3.47.2-r1.ebuild @@ -53,6 +53,7 @@ fi PATCHES=( "${FILESDIR}"/${PN}-3.45.1-ppc64-ptr.patch "${FILESDIR}"/${PN}-3.47.1-buildtclext.patch + "${FILESDIR}"/${PN}-3.47.2-hwtime.h-Don-t-use-rdtsc-on-i486.patch ) _fossil_fetch() { diff --git a/dev-db/sqlite/sqlite-3.48.0-r1.ebuild b/dev-db/sqlite/sqlite-3.48.0-r1.ebuild new file mode 100644 index 000000000000..1e772cac840d --- /dev/null +++ b/dev-db/sqlite/sqlite-3.48.0-r1.ebuild @@ -0,0 +1,431 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit flag-o-matic multilib-minimal toolchain-funcs + +DESCRIPTION="SQL database engine" +HOMEPAGE="https://sqlite.org/" + +# On version updates, make sure to read the forum (https://sqlite.org/forum/forum) +# for hints regarding test failures, backports, etc. +if [[ ${PV} == 9999 ]]; then + S="${WORKDIR}"/${PN} + PROPERTIES="live" +else + printf -v SRC_PV "%u%02u%02u%02u" $(ver_rs 1- " ") + DOC_PV="${SRC_PV}" + #printf -v DOC_PV "%u%02u%02u00" $(ver_rs 1-3 " ") + + SRC_URI=" + https://sqlite.org/2025/${PN}-src-${SRC_PV}.zip + doc? ( https://sqlite.org/2025/${PN}-doc-${DOC_PV}.zip ) + " + S="${WORKDIR}/${PN}-src-${SRC_PV}" + + #KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris" +fi + +LICENSE="public-domain" +SLOT="3" +IUSE="debug doc icu +readline secure-delete static-libs tcl test tools" +RESTRICT="!test? ( test )" + +RDEPEND=" + sys-libs/zlib:=[${MULTILIB_USEDEP}] + icu? ( dev-libs/icu:=[${MULTILIB_USEDEP}] ) + readline? ( sys-libs/readline:=[${MULTILIB_USEDEP}] ) + tcl? ( dev-lang/tcl:=[${MULTILIB_USEDEP}] ) + tools? ( dev-lang/tcl:= ) +" +DEPEND=" + ${RDEPEND} + test? ( >=dev-lang/tcl-8.6:0[${MULTILIB_USEDEP}] ) +" +if [[ ${PV} == 9999 ]]; then + BDEPEND+=" dev-vcs/fossil" +else + BDEPEND+=" app-arch/unzip" +fi + +PATCHES=( + "${FILESDIR}"/${PN}-3.47.2-hwtime.h-Don-t-use-rdtsc-on-i486.patch +) + +_fossil_fetch() { + local distdir="${PORTAGE_ACTUAL_DISTDIR:-${DISTDIR}}" + local repo_id="${1}" + local repo_uri="${2}" + + local -x FOSSIL_HOME="${HOME}" + + mkdir -p "${T}/fossil/${repo_id}" || die + pushd "${T}/fossil/${repo_id}" > /dev/null || die + + if [[ -n "${EVCS_OFFLINE}" ]]; then + if [[ ! -f "${distdir}/fossil-src/${repo_id}/${repo_id}.fossil" ]]; then + die "Network activity disabled using EVCS_OFFLINE and clone of repository missing: \"${distdir}/fossil-src/${repo_id}/${repo_id}.fossil\"" + fi + else + if [[ ! -f "${distdir}/fossil-src/${repo_id}/${repo_id}.fossil" ]]; then + einfo fossil clone --verbose "${repo_uri}" "${repo_id}.fossil" + fossil clone --verbose "${repo_uri}" "${repo_id}.fossil" || die + echo + else + cp -p "${distdir}/fossil-src/${repo_id}/${repo_id}.fossil" . || die + einfo fossil pull --repository "${repo_id}.fossil" --verbose "${repo_uri}" + fossil pull --repository "${repo_id}.fossil" --verbose "${repo_uri}" || die + echo + fi + + ( + addwrite "${distdir}" + mkdir -p "${distdir}/fossil-src/${repo_id}" || die + cp -p "${repo_id}.fossil" "${distdir}/fossil-src/${repo_id}/${repo_id}.fossil" || die + ) + fi + + popd > /dev/null || die +} + +_fossil_checkout() { + local distdir="${PORTAGE_ACTUAL_DISTDIR:-${DISTDIR}}" + local repo_id="${1}" + local branch_or_commit="${2}" + local target_directory="${3}" + + local -x FOSSIL_HOME="${HOME}" + + if [[ ! -f "${distdir}/fossil-src/${repo_id}/${repo_id}.fossil" ]]; then + die "Clone of repository missing: \"${distdir}/fossil-src/${repo_id}/${repo_id}.fossil\"" + fi + + if [[ ! -f "${T}/fossil/${repo_id}/${repo_id}.fossil" ]]; then + mkdir -p "${T}/fossil/${repo_id}" || die + cp -p "${distdir}/fossil-src/${repo_id}/${repo_id}.fossil" "${T}/fossil/${repo_id}" || die + fi + + mkdir "${target_directory}" || die + pushd "${target_directory}" > /dev/null || die + + einfo fossil open --quiet "${T}/fossil/${repo_id}/${repo_id}.fossil" "${branch_or_commit}" + fossil open --quiet "${T}/fossil/${repo_id}/${repo_id}.fossil" "${branch_or_commit}" || die + echo + + popd > /dev/null || die +} + +fossil_fetch() { + local repo_id="${1}" + local repo_uri="${2}" + local target_directory="${3}" + + local branch_or_commit="${EFOSSIL_COMMIT:-${EFOSSIL_BRANCH:-trunk}}" + + _fossil_fetch "${repo_id}" "${repo_uri}" + _fossil_checkout "${repo_id}" "${branch_or_commit}" "${target_directory}" +} + +src_unpack() { + if [[ ${PV} == 9999 ]]; then + fossil_fetch sqlite https://sqlite.org/src "${WORKDIR}/${PN}" + if use doc; then + fossil_fetch sqlite-doc https://sqlite.org/docsrc "${WORKDIR}/${PN}-doc" + fi + else + default + fi +} + +src_prepare() { + + # Avoid stripping during the install phase + sed -i -e 's/$(INSTALL) -s /$(INSTALL) /' main.mk || die + default + + multilib_copy_sources +} + +multilib_src_configure() { + local -x CPPFLAGS="${CPPFLAGS}" CFLAGS="${CFLAGS}" + local options=() + + options+=( + --enable-load-extension + --enable-threadsafe + ) + + # Support detection of misuse of SQLite API. + # https://sqlite.org/compile.html#enable_api_armor + append-cppflags -DSQLITE_ENABLE_API_ARMOR + + # Support bytecode and tables_used virtual tables. + # https://sqlite.org/compile.html#enable_bytecode_vtab + # https://sqlite.org/bytecodevtab.html + append-cppflags -DSQLITE_ENABLE_BYTECODE_VTAB + + # Support column metadata functions. + # https://sqlite.org/compile.html#enable_column_metadata + # https://sqlite.org/c3ref/column_database_name.html + append-cppflags -DSQLITE_ENABLE_COLUMN_METADATA + + # Support sqlite_dbpage virtual table. + # https://sqlite.org/compile.html#enable_dbpage_vtab + # https://sqlite.org/dbpage.html + append-cppflags -DSQLITE_ENABLE_DBPAGE_VTAB + + # Support dbstat virtual table. + # https://sqlite.org/compile.html#enable_dbstat_vtab + # https://sqlite.org/dbstat.html + append-cppflags -DSQLITE_ENABLE_DBSTAT_VTAB + + # Support sqlite3_serialize() and sqlite3_deserialize() functions. + # https://sqlite.org/compile.html#enable_deserialize + # https://sqlite.org/c3ref/serialize.html + # https://sqlite.org/c3ref/deserialize.html + append-cppflags -DSQLITE_ENABLE_DESERIALIZE + + # Support comments in output of EXPLAIN. + # https://sqlite.org/compile.html#enable_explain_comments + append-cppflags -DSQLITE_ENABLE_EXPLAIN_COMMENTS + + # Support Full-Text Search versions 3, 4 and 5. + # https://sqlite.org/compile.html#enable_fts3 + # https://sqlite.org/compile.html#enable_fts3_parenthesis + # https://sqlite.org/compile.html#enable_fts4 + # https://sqlite.org/compile.html#enable_fts5 + # https://sqlite.org/fts3.html + # https://sqlite.org/fts5.html + append-cppflags -DSQLITE_ENABLE_FTS3 -DSQLITE_ENABLE_FTS3_PARENTHESIS -DSQLITE_ENABLE_FTS4 + options+=( --enable-fts5 ) + + # Support hidden columns. + append-cppflags -DSQLITE_ENABLE_HIDDEN_COLUMNS + + # Support memsys5 memory allocator. + # https://sqlite.org/compile.html#enable_memsys5 + # https://sqlite.org/malloc.html#memsys5 + append-cppflags -DSQLITE_ENABLE_MEMSYS5 + + # Support sqlite3_normalized_sql() function. + # https://sqlite.org/c3ref/expanded_sql.html + append-cppflags -DSQLITE_ENABLE_NORMALIZE + + # Support sqlite_offset() function. + # https://sqlite.org/compile.html#enable_offset_sql_func + # https://sqlite.org/lang_corefunc.html#sqlite_offset + append-cppflags -DSQLITE_ENABLE_OFFSET_SQL_FUNC + + # Support pre-update hook functions. + # https://sqlite.org/compile.html#enable_preupdate_hook + # https://sqlite.org/c3ref/preupdate_count.html + append-cppflags -DSQLITE_ENABLE_PREUPDATE_HOOK + + # Support Resumable Bulk Update extension. + # https://sqlite.org/compile.html#enable_rbu + # https://sqlite.org/rbu.html + append-cppflags -DSQLITE_ENABLE_RBU + + # Support R*Trees. + # https://sqlite.org/compile.html#enable_rtree + # https://sqlite.org/compile.html#enable_geopoly + # https://sqlite.org/rtree.html + # https://sqlite.org/geopoly.html + append-cppflags -DSQLITE_ENABLE_RTREE -DSQLITE_ENABLE_GEOPOLY + + # Support Session extension. + # https://sqlite.org/compile.html#enable_session + # https://sqlite.org/sessionintro.html + append-cppflags -DSQLITE_ENABLE_SESSION + + # Support scan status functions. + # https://sqlite.org/compile.html#enable_stmt_scanstatus + # https://sqlite.org/c3ref/stmt_scanstatus.html + # https://sqlite.org/c3ref/stmt_scanstatus_reset.html + append-cppflags -DSQLITE_ENABLE_STMT_SCANSTATUS + + # Support sqlite_stmt virtual table. + # https://sqlite.org/compile.html#enable_stmtvtab + # https://sqlite.org/stmt.html + append-cppflags -DSQLITE_ENABLE_STMTVTAB + + # Support unknown() function. + # https://sqlite.org/compile.html#enable_unknown_sql_function + append-cppflags -DSQLITE_ENABLE_UNKNOWN_SQL_FUNCTION + + # Support unlock notification. + # https://sqlite.org/compile.html#enable_unlock_notify + # https://sqlite.org/c3ref/unlock_notify.html + # https://sqlite.org/unlock_notify.html + append-cppflags -DSQLITE_ENABLE_UNLOCK_NOTIFY + + # Support LIMIT and ORDER BY clauses on DELETE and UPDATE statements. + # https://sqlite.org/compile.html#enable_update_delete_limit + # https://sqlite.org/lang_delete.html#optional_limit_and_order_by_clauses + # https://sqlite.org/lang_update.html#optional_limit_and_order_by_clauses + append-cppflags -DSQLITE_ENABLE_UPDATE_DELETE_LIMIT + + # Support soundex() function. + # https://sqlite.org/compile.html#soundex + # https://sqlite.org/lang_corefunc.html#soundex + append-cppflags -DSQLITE_SOUNDEX + + # Support URI filenames. + # https://sqlite.org/compile.html#use_uri + # https://sqlite.org/uri.html + append-cppflags -DSQLITE_USE_URI + + options+=( $(use_enable debug) ) + + if use icu; then + # Support ICU extension. + # https://sqlite.org/compile.html#enable_icu + options+=( --with-icu-config ) + fi + + options+=( + --disable-editline + $(use_enable readline) + ) + + if use readline; then + options+=( --with-readline-inc="-I${ESYSROOT}/usr/include/readline" ) + fi + + if use secure-delete; then + # Enable secure_delete pragma by default. + # https://sqlite.org/compile.html#secure_delete + # https://sqlite.org/pragma.html#pragma_secure_delete + append-cppflags -DSQLITE_SECURE_DELETE + fi + + options+=( $(use_enable static-libs static) ) + + # tcl, test, tools USE flags. + if use tcl || use test || { use tools && multilib_is_native_abi; }; then + options+=( + --enable-tcl + --with-tcl="${ESYSROOT}/usr/$(get_libdir)" + ) + else + options+=( --disable-tcl ) + fi + + if [[ "${ABI}" == "x86" ]]; then + if $(tc-getCC) ${CPPFLAGS} ${CFLAGS} -E -P -dM - < /dev/null 2> /dev/null | grep -q "^#define __SSE__ 1$"; then + append-cflags -mfpmath=sse + else + append-cflags -ffloat-store + fi + fi + + # set SONAME for the library + options+=( --soname=legacy ) + + # https://sqlite.org/forum/forumpost/4f4d06a9f6683bb9 + tc-export CC + CC_FOR_BUILD=${CC} econf "${options[@]}" +} + +multilib_src_compile() { + emake HAVE_TCL="$(usev tcl 1)" TCLLIBDIR="${EPREFIX}/usr/$(get_libdir)/${P}" + + if use tools && multilib_is_native_abi; then + emake changeset dbdump dbhash dbtotxt index_usage rbu scrub showdb showjournal showshm showstat4 showwal sqldiff sqlite3_analyzer sqlite3_checker sqlite3_expert sqltclsh + fi + + if [[ ${PV} == 9999 ]] && use doc && multilib_is_native_abi; then + emake tclsqlite3.c + + local build_directory="$(pwd)" + build_directory="${build_directory##*/}" + + mkdir "${WORKDIR}/${PN}-doc-build" || die + pushd "${WORKDIR}/${PN}-doc-build" > /dev/null || die + + emake -f "../${PN}-doc/Makefile" -j1 SRC="../${PN}" BLD="../${build_directory}" DOC="../${PN}-doc" CC="$(tc-getBUILD_CC)" TCLINC="" TCLFLAGS="$($(tc-getBUILD_PKG_CONFIG) --libs tcl) -ldl -lm" base doc + rmdir doc/matrix{/*,} || die + + popd > /dev/null || die + fi +} + +multilib_src_test() { + if [[ "${EUID}" -eq 0 ]]; then + ewarn "Skipping tests due to root permissions" + return + fi + + local -x SQLITE_HISTORY="${T}/sqlite_history_${ABI}" + + # e_uri.test tries to open files in /. + # bug #839798 + local SANDBOX_PREDICT=${SANDBOX_PREDICT} + addpredict "/test.db" + addpredict "/ΓΏ.db" + + emake -Onone $(usex debug 'fulltest' 'test') +} + +multilib_src_install() { + emake DESTDIR="${D}" HAVE_TCL="$(usex tcl 1 "")" TCLLIBDIR="${EPREFIX}/usr/$(get_libdir)/${P}" install + + if use tools && multilib_is_native_abi; then + install_tool() { + if [[ -f ".libs/${1}" ]]; then + newbin ".libs/${1}" "${2}" + else + newbin "${1}" "${2}" + fi + } + + install_tool changeset sqlite3-changeset + install_tool dbdump sqlite3-db-dump + install_tool dbhash sqlite3-db-hash + install_tool dbtotxt sqlite3-db-to-txt + install_tool index_usage sqlite3-index-usage + install_tool rbu sqlite3-rbu + install_tool scrub sqlite3-scrub + install_tool showdb sqlite3-show-db + install_tool showjournal sqlite3-show-journal + install_tool showshm sqlite3-show-shm + install_tool showstat4 sqlite3-show-stat4 + install_tool showwal sqlite3-show-wal + install_tool sqldiff sqlite3-diff + install_tool sqlite3_analyzer sqlite3-analyzer + install_tool sqlite3_checker sqlite3-checker + install_tool sqlite3_expert sqlite3-expert + install_tool sqltclsh sqlite3-tclsh + + unset -f install_tool + fi +} + +multilib_src_install_all() { + find "${ED}" -name "*.la" -delete || die + + doman sqlite3.1 + + if use doc; then + if [[ ${PV} == 9999 ]]; then + pushd "${WORKDIR}/${PN}-doc-build/doc" > /dev/null || die + else + pushd "${WORKDIR}/${PN}-doc-${DOC_PV}" > /dev/null || die + fi + + find "(" -name "*.db" -o -name "*.txt" ")" -delete || die + if [[ ${PV} != 9999 ]]; then + rm search search.d/admin || die + rmdir search.d || die + find -name "*~" -delete || die + fi + + ( + docinto html + dodoc -r * + ) + + popd > /dev/null || die + fi +} diff --git a/dev-db/sqlite/sqlite-9999.ebuild b/dev-db/sqlite/sqlite-9999.ebuild index 53686a767f9b..e0fe683ea625 100644 --- a/dev-db/sqlite/sqlite-9999.ebuild +++ b/dev-db/sqlite/sqlite-9999.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -50,6 +50,10 @@ else BDEPEND+=" app-arch/unzip" fi +PATCHES=( + "${FILESDIR}"/${PN}-3.47.2-hwtime.h-Don-t-use-rdtsc-on-i486.patch +) + _fossil_fetch() { local distdir="${PORTAGE_ACTUAL_DISTDIR:-${DISTDIR}}" local repo_id="${1}" diff --git a/dev-db/sqlitebrowser/Manifest b/dev-db/sqlitebrowser/Manifest index a05b013ae44c..498f8cc4a91f 100644 --- a/dev-db/sqlitebrowser/Manifest +++ b/dev-db/sqlitebrowser/Manifest @@ -1,5 +1,5 @@ AUX sqlitebrowser-3.13.1-missing-include.patch 657 BLAKE2B 2ac7b01ee6f55e8ad3859369128782d7ff685585f40e572f8ff99c57da5e459e3b0a6daf649997c8e17ce2ba68343f350a2f6c96bb4e015a69f4185e6b1848f1 SHA512 851c751130ff7f63a74d9b8518ea1576f0fa8b00330fe7cb4c271a8a3f350b24f5de8a46147b0a13836df966ca9f600e75d3fdadc9591219c34a3e965d27eb79 DIST sqlitebrowser-3.13.1.tar.gz 4923092 BLAKE2B 894790cc30b802b4aab19a8e7834aef1bf68b027bcd66b63901269d6d44b706ce5ddca1ae4ca4743d14f9a8d2a5cc6005711b6ee25cef068c55e0b01c56f8b5c SHA512 7482094823293a216e4df20105d1351a23fcc706fd9e64bca58cd1c6a46dcf639a945f919613f1a9550d0a15e60a4c2827ee5eee4f89a7b11046d8eefbf375ee -EBUILD sqlitebrowser-3.13.1.ebuild 1734 BLAKE2B a628022850b5713829fc91acaab3bc37c9a34533e9f08e98c8f8f31ad902ea6106ec9d0d952d5d02ee873b6f2f063579c41a3fc2f1d56dfde80d3b5787aa4743 SHA512 2af2a22aabdb964dfcfb49665e674a456b939eb9dcc5a825b6f67cdd4c29b24134a7f5ca29bafa822427823b6346f87b97738a229ad708ff3b4f3c7a0857e800 -EBUILD sqlitebrowser-9999.ebuild 1682 BLAKE2B 8ff3453dc827f8f28cab66a28186188cb2952854fd5bac3cc71a98be8ecdbb0ace7606f169d47bb7534660dde82e16d04aa9089e2f57e2e30b68b966f08c3c8f SHA512 b915e698b86cfbc20623c56c6a4dad0104b0f87bf14e5c8c64ed22442ae14731c00cd2d456a088c2d07137c9a756e71fd95c51fe6e3457567b1e6d5e4c345291 +EBUILD sqlitebrowser-3.13.1-r1.ebuild 1755 BLAKE2B f2b451b4280e3b9f22a3b6ff57e3955bee247f17cf9c7b898cad8657abefd3aca475430c8e1d5d59ae672dcbc1168a7a17e834751cab296fd8aea960bffdd616 SHA512 a0c10c94411c378047cb5c4e3c4b5c2ac44f0241718e095759346778c3b30a895de62e72df90490d9cf3699830b0822109ff2a469cfe977becf042f7825160e5 +EBUILD sqlitebrowser-9999.ebuild 1333 BLAKE2B 872c1b158cf5a7af79a13e0b39154df4b4831ec43ada2daa2518b358641f4019856b038d6a9e05953f2af7fc419f85c1d448210e82dab8a56e110fb54feae9ee SHA512 6006c2585eb00b56e0dc101e58c1332fc47b9ced91dc0dab83af3a44faacd226c51ca2bb4dc4e7ccdf0a9e774d3580f6a14549d7fc2af2efd9ab6b7e3ef8881e MISC metadata.xml 1796 BLAKE2B 988ec79d4d043ecbf8802aa3d761868479fc0a398a00035c387aa4b362e2c6c59afbbd04d648d2084aa0d9d35972336cd312c4b596e663e5142ce72671e70a55 SHA512 6b0e05517590c7c56cabc1bfecfafed155be78ccff4d159fd810b3c8e6555559c45fba3ea3bdf0aef73d1c1a1d8fcabc7005c2e7dbb3b6377d14505c819355d7 diff --git a/dev-db/sqlitebrowser/sqlitebrowser-3.13.1.ebuild b/dev-db/sqlitebrowser/sqlitebrowser-3.13.1-r1.ebuild index 14bd66fc1cf2..3b7c7308fe49 100644 --- a/dev-db/sqlitebrowser/sqlitebrowser-3.13.1.ebuild +++ b/dev-db/sqlitebrowser/sqlitebrowser-3.13.1-r1.ebuild @@ -5,10 +5,10 @@ EAPI=8 inherit cmake flag-o-matic xdg -DESCRIPTION="A light GUI editor for SQLite databases" +DESCRIPTION="Light GUI editor for SQLite databases" HOMEPAGE="https://sqlitebrowser.org/" -if [[ "${PV}" = 9999 ]]; then +if [[ ${PV} == *9999* ]]; then inherit git-r3 EGIT_REPO_URI="https://github.com/sqlitebrowser/sqlitebrowser.git" else @@ -22,16 +22,16 @@ IUSE="sqlcipher test" RESTRICT="!test? ( test )" RDEPEND=" - app-editors/qhexedit2 + <app-editors/qhexedit2-0.8.10 dev-db/sqlite:3 - dev-libs/qcustomplot + <dev-libs/qcustomplot-2.1.1-r10 >=dev-qt/qtcore-5.15.9:5 >=dev-qt/qtgui-5.15.9:5 >=dev-qt/qtnetwork-5.15.9:5[ssl] >=dev-qt/qtprintsupport-5.15.9:5 >=dev-qt/qtwidgets-5.15.9:5 >=dev-qt/qtxml-5.15.9:5 - >=x11-libs/qscintilla-2.8.10:=[qt5(+)] + >=x11-libs/qscintilla-2.14.1-r1:=[qt5(-)] sqlcipher? ( dev-db/sqlcipher ) " DEPEND="${RDEPEND} diff --git a/dev-db/sqlitebrowser/sqlitebrowser-9999.ebuild b/dev-db/sqlitebrowser/sqlitebrowser-9999.ebuild index a423fd763348..9ff0f452d75b 100644 --- a/dev-db/sqlitebrowser/sqlitebrowser-9999.ebuild +++ b/dev-db/sqlitebrowser/sqlitebrowser-9999.ebuild @@ -5,10 +5,10 @@ EAPI=8 inherit cmake flag-o-matic xdg -DESCRIPTION="A light GUI editor for SQLite databases" +DESCRIPTION="Light GUI editor for SQLite databases" HOMEPAGE="https://sqlitebrowser.org/" -if [[ "${PV}" = 9999 ]]; then +if [[ ${PV} == *9999* ]]; then inherit git-r3 EGIT_REPO_URI="https://github.com/sqlitebrowser/sqlitebrowser.git" else @@ -22,46 +22,28 @@ IUSE="sqlcipher test" RESTRICT="!test? ( test )" RDEPEND=" - app-editors/qhexedit2 + >=app-editors/qhexedit2-0.8.10 dev-db/sqlite:3 - dev-libs/qcustomplot - >=dev-qt/qtcore-5.15.9:5 - >=dev-qt/qtgui-5.15.9:5 - >=dev-qt/qtnetwork-5.15.9:5[ssl] - >=dev-qt/qtprintsupport-5.15.9:5 - >=dev-qt/qtwidgets-5.15.9:5 - >=dev-qt/qtxml-5.15.9:5 - >=x11-libs/qscintilla-2.8.10:=[qt5(+)] + >=dev-libs/qcustomplot-2.1.1-r10 + dev-qt/qtbase:6[gui,network,ssl,widgets,xml] + >=x11-libs/qscintilla-2.14.1-r1:=[qt6(+)] sqlcipher? ( dev-db/sqlcipher ) " DEPEND="${RDEPEND} - >=dev-qt/qtconcurrent-5.15.9:5 -" -BDEPEND=" - >=dev-qt/linguist-tools-5.15.9:5 - test? ( >=dev-qt/qttest-5.15.9:5 ) + dev-qt/qtbase:6[concurrent] " +BDEPEND="dev-qt/qttools:6[linguist]" DOCS=( images/ {BUILDING,CHANGELOG,README}.md ) -src_prepare() { - cmake_src_prepare - - if ! use test; then - sed -i CMakeLists.txt \ - -e "/find_package/ s/ Test//" \ - -e "/set/ s/ Qt5::Test//" \ - || die "Cannot remove Qt Test from CMake dependencies" - fi -} - src_configure() { local mycmakeargs=( - -DENABLE_TESTING=$(usex test) + -DQT_MAJOR=Qt6 -DFORCE_INTERNAL_QSCINTILLA=OFF -DFORCE_INTERNAL_QCUSTOMPLOT=OFF -DFORCE_INTERNAL_QHEXEDIT=OFF -Dsqlcipher=$(usex sqlcipher) + -DENABLE_TESTING=$(usex test) ) # https://bugs.gentoo.org/855254 diff --git a/dev-db/timescaledb/Manifest b/dev-db/timescaledb/Manifest index 3e9fda6ec93f..37e89b7cb56b 100644 --- a/dev-db/timescaledb/Manifest +++ b/dev-db/timescaledb/Manifest @@ -1,9 +1,5 @@ -DIST timescaledb-2.16.1.tar.gz 7449327 BLAKE2B 4eac0f41596db1b7669850cbb576a2d710998f7207f566fb9b4965804e6810f1571d18058a126acdae7862bf77424db44f27720f3600d1191ae1a3c3cf8680ae SHA512 4972ccc385a3c7bda8fab8736c63f75c5b290a3a0206add84718326fcd07c24a52dbbae2114e857fb78246bf5a4b5ec3310cc2219a163af4d5f30f1766e37fae -DIST timescaledb-2.17.0.tar.gz 7559829 BLAKE2B 59ae1acabd9cc2657eaef04b42a2e4a9a633bf6dca0080897b2c0645ad2faa3b82c0f693ea121fbda8becf4088877b87f5aac8cf300d73ba85b3226a057ea5e0 SHA512 0c10f04b62e6e57da0e53234d25b82e68724a7925fd8696a9872e2934cbd1a7af9798576afceb504d4a7207ef8b0407421bbeeb4a3deef0f4b4ad17c2753443c -DIST timescaledb-2.17.1.tar.gz 7565025 BLAKE2B 8d8325e06739201d17e0da19173ee852abb10c0646d5f3647c51a6c209c1c6df30bc03ee8682e082652fb8d26a0b9bedf5c6014ed143b0af530b450664f6e14f SHA512 f5cd527f1b37e228c7caaad0b9a9802b1cef3b0b4a856951e46e74479263f4fef6190cc37c920ca5819ddd6874ff469645f606eeadec6741b83e82adb8c21f22 DIST timescaledb-2.17.2.tar.gz 7567447 BLAKE2B c2d5d9883377ffce57184c9c29413d12a41c7ef7891abb088aa72d0d7c410db28370c53585d7ec286fd52b3fe5c89b10f3b6deb547b6a1de132dc9c6697aa8cb SHA512 fc74d41062735bd4136ac71b0e10aecf34a64cdb29fd2ff31eae3f406beb8db00866e8ed7e142d47852e1586a6ad2ffa1652fbd792a45e995174b62464963d1e -EBUILD timescaledb-2.16.1.ebuild 1434 BLAKE2B 77976343740622bfde842b51055bce458295dc7304c82f9e06cfc510c9899954e85bf7f0c2f86ab0d8a9b47f1a956fba2102d889f4609c68d6898f59c7a7c5b1 SHA512 19ec48b1c738f884542b6c25cfbf5723727af5b7aba21889ee9a152721432a692feb3f59cd43c2cea0d173d3cdbe2fdba5fa5b0dc50e40563d8c14dddd9179d5 -EBUILD timescaledb-2.17.0.ebuild 1437 BLAKE2B 8e0fb37cb92aef40b53608eab5a06496c105a8015fa4065387ebd0ee54c08fe6fc0ba3383b2d1a7767e085016a4e00a089e67bd72769f7f5f4b45bbee0b15958 SHA512 22a62409c4d0e710279f9227b10b20d2df9a7c977d30a2d45c2ab829a29638909d75e5fb16c3146ce8d64a0a702e77935e27d6d910f9cfc4265611dc72c69119 -EBUILD timescaledb-2.17.1.ebuild 1437 BLAKE2B 8e0fb37cb92aef40b53608eab5a06496c105a8015fa4065387ebd0ee54c08fe6fc0ba3383b2d1a7767e085016a4e00a089e67bd72769f7f5f4b45bbee0b15958 SHA512 22a62409c4d0e710279f9227b10b20d2df9a7c977d30a2d45c2ab829a29638909d75e5fb16c3146ce8d64a0a702e77935e27d6d910f9cfc4265611dc72c69119 +DIST timescaledb-2.18.0.tar.gz 7890767 BLAKE2B 84cdb9673893290b835500b8a22436e1a9f19d13e9a85dc9a34b31f246d647fc3cc0a54be5676e381eb3161b7e6bb9e79447dbe0ed4a265b93e66871dbd577ed SHA512 6a41c49b0262064d70e6b754a95a3914b43b518523c63a9a9604612df2188117733b237330cb28ffe5d7da10e64e7db11fe952b976878dff5624c799d8d37220 EBUILD timescaledb-2.17.2.ebuild 1435 BLAKE2B 5db2df97f1a3a553fddba3f1335f0c8ed0d559373db4846a6512ef7ba1312f8c29eb85add3e87cb430718ecffbf70cab8ae3a00553a297d2acbba0335fb0aff6 SHA512 73a4680b81449792ad256be52140d1f07d424793cfa94c080ae2f46f60209710780a0a21df8a802a2bfb1d2931d8ea3743829502cae14bc60f80630f1c6562af +EBUILD timescaledb-2.18.0.ebuild 1435 BLAKE2B 1bd8f483ef831456a7563048d026823be7590446a8911c2e94a81000d45b650200c2fd142d824d2b102e6aaf42c9cac292526b5ea36f61b1b9d0b49eabab4c18 SHA512 f24d023333f77a160a67ce44a5f3b51210d609969c86b269561af4ddf3d17debb95891636ff645790a6915c4ec97a91f56676c7d11452d08808fe877621df929 MISC metadata.xml 510 BLAKE2B 4e96707c6ee1fd09ff2baff091e02ceab53bfc28a6a3b91265a21fe9918a9728d2fe6394bed01e8bf4417c2349c2e72bab180cfff71cedf4641d462b29a33d3d SHA512 5e91ef3b9a503462dc880300e364f74e6564dd74671d0b0ce723a86ea7471f987424e06e51384d6fb079681122b8d454e255efe2e19726d64de7928df227148a diff --git a/dev-db/timescaledb/timescaledb-2.16.1.ebuild b/dev-db/timescaledb/timescaledb-2.16.1.ebuild deleted file mode 100644 index 8e453121b6c0..000000000000 --- a/dev-db/timescaledb/timescaledb-2.16.1.ebuild +++ /dev/null @@ -1,67 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -POSTGRES_COMPAT=( 14 15 16 ) -POSTGRES_USEDEP="ssl" - -inherit postgres-multi cmake - -DESCRIPTION="Open-source time-series SQL database" -HOMEPAGE="https://www.timescale.com/" -SRC_URI="https://github.com/timescale/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" - -IUSE="proprietary-extensions" -LICENSE="POSTGRESQL Apache-2.0 proprietary-extensions? ( timescale )" - -KEYWORDS="~amd64" - -SLOT=0 - -RESTRICT="test" - -DEPEND="${POSTGRES_DEP}" -RDEPEND="${DEPEND}" - -CMAKE_IN_SOURCE_BUILD=yes -CMAKE_BUILD_TYPE="RelWithDebInfo" -BUILD_DIR=${WORKDIR}/${P} - -src_prepare() { - postgres-multi_src_prepare - postgres-multi_foreach cmake_src_prepare -} - -timescale_configure() { - local CMAKE_USE_DIR=$BUILD_DIR - local mycmakeargs=( "-DPG_CONFIG=/usr/bin/pg_config${MULTIBUILD_VARIANT}" "-DREGRESS_CHECKS=OFF" ) - - # licensing is tied to features, this useflag disables the non-apache2 licensed bits - if ! use proprietary-extensions ; then - mycmakeargs+=("-DAPACHE_ONLY=ON") - fi - cmake_src_configure -} - -src_configure() { - postgres-multi_foreach timescale_configure -} - -timescale_src_compile() { - local CMAKE_USE_DIR=$BUILD_DIR - cmake_src_compile -} - -src_compile() { - postgres-multi_foreach timescale_src_compile -} - -timescale_src_install() { - local CMAKE_USE_DIR=$BUILD_DIR - cmake_src_install -} - -src_install() { - postgres-multi_foreach timescale_src_install -} diff --git a/dev-db/timescaledb/timescaledb-2.17.0.ebuild b/dev-db/timescaledb/timescaledb-2.17.0.ebuild deleted file mode 100644 index ce49cb6c56ac..000000000000 --- a/dev-db/timescaledb/timescaledb-2.17.0.ebuild +++ /dev/null @@ -1,67 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -POSTGRES_COMPAT=( 14 15 16 17 ) -POSTGRES_USEDEP="ssl" - -inherit postgres-multi cmake - -DESCRIPTION="Open-source time-series SQL database" -HOMEPAGE="https://www.timescale.com/" -SRC_URI="https://github.com/timescale/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" - -IUSE="proprietary-extensions" -LICENSE="POSTGRESQL Apache-2.0 proprietary-extensions? ( timescale )" - -KEYWORDS="~amd64" - -SLOT=0 - -RESTRICT="test" - -DEPEND="${POSTGRES_DEP}" -RDEPEND="${DEPEND}" - -CMAKE_IN_SOURCE_BUILD=yes -CMAKE_BUILD_TYPE="RelWithDebInfo" -BUILD_DIR=${WORKDIR}/${P} - -src_prepare() { - postgres-multi_src_prepare - postgres-multi_foreach cmake_src_prepare -} - -timescale_configure() { - local CMAKE_USE_DIR=$BUILD_DIR - local mycmakeargs=( "-DPG_CONFIG=/usr/bin/pg_config${MULTIBUILD_VARIANT}" "-DREGRESS_CHECKS=OFF" ) - - # licensing is tied to features, this useflag disables the non-apache2 licensed bits - if ! use proprietary-extensions ; then - mycmakeargs+=("-DAPACHE_ONLY=ON") - fi - cmake_src_configure -} - -src_configure() { - postgres-multi_foreach timescale_configure -} - -timescale_src_compile() { - local CMAKE_USE_DIR=$BUILD_DIR - cmake_src_compile -} - -src_compile() { - postgres-multi_foreach timescale_src_compile -} - -timescale_src_install() { - local CMAKE_USE_DIR=$BUILD_DIR - cmake_src_install -} - -src_install() { - postgres-multi_foreach timescale_src_install -} diff --git a/dev-db/timescaledb/timescaledb-2.17.1.ebuild b/dev-db/timescaledb/timescaledb-2.18.0.ebuild index ce49cb6c56ac..93d772f03508 100644 --- a/dev-db/timescaledb/timescaledb-2.17.1.ebuild +++ b/dev-db/timescaledb/timescaledb-2.18.0.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -12,12 +12,10 @@ DESCRIPTION="Open-source time-series SQL database" HOMEPAGE="https://www.timescale.com/" SRC_URI="https://github.com/timescale/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" -IUSE="proprietary-extensions" LICENSE="POSTGRESQL Apache-2.0 proprietary-extensions? ( timescale )" - -KEYWORDS="~amd64" - SLOT=0 +KEYWORDS="~amd64" +IUSE="proprietary-extensions" RESTRICT="test" diff --git a/dev-db/unixODBC/Manifest b/dev-db/unixODBC/Manifest index 4f24281af113..65005947bc45 100644 --- a/dev-db/unixODBC/Manifest +++ b/dev-db/unixODBC/Manifest @@ -1,5 +1,5 @@ AUX unixODBC-2.3.12-bug-936060.patch 1018 BLAKE2B 3efeb58341af9e004bbc9adc4652a64ff8149a0d89bb1e73925b5e282240c2976f87aaf22656c584443e307e2f97bd36d57acc127526f3d8285480445371904d SHA512 812d3cac8a2168e477ff231dbef3fbcda41caac87368811ae192dcd67483553b97d14a6028624509dc772b0ab6cbc59917390f43131fd7e90b40dc6a199dbb4d DIST unixODBC-2.3.12.tar.gz 1753915 BLAKE2B 9da9b0fb5ff962db8ec1483b700aca5d4adf88f3349b22010bd0b4b4ec1fe2e7a51d761527e3b9e49b08286a00e55aadc38c320a6db512ba52f491aecad7fd83 SHA512 ca9d8db943195679a44db1fc09391dc6662ab1721112c93d448f04011e98502462ffe14b8364eb03707d851db456eced20eb61a22370392ca88d917038d45b56 -EBUILD unixODBC-2.3.12-r1.ebuild 1968 BLAKE2B 608a66ab7a8518a832c8b53e53cf6b93678f77638844a6492fcb5d5760d8e26a0e6d5f8b0ceecb05c8d5ac60ec25009b22f675fe524668430e20f312a913ecfb SHA512 96cc2bba289b90b7adbf758777751a814e649a2b98a2e415f703019c7a6c50fb24f9ebfefe992b8575b71177c70828be082b56638997009083285b40865297b3 +EBUILD unixODBC-2.3.12-r1.ebuild 1962 BLAKE2B 4baa47bb79d6259cba910f9c7beb11e30071cafeaad1b8f631bb9c30ca5fe73d0cc8dd580407b523a11f80dca787d4bf6b6ae73672d5caaf7771abdd2917f471 SHA512 577b140d5a993b3b41ba5f3f545b49f5ef5471d6dba90502454cfc6bdbe26312d4a6762519fdbe765a32925fd35b61601a107c7520e3c136bb5f2cc88d159b74 EBUILD unixODBC-2.3.12.ebuild 1910 BLAKE2B d5c84937b47a9659e8a077c0188c2266f4fa5b61c74195db20093c55fe87a7c71fd55ce792d00c1eff9f56586e4d3562f79b33d99690a3517cfdbc4c48423e82 SHA512 3306788ded0d691280796f8881682ada3a7e5489bba5f170645f430da233cf12e17b39d25c3fb0e5c835814bcb481ad8b0c7edcb8d8454fdf7dcbb8d7f30280f MISC metadata.xml 479 BLAKE2B 298fd55d5c29508598a3e221f0d3b850b3f2e195885460c5a9cb9d4111d9246576d1ae0c8c586f6484931ea2b8b9a2e0127db5e4c01c456e66fb66436b62f2aa SHA512 a751b3121ce1298c50e4f66ce8c654d578be088fdf52490a4149d380053bef287736d27ef1b430fef789019cc1e0f53904cafc6c292d984a78da105a493be6a5 diff --git a/dev-db/unixODBC/unixODBC-2.3.12-r1.ebuild b/dev-db/unixODBC/unixODBC-2.3.12-r1.ebuild index 87141847f80b..061e25645301 100644 --- a/dev-db/unixODBC/unixODBC-2.3.12-r1.ebuild +++ b/dev-db/unixODBC/unixODBC-2.3.12-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -11,7 +11,7 @@ SRC_URI="https://www.unixodbc.org/unixODBC-${PV}.tar.gz" LICENSE="GPL-2 LGPL-2.1" SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris" +KEYWORDS="~alpha amd64 arm arm64 ~hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 ~sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris" IUSE="+minimal odbcmanual static-libs unicode" RDEPEND=" |