summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Evans <grknight@gentoo.org>2017-08-24 10:02:13 -0400
committerBrian Evans <grknight@gentoo.org>2017-08-24 10:41:33 -0400
commit7f006aed315a98c65ccebc820de11131039b0dee (patch)
tree971332d71eb8ff2d422a9617e023a75df970bc74 /dev-db/mysql-connector-c++/mysql-connector-c++-1.1.9.ebuild
parentapp-emulation/flannel: Remove old (diff)
downloadgentoo-7f006aed315a98c65ccebc820de11131039b0dee.tar.gz
gentoo-7f006aed315a98c65ccebc820de11131039b0dee.tar.bz2
gentoo-7f006aed315a98c65ccebc820de11131039b0dee.zip
dev-db/mysql-connector-c++: Version bump and fix patch wrt bug 628788
MariaDB 10.2 no longer includes MARIADB_BASE_VERSION but uses MARIADB_VERSION_ID instead. Package-Manager: Portage-2.3.8, Repoman-2.3.3
Diffstat (limited to 'dev-db/mysql-connector-c++/mysql-connector-c++-1.1.9.ebuild')
-rw-r--r--dev-db/mysql-connector-c++/mysql-connector-c++-1.1.9.ebuild62
1 files changed, 62 insertions, 0 deletions
diff --git a/dev-db/mysql-connector-c++/mysql-connector-c++-1.1.9.ebuild b/dev-db/mysql-connector-c++/mysql-connector-c++-1.1.9.ebuild
new file mode 100644
index 00000000000..1120d852cbe
--- /dev/null
+++ b/dev-db/mysql-connector-c++/mysql-connector-c++-1.1.9.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit cmake-utils flag-o-matic
+
+DESCRIPTION="MySQL database connector for C++ (mimics JDBC 4.0 API)"
+HOMEPAGE="http://dev.mysql.com/downloads/connector/cpp/"
+URI_DIR="Connector-C++"
+SRC_URI="https://dev.mysql.com/get/Downloads/${URI_DIR}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~sparc ~x86"
+IUSE="debug examples gcov static-libs"
+
+DEPEND="virtual/libmysqlclient:=
+ dev-libs/boost:=
+ dev-libs/openssl:0=
+ !<dev-db/mysql-connector-c-6.1.8"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-1.1.6-fix-cmake.patch"
+ "${FILESDIR}/${PN}-1.1.8-fix-mariadb.patch"
+)
+
+src_configure() {
+ # native lib/wrapper needs this!
+ append-flags "-fno-strict-aliasing"
+
+ local mycmakeargs=(
+ -DMYSQLCPPCONN_BUILD_EXAMPLES=OFF
+ -DMYSQLCPPCONN_ICU_ENABLE=OFF
+ -DUSE_MYSQLCPPCONN_TRACE_ENABLE=$(usex debug ON OFF)
+ -DUSE_MYSQLCPPCONN_GCOV_ENABLE=$(usex gcov ON OFF)
+ -DINSTALL_DOCS="/usr/share/doc/${PF}"
+ -DMYSQL_CXX_LINKAGE=0
+ -DMYSQL_INCLUDE_DIR=$(mysql_config --variable=pkgincludedir)
+ )
+
+ cmake-utils_src_configure
+}
+
+src_install() {
+ cmake-utils_src_install
+
+ # static lib has wrong name so we need to rename it
+ if use static-libs; then
+ mv "${ED}"/usr/$(get_libdir)/libmysqlcppconn-static.a \
+ "${ED}"/usr/$(get_libdir)/libmysqlcppconn.a || die
+ else
+ rm -f "${ED}"/usr/$(get_libdir)/libmysqlcppconn-static.a
+ fi
+
+ # examples
+ if use examples; then
+ insinto /usr/share/doc/${PF}/examples
+ doins "${S}"/examples/*
+ fi
+}