mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
dev-db/mariadb-connector-odbc: add 3.2.7
Signed-off-by: Jaco Kroon <jkroon@gentoo.org>
This commit is contained in:
@@ -1 +1,2 @@
|
||||
DIST mariadb-connector-odbc-3.1.18-src.tar.gz 556590 BLAKE2B 9644521f91136b3bc30846d8c9df7cfa21c8fff0e9219bf0c758a0294f34783a57f1200834b84833284624160652315adb4f6eb465a90378e676e5767c7bd40a SHA512 1d240988d03dbb0ef2f4eb0667ff973a35d700f319caaea78db6d5c0ca569ed5adcee978fb10cd9f067c0c5aecbfe697e5adb3d736e564bae82cf6c11cd0dba2
|
||||
DIST mariadb-connector-odbc-3.2.7-src.tar.gz 667911 BLAKE2B 4ffaecb0239ede28fccfd00bd3fbf9cdef6139cbb898ec930c583aa5d690911952355b6998451273838f756f12a46f5335bdd12c97a39d53a9eeb534362e532c SHA512 b9cba5a067e044b312e116dba9faada63ddae379a67aec3abfd29b2d7bf004dedf0241f550f17c296e87765a47cd10793de8a65f4e90c9eff94e0dc5250d5d9f
|
||||
|
||||
@@ -0,0 +1,70 @@
|
||||
# Copyright 2018-2025 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit cmake-multilib flag-o-matic
|
||||
|
||||
DESCRIPTION="MariaDB Connector/ODBC"
|
||||
HOMEPAGE="https://mariadb.org/connector-odbc/all-releases/ https://github.com/mariadb-corporation/mariadb-connector-odbc/"
|
||||
SRC_URI="mirror://mariadb/connector-odbc-${PV}/${P}-src.tar.gz"
|
||||
S="${S}-src"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="0/3.1"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="ssl"
|
||||
|
||||
# USE=ssl merely enables the configuration options (seemingly for interactive
|
||||
# sessions) and does not cause direct linking to any SSL libraries. However,
|
||||
# it doesn't make sense enable these configuration options unless the
|
||||
# underlying mariadb-connector-c has ssl enabled, thus if we have USE=ssl,
|
||||
# require mariadb-connector-c to have it too.
|
||||
DEPEND="dev-db/mariadb-connector-c:=[ssl(+)?]
|
||||
dev-db/unixODBC"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
src_prepare() {
|
||||
cmake_src_prepare
|
||||
|
||||
sed -e "s,/lib/,/$(get_libdir)/,g" "${FILESDIR}/odbcinst2.ini" > odbcinst.ini || die
|
||||
}
|
||||
|
||||
multilib_src_configure() {
|
||||
append-cppflags $(mariadb_config --cflags || die)
|
||||
local mycmakeargs=(
|
||||
-DWITH_SSL=$(usex ssl OPENSSL OFF)
|
||||
-DMARIADB_LINK_DYNAMIC=YES
|
||||
-DUSE_SYSTEM_INSTALLED_LIB=YES
|
||||
-DINSTALL_DOCDIR="/usr/share/doc/${PF}"
|
||||
-DINSTALL_LICENSEDIR="/usr/share/doc/${PF}"
|
||||
-DINSTALL_LIBDIR="$(get_libdir)/mariadb"
|
||||
-DINSTALL_PCDIR="$(get_libdir)/pkgconfig"
|
||||
#-DCMAKE_C_FLAGS="$(mariadb_config --cflags)"
|
||||
)
|
||||
cmake_src_configure
|
||||
}
|
||||
|
||||
multilib_src_install_all() {
|
||||
insinto /usr/share/${PN}
|
||||
doins odbcinst.ini
|
||||
|
||||
rm "${ED}/usr/share/doc/${PF}/COPYING" || die "Error removing COPYING file from installation"
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "Please remember to use emerge --config =${P} to install the ODBC ini files."
|
||||
elog "Alternatively run: /usr/bin/odbcinst -i -d -f /usr/share/${PN}/odbcinst.ini"
|
||||
}
|
||||
|
||||
pkg_config() {
|
||||
[[ -n "${ROOT}" ]] && die "Sorry, non-standard ROOT setting is not supported."
|
||||
|
||||
if /usr/bin/odbcinst -q -d -n maodbc &>/dev/null; then
|
||||
einfo "maodbc (MariaDB ODBC driver) has already been installed."
|
||||
else
|
||||
ebegin "Installing maodbc (MariaDB ODBC driver)"
|
||||
/usr/bin/odbcinst -i -d -f /usr/share/${PN}/odbcinst.ini
|
||||
eend ${?} || die
|
||||
fi
|
||||
}
|
||||
Reference in New Issue
Block a user