diff options
-rw-r--r-- | dev-db/mysql-connector-c/Manifest | 1 | ||||
-rw-r--r-- | dev-db/mysql-connector-c/mysql-connector-c-8.0.26.ebuild | 122 |
2 files changed, 123 insertions, 0 deletions
diff --git a/dev-db/mysql-connector-c/Manifest b/dev-db/mysql-connector-c/Manifest index c06df36e6035..0f9c928a3587 100644 --- a/dev-db/mysql-connector-c/Manifest +++ b/dev-db/mysql-connector-c/Manifest @@ -1,3 +1,4 @@ DIST mysql-boost-8.0.22.tar.gz 285934450 BLAKE2B 1ba0c9bb9a0cb74af4842d3b746f8b690c122cfbf2c6d5201ce95e59a257427a8683dd8d5c2be31dfe9ece4761366c1287fa7b841c45db222725bf76b0639bc6 SHA512 792f2ada93ec67a4679228478c6b798e81d9e9f6d13c7f4977cb7682738a4aae3cb483294edc6b2fde16c3960e51af8786216c063ab500840afd39a609e4b612 DIST mysql-boost-8.0.23.tar.gz 291039175 BLAKE2B 3a7d3e05c774085d6078d0d3effd58d2df47521615356a2aa5efc2ea2ef8457e19ad57a054926ccff0a4752ca71d0464daa7fe9a3ac6c1b1d3bd86a9a82dfc58 SHA512 b8c2e2ac772b7b730f8b3bac7a5afb205da173b3639500606e7d1fac74832a0134027951855a2dc81af015e6158c924927ad63b9e1f2e7c823d45d4c4961c3f8 DIST mysql-boost-8.0.25.tar.gz 290265324 BLAKE2B 5393a2a2525a886d9ece19777deae01e6c0b24b9ff5a0a5ffb9075740ed912d0df59a165b6ec9ceb60c7c28f3062cda5cceb4da3a8280f42549984c846f1ce5c SHA512 af653ccff66a9d87221b46ad4f7bcc629700549f758998b9a7fb22e4573b9495a28624e031f016f9ad8fe0dfcf481b82f1ffe224aa48c2d45531570026b26081 +DIST mysql-boost-8.0.26.tar.gz 291285918 BLAKE2B 6198ca8982a8c9df7e6ee4df5e2c1e0d64d2eb4d83cb7265317b58d55f6787c3240c8e40d196f2326ff3d66926ad7dab0705edd92e5a82881ce6ddb7f0c510b9 SHA512 63d47cb52407a816dc9f4330b99924624dfee46e57e7fdce19eff32909dd9e23251e2439d1807b002a1661b547173222c77465a3ca4dbb312414a84927809cfc diff --git a/dev-db/mysql-connector-c/mysql-connector-c-8.0.26.ebuild b/dev-db/mysql-connector-c/mysql-connector-c-8.0.26.ebuild new file mode 100644 index 000000000000..fa385e807a46 --- /dev/null +++ b/dev-db/mysql-connector-c/mysql-connector-c-8.0.26.ebuild @@ -0,0 +1,122 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +CMAKE_ECLASS=cmake +inherit cmake-multilib flag-o-matic + +# wrap the config script +MULTILIB_CHOST_TOOLS=( /usr/bin/mysql_config ) + +DESCRIPTION="C client library for MariaDB/MySQL" +HOMEPAGE="https://dev.mysql.com/downloads/" + +if [[ ${PV} == "9999" ]]; then + EGIT_REPO_URI="https://github.com/mysql/mysql-server.git" + + inherit git-r3 +else + SRC_URI="https://dev.mysql.com/get/Downloads/MySQL-$(ver_cut 1-2)/mysql-boost-${PV}.tar.gz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" + + S="${WORKDIR}/mysql-${PV}" +fi + +LICENSE="GPL-2" +SLOT="0/21" +IUSE="ldap static-libs" + +RDEPEND=" + >=app-arch/lz4-0_p131:=[${MULTILIB_USEDEP}] + app-arch/zstd:=[${MULTILIB_USEDEP}] + sys-libs/zlib:=[${MULTILIB_USEDEP}] + ldap? ( dev-libs/cyrus-sasl:=[${MULTILIB_USEDEP}] ) + dev-libs/openssl:0=[${MULTILIB_USEDEP}] +" +DEPEND="${RDEPEND}" + +# Avoid file collisions, #692580 +RDEPEND+=" !<dev-db/mysql-5.6.45-r1" +RDEPEND+=" !=dev-db/mysql-5.7.23*" +RDEPEND+=" !=dev-db/mysql-5.7.24*" +RDEPEND+=" !=dev-db/mysql-5.7.25*" +RDEPEND+=" !=dev-db/mysql-5.7.26-r0" +RDEPEND+=" !=dev-db/mysql-5.7.27-r0" +RDEPEND+=" !<dev-db/percona-server-5.7.26.29-r1" + +DOCS=( README ) + +PATCHES=( + "${FILESDIR}"/${PN}-8.0.22-always-build-decompress-utilities.patch + "${FILESDIR}"/${PN}-8.0.19-do-not-install-comp_err.patch + "${FILESDIR}"/${PN}-8.0.25-add-OpenSSL-3.0.0-support.patch +) + +src_prepare() { + sed -i -e 's/CLIENT_LIBS/CONFIG_CLIENT_LIBS/' "scripts/CMakeLists.txt" || die + + # All these are for the server only. + # Disable rpm call which would trigger sandbox, #692368 + sed -i \ + -e '/MYSQL_CHECK_LIBEVENT/d' \ + -e '/MYSQL_CHECK_RAPIDJSON/d' \ + -e '/MYSQL_CHECK_ICU/d' \ + -e '/MYSQL_CHECK_EDITLINE/d' \ + -e '/MYSQL_CHECK_CURL/d' \ + -e '/ADD_SUBDIRECTORY(man)/d' \ + -e '/ADD_SUBDIRECTORY(share)/d' \ + -e '/INCLUDE(cmake\/boost/d' \ + -e 's/MY_RPM rpm/MY_RPM rpmNOTEXISTENT/' \ + CMakeLists.txt || die + + # Skip building clients + echo > client/CMakeLists.txt || die + + # Forcefully disable auth plugin + if ! use ldap ; then + sed -i -e '/MYSQL_CHECK_SASL/d' CMakeLists.txt || die + echo > libmysql/authentication_ldap/CMakeLists.txt || die + fi + + cmake_src_prepare +} + +multilib_src_configure() { + CMAKE_BUILD_TYPE="RelWithDebInfo" + + # code is not C++17 ready, bug #786402 + append-cxxflags -std=c++14 + + local mycmakeargs=( + -DCMAKE_C_FLAGS_RELWITHDEBINFO=-DNDEBUG + -DCMAKE_CXX_FLAGS_RELWITHDEBINFO=-DNDEBUG + -DINSTALL_LAYOUT=RPM + -DINSTALL_LIBDIR=$(get_libdir) + -DWITH_DEFAULT_COMPILER_OPTIONS=OFF + -DENABLED_LOCAL_INFILE=ON + -DMYSQL_UNIX_ADDR="${EPREFIX}/run/mysqld/mysqld.sock" + -DWITH_LZ4=system + -DWITH_NUMA=OFF + -DWITH_SSL=system + -DWITH_ZLIB=system + -DWITH_ZSTD=system + -DLIBMYSQL_OS_OUTPUT_NAME=mysqlclient + -DSHARED_LIB_PATCH_VERSION="0" + -DCMAKE_POSITION_INDEPENDENT_CODE=ON + -DWITHOUT_SERVER=ON + ) + + cmake_src_configure +} + +multilib_src_install_all() { + doman \ + man/my_print_defaults.1 \ + man/perror.1 \ + man/zlib_decompress.1 + + if ! use static-libs ; then + find "${ED}" -name "*.a" -delete || die + fi +} |