From: "Jorge Manuel B. S. Vicetto" <jmbsvicetto@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/mysql:master commit in: eclass/
Date: Tue, 30 Apr 2013 10:17:02 +0000 (UTC) [thread overview]
Message-ID: <1367316810.7880308a3ef25f6e2945dc364fff3cc8a2eb84f4.jmbsvicetto@gentoo> (raw)
commit: 7880308a3ef25f6e2945dc364fff3cc8a2eb84f4
Author: Jorge Manuel B. S. Vicetto (jmbsvicetto) <jmbsvicetto <AT> gentoo <DOT> org>
AuthorDate: Tue Apr 30 10:13:30 2013 +0000
Commit: Jorge Manuel B. S. Vicetto <jmbsvicetto <AT> gentoo <DOT> org>
CommitDate: Tue Apr 30 10:13:30 2013 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/mysql.git;a=commit;h=7880308a
[eclass] Update eclasses to be more consistent with bash notation and more compact.
---
eclass/mysql-autotools.eclass | 58 ++++++++--------
eclass/mysql-cmake.eclass | 28 ++++----
eclass/mysql-v2.eclass | 153 +++++++++++++++++------------------------
3 files changed, 107 insertions(+), 132 deletions(-)
diff --git a/eclass/mysql-autotools.eclass b/eclass/mysql-autotools.eclass
index e00906b..9d1ff91 100644
--- a/eclass/mysql-autotools.eclass
+++ b/eclass/mysql-autotools.eclass
@@ -51,14 +51,14 @@ mysql-autotools_disable_test() {
# ${S}/mysql-tests/suite/ndb_team/t/disabled.def
# ${S}/mysql-tests/suite/binlog/t/disabled.def
# ${S}/mysql-tests/suite/innodb/t/disabled.def
- if [ -n "${testsuite}" ]; then
+ if [[ -n ${testsuite} ]]; then
for mysql_disable_file in \
${S}/mysql-test/suite/${testsuite}/disabled.def \
${S}/mysql-test/suite/${testsuite}/t/disabled.def \
FAILED ; do
- [ -f "${mysql_disable_file}" ] && break
+ [[ -f ${mysql_disable_file} ]] && break
done
- if [ "${mysql_disabled_file}" != "FAILED" ]; then
+ if [[ ${mysql_disabled_file} != "FAILED" ]]; then
echo "${testname} : ${reason}" >> "${mysql_disable_file}"
else
ewarn "Could not find testsuite disabled.def location for ${rawtestname}"
@@ -99,7 +99,7 @@ mysql-autotools_configure_minimal() {
# MariaDB requires this flag in order to link to GPLv3 readline v6 or greater
# A note is added to the configure output
- if [[ "${PN}" == "mariadb" ]] && mysql_version_is_at_least "5.1.61" ; then
+ if [[ ${PN} == "mariadb" ]] && mysql_version_is_at_least "5.1.61" ; then
myconf="${myconf} --disable-distribution"
fi
}
@@ -134,7 +134,7 @@ mysql-autotools_configure_common() {
fi
fi
- if [ -n "${MYSQL_DEFAULT_CHARSET}" -a -n "${MYSQL_DEFAULT_COLLATION}" ]; then
+ 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."
@@ -220,7 +220,7 @@ mysql-autotools_configure_51() {
# Not supporting as examples: example,daemon_example,ftexample
plugins_sta="${plugins_sta} partition"
- if [[ "${PN}" != "mariadb" ]] ; then
+ if [[ ${PN} != "mariadb" ]] ; then
elog "Before using the Federated storage engine, please be sure to read"
elog "http://dev.mysql.com/doc/refman/5.1/en/federated-limitations.html"
plugins_dyn="${plugins_dyn} federated"
@@ -237,10 +237,10 @@ mysql-autotools_configure_51() {
# - innobase, innodb_plugin
# Build falcon if available for 6.x series.
for i in innobase falcon ; do
- [ -e "${S}"/storage/${i} ] && plugins_sta="${plugins_sta} ${i}"
+ [[ -e ${S}/storage/${i} ]] && plugins_sta="${plugins_sta} ${i}"
done
for i in innodb_plugin ; do
- [ -e "${S}"/storage/${i} ] && plugins_dyn="${plugins_dyn} ${i}"
+ [[ -e ${S}/storage/${i} ]] && plugins_dyn="${plugins_dyn} ${i}"
done
# like configuration=max-no-ndb
@@ -252,12 +252,12 @@ mysql-autotools_configure_51() {
plugins_dis="${plugins_dis} ndbcluster"
fi
- if [[ "${PN}" == "mariadb" ]] ; then
+ if [[ ${PN} == "mariadb" ]] ; then
# In MariaDB, InnoDB is packaged in the xtradb directory, so it's not
# caught above.
# This is not optional, without it several upstream testcases fail.
# Also strongly recommended by upstream.
- if [[ "${PV}" < "5.2.0" ]] ; then
+ if [[ ${PV} < "5.2.0" ]] ; then
myconf="${myconf} --with-maria-tmp-tables"
plugins_sta="${plugins_sta} maria"
else
@@ -265,11 +265,11 @@ mysql-autotools_configure_51() {
plugins_sta="${plugins_sta} aria"
fi
- [ -e "${S}"/storage/innobase ] || [ -e "${S}"/storage/xtradb ] ||
+ [[ ( -e ${S}/storage/innobase ) || ( -e ${S}/storage/xtradb ) ]] ||
die "The ${P} package doesn't provide innobase nor xtradb"
for i in innobase xtradb ; do
- [ -e "${S}"/storage/${i} ] && plugins_sta="${plugins_sta} ${i}"
+ [[ -e ${S}/storage/${i} ]] && plugins_sta="${plugins_sta} ${i}"
done
myconf="${myconf} $(use_with libevent)"
@@ -300,7 +300,7 @@ mysql-autotools_configure_51() {
fi
fi
- if pbxt_available && [[ "${PBXT_NEWSTYLE}" == "1" ]]; then
+ if pbxt_available && [[ ${PBXT_NEWSTYLE} == "1" ]]; then
use pbxt \
&& plugins_sta="${plugins_sta} pbxt" \
|| plugins_dis="${plugins_dis} pbxt"
@@ -311,7 +311,7 @@ mysql-autotools_configure_51() {
plugins_dyn=""
# Google MySQL, bundle what upstream supports
- if [[ "${PN}" == "google-mysql" ]]; then
+ if [[ ${PN} == "google-mysql" ]]; then
for x in innobase innodb_plugin innodb ; do
plugins_sta="${plugins_sta//$x}"
plugins_dyn="${plugins_dyn//$x}"
@@ -389,7 +389,7 @@ mysql-autotools_src_prepare() {
# last -fPIC fixup, per bug #305873
i="${S}"/storage/innodb_plugin/plug.in
- [ -f "${i}" ] && sed -i -e '/CFLAGS/s,-prefer-non-pic,,g' "${i}"
+ [[ -f ${i} ]] && sed -i -e '/CFLAGS/s,-prefer-non-pic,,g' "${i}"
# Additional checks, remove bundled zlib
rm -f "${S}/zlib/"*.[ch]
@@ -417,21 +417,21 @@ mysql-autotools_src_prepare() {
i="innobase"
o="${WORKDIR}/storage-${i}.mysql-upstream"
# Have we been here already?
- [ -d "${o}" ] && rm -f "${i}"
+ [[ -d ${o} ]] && rm -f "${i}"
# Or maybe we haven't
- [ -d "${i}" -a ! -d "${o}" ] && mv "${i}" "${o}"
+ [[ ( -d ${i} ) && ! ( -d ${o} ) ]] && mv "${i}" "${o}"
cp -ral "${WORKDIR}/${XTRADB_P}" "${i}"
popd >/dev/null
fi
- if pbxt_patch_available && [[ "${PBXT_NEWSTYLE}" == "1" ]] && use pbxt ; then
+ if pbxt_patch_available && [[ ${PBXT_NEWSTYLE} == "1" ]] && use pbxt ; then
einfo "Adding storage engine: PBXT"
pushd "${S}"/storage >/dev/null
i='pbxt'
- [ -d "${i}" ] && rm -rf "${i}"
+ [[ -d ${i} ]] && rm -rf "${i}"
cp -ral "${WORKDIR}/${PBXT_P}" "${i}"
f="${WORKDIR}/mysql-extras/pbxt/fix-low-priority.patch"
- [[ -f $f ]] && epatch "$f"
+ [[ -f $f ]] && epatch "$f"
popd >/dev/null
fi
@@ -490,7 +490,7 @@ mysql-autotools_src_configure() {
# implicitly. Upstream might be interested in this, exclude
# -fno-implicit-templates for google-mysql for now.
mysql_version_is_at_least "5.0" \
- && [[ "${PN}" != "google-mysql" ]] \
+ && [[ ${PN} != "google-mysql" ]] \
&& CXXFLAGS="${CXXFLAGS} -fno-implicit-templates"
export CXXFLAGS
@@ -526,7 +526,7 @@ mysql-autotools_src_configure() {
| xargs -0 -n100 sed -i \
-e 's|^pkglibdir *= *$(libdir)/mysql|pkglibdir = $(libdir)|;s|^pkgincludedir *= *$(includedir)/mysql|pkgincludedir = $(includedir)|'
- if [[ $EAPI == 2 ]] && [[ "${PBXT_NEWSTYLE}" != "1" ]]; then
+ if [[ $EAPI == 2 ]] && [[ ${PBXT_NEWSTYLE} != "1" ]]; then
pbxt_patch_available && use pbxt && pbxt_src_configure
fi
}
@@ -538,7 +538,7 @@ mysql-autotools_src_compile() {
emake || die "emake failed"
- if [[ "${PBXT_NEWSTYLE}" != "1" ]]; then
+ if [[ ${PBXT_NEWSTYLE} != "1" ]]; then
pbxt_patch_available && use pbxt && pbxt_src_compile
fi
}
@@ -557,7 +557,7 @@ mysql-autotools_src_install() {
testroot="${MY_SHAREDSTATEDIR}" \
|| die "emake install failed"
- if [[ "${PBXT_NEWSTYLE}" != "1" ]]; then
+ if [[ ${PBXT_NEWSTYLE} != "1" ]]; then
pbxt_patch_available && use pbxt && pbxt_src_install
fi
@@ -620,7 +620,7 @@ mysql-autotools_src_install() {
# Empty directories ...
diropts "-m0750"
keepdir "${MY_DATADIR#${EPREFIX}}"
- if [[ "${PREVIOUS_DATADIR}" != "yes" ]] ; then
+ if [[ ${PREVIOUS_DATADIR} != "yes" ]] ; then
chown -R mysql:mysql "${D}/${MY_DATADIR}"
fi
@@ -635,7 +635,7 @@ mysql-autotools_src_install() {
# Docs
einfo "Installing docs"
for i in README ChangeLog EXCEPTIONS-CLIENT INSTALL-SOURCE ; do
- [[ -f "$i" ]] && dodoc "$i"
+ [[ -f $i ]] && dodoc "$i"
done
doinfo "${S}"/Docs/mysql.info
@@ -648,12 +648,12 @@ mysql-autotools_src_install() {
"${S}"/support-files/magic \
"${S}"/support-files/ndb-config-2-node.ini
do
- [[ -f "$script" ]] && dodoc "${script}"
+ [[ -f $script ]] && dodoc "${script}"
done
docinto "scripts"
for script in "${S}"/scripts/mysql* ; do
- [[ -f "$script" ]] && [[ "${script%.sh}" == "${script}" ]] && dodoc "${script}"
+ [[ ( -f $script ) && ( ${script%.sh} == ${script} ) ]] && dodoc "${script}"
done
fi
@@ -661,7 +661,7 @@ mysql-autotools_src_install() {
mysql_lib_symlinks "${ED}"
#Remove mytop if perl is not selected
- [[ "${PN}" == "mariadb" ]] && ! use perl \
+ [[ ${PN} == "mariadb" ]] && ! use perl \
&& mysql_version_is_at_least "5.3" \
&& rm -f "${ED}/usr/bin/mytop"
diff --git a/eclass/mysql-cmake.eclass b/eclass/mysql-cmake.eclass
index 43d0221..c00ceb2 100644
--- a/eclass/mysql-cmake.eclass
+++ b/eclass/mysql-cmake.eclass
@@ -36,29 +36,29 @@ mysql-cmake_disable_test() {
for mysql_disabled_file in \
${S}/mysql-test/disabled.def \
${S}/mysql-test/t/disabled.def ; do
- [ -f "${mysql_disabled_file}" ] && break
+ [[ -f ${mysql_disabled_file} ]] && break
done
#mysql_disabled_file="${S}/mysql-test/t/disabled.def"
#einfo "rawtestname=${rawtestname} testname=${testname} testsuite=${testsuite}"
echo ${testname} : ${reason} >> "${mysql_disabled_file}"
- if [ -n "${testsuite}" ] && [ "${testsuite}" != "main" ]; then
+ if [[ ( -n ${testsuite} ) && ( ${testsuite} != "main" ) ]]; then
for mysql_disabled_file in \
${S}/mysql-test/suite/${testsuite}/disabled.def \
${S}/mysql-test/suite/${testsuite}/t/disabled.def \
FAILED ; do
- [ -f "${mysql_disabled_file}" ] && break
+ [[ -f ${mysql_disabled_file} ]] && break
done
- if [ "${mysql_disabled_file}" != "FAILED" ]; then
+ if [[ ${mysql_disabled_file} != "FAILED" ]]; then
echo "${testname} : ${reason}" >> "${mysql_disabled_file}"
else
for mysql_disabled_dir in \
${S}/mysql-test/suite/${testsuite} \
${S}/mysql-test/suite/${testsuite}/t \
FAILED ; do
- [ -d "${mysql_disabled_dir}" ] && break
+ [[ -d ${mysql_disabled_dir} ]] && break
done
- if [ "${mysql_disabled_dir}" != "FAILED" ]; then
+ if [[ ${mysql_disabled_dir} != "FAILED" ]]; then
echo "${testname} : ${reason}" >> "${mysql_disabled_dir}/disabled.def"
else
ewarn "Could not find testsuite disabled.def location for ${rawtestname}"
@@ -72,7 +72,7 @@ mysql-cmake_disable_test() {
# Helper function to configure locale cmake options
configure_cmake_locale() {
- if ! use minimal && [ -n "${MYSQL_DEFAULT_CHARSET}" -a -n "${MYSQL_DEFAULT_COLLATION}" ]; then
+ if ! use minimal && [[ ( -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."
@@ -218,7 +218,7 @@ mysql-cmake_src_prepare() {
# last -fPIC fixup, per bug #305873
i="${S}"/storage/innodb_plugin/plug.in
- [ -f "${i}" ] && sed -i -e '/CFLAGS/s,-prefer-non-pic,,g' "${i}"
+ [[ -f ${i} ]] && sed -i -e '/CFLAGS/s,-prefer-non-pic,,g' "${i}"
rm -f "scripts/mysqlbug"
epatch_user
@@ -259,7 +259,7 @@ mysql-cmake_src_configure() {
# Bug 412851
# MariaDB requires this flag to compile with GPLv3 readline linked
# Adds a warning about redistribution to configure
- if [[ "${PN}" == "mariadb" ]] ; then
+ if [[ ${PN} == "mariadb" ]] ; then
mycmakeargs+=( -DNOT_FOR_DISTRIBUTION=1 )
fi
@@ -321,7 +321,7 @@ mysql-cmake_src_install() {
dosym "/usr/bin/mysqlcheck" "/usr/bin/mysqloptimize"
# Create a mariadb_config symlink
- [[ "${PN}" == "mariadb" ]] && dosym "/usr/bin/mysql_config" "/usr/bin/mariadb_config"
+ [[ ${PN} == "mariadb" ]] && dosym "/usr/bin/mysql_config" "/usr/bin/mariadb_config"
# INSTALL_LAYOUT=STANDALONE causes cmake to create a /usr/data dir
rm -Rf "${ED}/usr/data"
@@ -370,7 +370,7 @@ mysql-cmake_src_install() {
einfo "Creating initial directories"
# Empty directories ...
diropts "-m0750"
- if [[ "${PREVIOUS_DATADIR}" != "yes" ]] ; then
+ if [[ ${PREVIOUS_DATADIR} != "yes" ]] ; then
dodir "${MY_DATADIR#${EPREFIX}}"
keepdir "${MY_DATADIR#${EPREFIX}}"
chown -R mysql:mysql "${D}/${MY_DATADIR}"
@@ -393,16 +393,16 @@ mysql-cmake_src_install() {
"${S}"/support-files/magic \
"${S}"/support-files/ndb-config-2-node.ini.sh
do
- [[ -f "$script" ]] && dodoc "${script}"
+ [[ -f $script ]] && dodoc "${script}"
done
docinto "scripts"
for script in "${S}"/scripts/mysql* ; do
- [[ -f "$script" ]] && [[ "${script%.sh}" == "${script}" ]] && dodoc "${script}"
+ [[ ( -f $script ) && ( ${script%.sh} == ${script} ) ]] && dodoc "${script}"
done
fi
#Remove mytop if perl is not selected
- [[ "${PN}" == "mariadb" ]] && ! use perl \
+ [[ ${PN} == "mariadb" ]] && ! use perl \
&& rm -f "${ED}/usr/bin/mytop"
}
diff --git a/eclass/mysql-v2.eclass b/eclass/mysql-v2.eclass
index eda43a4..cca2360 100644
--- a/eclass/mysql-v2.eclass
+++ b/eclass/mysql-v2.eclass
@@ -44,7 +44,7 @@ MYSQL_EXTRAS=""
# @DESCRIPTION:
# The version of the MYSQL_EXTRAS repo to use to build mysql
# Use "none" to disable it's use
-[[ "${MY_EXTRAS_VER}" == "live" ]] && MYSQL_EXTRAS="git-2"
+[[ ${MY_EXTRAS_VER} == "live" ]] && MYSQL_EXTRAS="git-2"
inherit eutils flag-o-matic gnuconfig ${MYSQL_EXTRAS} ${BUILD_INHERIT} mysql_fx versionator toolchain-funcs
@@ -67,8 +67,8 @@ EXPORT_FUNCTIONS pkg_setup src_unpack src_prepare src_configure src_compile src_
# and we will run a mysql server during test phase
S="${WORKDIR}/mysql"
-[[ "${MY_EXTRAS_VER}" == "latest" ]] && MY_EXTRAS_VER="20090228-0714Z"
-if [[ "${MY_EXTRAS_VER}" == "live" ]]; then
+[[ ${MY_EXTRAS_VER} == "latest" ]] && MY_EXTRAS_VER="20090228-0714Z"
+if [[ ${MY_EXTRAS_VER} == "live" ]]; then
EGIT_PROJECT=mysql-extras
EGIT_REPO_URI="git://git.overlays.gentoo.org/proj/mysql-extras.git"
fi
@@ -113,9 +113,9 @@ mysql_version_is_at_least "5.1.50" || die "This eclass should only be used with
# Designation by PERCONA for a MySQL version to apply an XTRADB release
# Work out the default SERVER_URI correctly
-if [ -z "${SERVER_URI}" ]; then
- [ -z "${MY_PV}" ] && MY_PV="${PV//_/-}"
- if [ "${PN}" == "mariadb" ] || [ "${PN}" == "mariadb-galera" ]; then
+if [[ -z ${SERVER_URI} ]]; then
+ [[ -z ${MY_PV} ]] && MY_PV="${PV//_/-}"
+ if [[ ${PN} == "mariadb" || ${PN} == "mariadb-galera" ]]; then
MARIA_FULL_PV="$(replace_version_separator 3 '-' ${MY_PV})"
MARIA_FULL_P="${PN}-${MARIA_FULL_PV}"
SERVER_URI="
@@ -126,8 +126,8 @@ if [ -z "${SERVER_URI}" ]; then
http://mirrors.fe.up.pt/pub/${PN}/${MARIA_FULL_P}/kvm-tarbake-jaunty-x86/${MARIA_FULL_P}.tar.gz
http://ftp-stud.hs-esslingen.de/pub/Mirrors/${PN}/${MARIA_FULL_P}/kvm-tarbake-jaunty-x86/${MARIA_FULL_P}.tar.gz
"
- if [ "${PN}" == "mariadb-galera" ]; then
- MY_SOURCEDIR="${PN%%-galera}-${GALERA_FULL_PV}"
+ if [[ ${PN} == "mariadb-galera" ]]; then
+ MY_SOURCEDIR="${PN%%-galera}-${MARIA_FULL_PV}"
fi
else
URI_DIR="MySQL"
@@ -144,20 +144,21 @@ fi
SRC_URI="${SERVER_URI}"
# Gentoo patches to MySQL
-[[ ${MY_EXTRAS_VER} != live ]] && [[ ${MY_EXTRAS_VER} != none ]] \
-&& SRC_URI="${SRC_URI}
+if [[ ${MY_EXTRAS_VER} != "live" && ${MY_EXTRAS_VER} != "none" ]]; then
+ SRC_URI="${SRC_URI}
mirror://gentoo/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
http://g3nt8.org/patches/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
http://dev.gentoo.org/~robbat2/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
http://dev.gentoo.org/~jmbsvicetto/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2"
+fi
DESCRIPTION="A fast, multi-threaded, multi-user SQL database server."
HOMEPAGE="http://www.mysql.com/"
-if [[ "${PN}" == "mariadb" ]]; then
+if [[ ${PN} == "mariadb" ]]; then
HOMEPAGE="http://mariadb.org/"
DESCRIPTION="An enhanced, drop-in replacement for MySQL"
fi
-if [ "${PN}" == "mariadb-galera" ]; then
+if [[ ${PN} == "mariadb-galera" ]]; then
HOMEPAGE="http://mariadb.org/"
DESCRIPTION="An enhanced, drop-in replacement for MySQL with Galera Replication"
fi
@@ -181,31 +182,23 @@ IUSE="${IUSE} cluster"
IUSE="${IUSE} max-idx-128"
IUSE="${IUSE} +community profiling"
-[[ ${PN} == "mariadb" ]] \
-&& mysql_check_version_range "5.1.38 to 5.3.99" \
-&& IUSE="${IUSE} libevent"
-
-([[ ${PN} == "mariadb" ]] || [[ "${PN}" == "mariadb-galera" ]])\
-&& mysql_version_is_at_least "5.2" \
-&& IUSE="${IUSE} oqgraph"
-
-([[ ${PN} == "mariadb" ]] || [[ "${PN}" == "mariadb-galera" ]])\
-&& mysql_version_is_at_least "5.2.5" \
-&& IUSE="${IUSE} sphinx"
-
-([[ ${PN} == "mariadb" ]] || [[ "${PN}" == "mariadb-galera" ]])\
-&& mysql_version_is_at_least "5.2.10" \
-&& IUSE="${IUSE} pam"
+if [[ ${PN} == "mariadb" || ${PN} == "mariadb-galera" ]]; then
+ mysql_check_version_range "5.1.38 to 5.3.99" && IUSE="${IUSE} libevent"
+ mysql_version_is_at_least "5.2" && IUSE="${IUSE} oqgraph"
+ mysql_version_is_at_least "5.2.5" && IUSE="${IUSE} sphinx"
+ mysql_version_is_at_least "5.2.10" && IUSE="${IUSE} pam"
+fi
if mysql_version_is_at_least "5.5"; then
REQUIRED_USE="tcmalloc? ( !jemalloc ) jemalloc? ( !tcmalloc )"
IUSE="${IUSE} jemalloc tcmalloc"
fi
-REQUIRED_USE="${REQUIRED_USE} minimal? ( !cluster !extraengine !embedded ) static? ( !ssl )"
+if mysql_version_is_at_least "5.5.7"; then
+ IUSE="${IUSE} systemtap"
+fi
-mysql_version_is_at_least "5.5.7" \
-&& IUSE="${IUSE} systemtap"
+REQUIRED_USE="${REQUIRED_USE} minimal? ( !cluster !extraengine !embedded ) static? ( !ssl )"
#
# DEPENDENCIES:
@@ -222,9 +215,23 @@ DEPEND="
>=sys-libs/zlib-1.2.3
"
-([[ ${PN} == "mariadb" ]] || [[ "${PN}" == "mariadb-galera" ]])\
-&& mysql_check_version_range "5.1.38 to 5.3.99" \
-&& DEPEND="${DEPEND} libevent? ( >=dev-libs/libevent-1.4 )"
+if [[ ${PN} == "mariadb" || ${PN} == "mariadb-galera" ]] ; then
+ mysql_check_version_range "5.1.38 to 5.3.99" && DEPEND="${DEPEND} libevent? ( >=dev-libs/libevent-1.4 )"
+ mysql_version_is_at_least "5.2" && DEPEND="${DEPEND} oqgraph? ( >=dev-libs/boost-1.40.0 )"
+ mysql_version_is_at_least "5.2.5" && DEPEND="${DEPEND} sphinx? ( app-misc/sphinx )"
+ mysql_version_is_at_least "5.2.10" && DEPEND="${DEPEND} !minimal? ( pam? ( virtual/pam ) )"
+ # Bug 441700 MariaDB >=5.3 include custom mytop
+ mysql_version_is_at_least "5.3" && DEPEND="${DEPEND} perl? ( !dev-db/mytop )"
+
+ # Bug 455016 Add dependancies of mytop
+ if mysql_version_is_at_least "5.3" ; then
+ RDEPEND="${RDEPEND} perl? (
+ virtual/perl-Getopt-Long
+ dev-perl/TermReadKey
+ virtual/perl-Term-ANSIColor
+ virtual/perl-Time-HiRes ) "
+ fi
+fi
# Having different flavours at the same time is not a good idea
for i in "mysql" "mariadb" "mariadb-galera" ; do
@@ -232,32 +239,15 @@ for i in "mysql" "mariadb" "mariadb-galera" ; do
DEPEND="${DEPEND} !dev-db/${i}"
done
-([[ ${PN} == "mariadb" ]] || [[ "${PN}" == "mariadb-galera" ]])\
-&& mysql_version_is_at_least "5.2" \
-&& DEPEND="${DEPEND} oqgraph? ( >=dev-libs/boost-1.40.0 )"
-
-([[ ${PN} == "mariadb" ]] || [[ "${PN}" == "mariadb-galera" ]])\
-&& mysql_version_is_at_least "5.2.5" \
-&& DEPEND="${DEPEND} sphinx? ( app-misc/sphinx )"
-
-([[ ${PN} == "mariadb" ]] || [[ "${PN}" == "mariadb-galera" ]])\
-&& mysql_version_is_at_least "5.2.10" \
-&& DEPEND="${DEPEND} !minimal? ( pam? ( virtual/pam ) )"
-
-# Bug 441700 MariaDB >=5.3 include custom mytop
-([[ ${PN} == "mariadb" ]] || [[ "${PN}" == "mariadb-galera" ]])\
-&& mysql_version_is_at_least "5.3" \
-&& DEPEND="${DEPEND} perl? ( !dev-db/mytop )"
-
-mysql_version_is_at_least "5.5.7" \
-&& DEPEND="${DEPEND} systemtap? ( >=dev-util/systemtap-1.3 )" \
-&& DEPEND="${DEPEND} kernel_linux? ( dev-libs/libaio )"
-
-mysql_version_is_at_least "5.5" \
-&& DEPEND="${DEPEND} jemalloc? ( dev-libs/jemalloc )"
+if mysql_version_is_at_least "5.5" ; then
+ DEPEND="${DEPEND} jemalloc? ( dev-libs/jemalloc )"
+ DEPEND="${DEPEND} tcmalloc? ( dev-util/google-perftools )"
+fi
-mysql_version_is_at_least "5.5" \
-&& DEPEND="${DEPEND} tcmalloc? ( dev-util/google-perftools )"
+if mysql_version_is_at_least "5.5.7" ; then
+ DEPEND="${DEPEND} systemtap? ( >=dev-util/systemtap-1.3 )"
+ DEPEND="${DEPEND} kernel_linux? ( dev-libs/libaio )"
+fi
# prefix: first need to implement something for #196294
RDEPEND="${DEPEND}
@@ -265,15 +255,6 @@ RDEPEND="${DEPEND}
selinux? ( sec-policy/selinux-mysql )
"
-# Bug 455016 Add dependancies of mytop
-([[ ${PN} == "mariadb" ]] || [[ "${PN}" == "mariadb-galera" ]])\
-&& mysql_version_is_at_least "5.3" \
-&& RDEPEND="${RDEPEND} perl? (
- virtual/perl-Getopt-Long
- dev-perl/TermReadKey
- virtual/perl-Term-ANSIColor
- virtual/perl-Time-HiRes ) "
-
DEPEND="${DEPEND}
virtual/yacc
"
@@ -284,8 +265,9 @@ DEPEND="${DEPEND} static? ( sys-libs/ncurses[static-libs] )"
DEPEND="${DEPEND} >=dev-util/cmake-2.4.3"
# compile-time-only
-mysql_version_is_at_least "5.5.8" \
-&& DEPEND="${DEPEND} >=dev-util/cmake-2.6.3"
+if mysql_version_is_at_least "5.5.8" ; then
+ DEPEND="${DEPEND} >=dev-util/cmake-2.6.3"
+fi
# dev-perl/DBD-mysql is needed by some scripts installed by MySQL
PDEPEND="perl? ( >=dev-perl/DBD-mysql-2.9004 )"
@@ -301,14 +283,11 @@ PDEPEND="${PDEPEND} =virtual/mysql-${MYSQL_PV_MAJOR}"
# PBXT_VERSION means that we have a PBXT patch for this PV
# PBXT was only introduced after 5.1.12
pbxt_patch_available() {
- [[ ${PN} != "mariadb" ]] && [[ ${PN} != "mariadb-galera" ]]\
- && [[ -n "${PBXT_VERSION}" ]]
- return $?
+ [[ ${PN} != "mariadb" && ${PN} != "mariadb-galera" && ( -n "${PBXT_VERSION}" ) ]]
}
pbxt_available() {
- pbxt_patch_available || [[ ${PN} == "mariadb" ]] || [[ ${PN} == "mariadb-galera" ]]
- return $?
+ pbxt_patch_available || [[ ${PN} == "mariadb" || ${PN} == "mariadb-galera" ]]
}
# Get the percona tarball if XTRADB_VER and PERCONA_VER are both set
@@ -316,18 +295,15 @@ pbxt_available() {
# XTRADB_VERS means that we have a XTRADB patch for this PV
# XTRADB was only introduced after 5.1.26
xtradb_patch_available() {
- [[ ${PN} != "mariadb" ]] && [[ ${PN} != "mariadb-galera" ]] \
- && [[ -n "${XTRADB_VER}" && -n "${PERCONA_VER}" ]]
- return $?
+ [[ ${PN} != "mariadb" && ${PN} != "mariadb-galera"
+ && ( -n "${XTRADB_VER}" ) && ( -n "${PERCONA_VER}" ) ]]
}
-
if pbxt_patch_available; then
PBXT_P="pbxt-${PBXT_VERSION}"
PBXT_SRC_URI="http://www.primebase.org/download/${PBXT_P}.tar.gz mirror://sourceforge/pbxt/${PBXT_P}.tar.gz"
SRC_URI="${SRC_URI} pbxt? ( ${PBXT_SRC_URI} )"
-
fi
# PBXT_NEWSTYLE means pbxt is in storage/ and gets enabled as other plugins
@@ -399,8 +375,7 @@ mysql-v2_pkg_setup() {
fi
# Check for USE flag problems in pkg_setup
- if ! mysql_version_is_at_least "5.2" \
- && use debug ; then
+ if ! mysql_version_is_at_least "5.2" && use debug ; then
# Also in package.use.mask
die "Bug #344885: Upstream has broken USE=debug for 5.1 series >=5.1.51"
fi
@@ -502,13 +477,13 @@ mysql-v2_pkg_postinst() {
docinto "scripts"
for script in scripts/mysql* ; do
- [[ -f "${script}" ]] \
- && [[ "${script%.sh}" == "${script}" ]] \
- && dodoc "${script}"
+ if [[ -f "${script}" && "${script%.sh}" == "${script}" ]]; then
+ dodoc "${script}"
+ fi
done
- if [ ${PN} == "mariadb" ] \
- && mysql_version_is_at_least "5.2.10" && use pam ; then
+ if [[ ${PN} == "mariadb" || ${PN} == "mariadb-galera" ]] \
+ && mysql_version_is_at_least "5.2.10" && use pam ; then
einfo
elog "This install includes the PAM authentication plugin."
elog "To activate and configure the PAM plugin, please read:"
@@ -589,7 +564,7 @@ mysql-v2_pkg_config() {
local old_MY_DATADIR_s="${ROOT}/${old_MY_DATADIR}"
old_MY_DATADIR_s="${old_MY_DATADIR_s%%/}"
- if [[ -d "${old_MY_DATADIR_s}" ]] && [[ "${old_MY_DATADIR_s}" != / ]]; then
+ if [[ ( -d "${old_MY_DATADIR_s}" ) && ( "${old_MY_DATADIR_s}" != / ) ]]; then
if [[ -d "${MY_DATADIR_s}" ]]; then
ewarn "Both ${old_MY_DATADIR_s} and ${MY_DATADIR_s} exist"
ewarn "Attempting to use ${MY_DATADIR_s} and preserving ${old_MY_DATADIR_s}"
@@ -692,7 +667,7 @@ mysql-v2_pkg_config() {
pushd "${TMPDIR}" &>/dev/null
#cmd="'${EROOT}/usr/share/mysql/scripts/mysql_install_db' '--basedir=${EPREFIX}/usr' ${options}"
cmd=${EROOT}usr/share/mysql/scripts/mysql_install_db
- [ -f ${cmd} ] || cmd=${EROOT}usr/bin/mysql_install_db
+ [[ -f ${cmd} ]] || cmd=${EROOT}usr/bin/mysql_install_db
cmd="'$cmd' '--basedir=${EPREFIX}/usr' ${options}"
einfo "Command: $cmd"
eval $cmd \
@@ -773,7 +748,7 @@ mysql-v2_pkg_config() {
mysql < "${sqltmp}"
rc=$?
eend $?
- [ $rc -ne 0 ] && ewarn "Failed to load zoneinfo!"
+ [[ $rc -ne 0 ]] && ewarn "Failed to load zoneinfo!"
# Stop the server and cleanup
einfo "Stopping the server ..."
next reply other threads:[~2013-04-30 10:17 UTC|newest]
Thread overview: 252+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-30 10:17 Jorge Manuel B. S. Vicetto [this message]
-- strict thread matches above, loose matches on Subject: below --
2018-06-22 13:22 [gentoo-commits] proj/mysql:master commit in: eclass/ Thomas Deutschmann
2017-11-15 14:28 Brian Evans
2017-07-17 19:24 Brian Evans
2017-07-09 2:42 Brian Evans
2017-05-19 12:51 Brian Evans
2017-05-02 17:16 Brian Evans
2017-03-28 14:44 Brian Evans
2017-03-28 14:36 Brian Evans
2017-03-17 17:53 Brian Evans
2017-02-01 18:37 Brian Evans
2016-09-27 16:44 Brian Evans
2016-09-27 16:44 Brian Evans
2016-09-27 16:44 Brian Evans
2016-05-11 18:55 Brian Evans
2016-03-24 14:32 Brian Evans
2016-03-10 1:26 Brian Evans
2016-03-09 20:22 Brian Evans
2016-02-27 3:28 Brian Evans
2016-02-17 3:30 Brian Evans
2016-02-10 2:59 Brian Evans
2016-02-07 20:41 Brian Evans
2016-02-07 20:29 Brian Evans
2015-12-31 18:34 Brian Evans
2015-12-23 15:09 Brian Evans
2015-11-18 14:31 Brian Evans
2015-11-02 21:51 Brian Evans
2015-10-30 18:33 Brian Evans
2015-10-30 18:33 Brian Evans
2015-10-26 16:54 Brian Evans
2015-10-26 16:54 Brian Evans
2015-10-26 16:54 Brian Evans
2015-10-21 19:12 Brian Evans
2015-10-19 18:48 Brian Evans
2015-09-23 2:51 Brian Evans
2015-09-18 18:45 Brian Evans
2015-09-18 17:33 Brian Evans
2015-09-18 15:06 Brian Evans
2015-09-18 15:01 Brian Evans
2015-09-17 1:41 Brian Evans
2015-09-15 12:56 Brian Evans
2015-09-14 19:14 Brian Evans
2015-08-27 13:28 Brian Evans
2015-08-13 13:50 Brian Evans
2015-07-31 2:49 Brian Evans
2015-07-29 15:02 Brian Evans
2015-07-28 22:27 Brian Evans
2015-07-27 20:28 Brian Evans
2015-06-12 20:11 Brian Evans
2015-06-10 18:09 Brian Evans
2015-05-01 18:49 Brian Evans
2015-05-01 12:40 Brian Evans
2015-05-01 12:28 Brian Evans
2015-03-17 19:45 Brian Evans
2015-03-17 19:45 Brian Evans
2015-03-08 23:48 Brian Evans
2015-02-10 18:36 Brian Evans
2015-01-30 19:37 Brian Evans
2015-01-28 15:51 Brian Evans
2015-01-27 3:41 Brian Evans
2014-12-30 15:30 Brian Evans
2014-11-26 0:35 Brian Evans
2014-11-23 20:12 Brian Evans
2014-11-23 19:59 Brian Evans
2014-11-23 2:32 Brian Evans
2014-11-23 1:53 Brian Evans
2014-11-18 19:35 Brian Evans
2014-10-25 3:09 Brian Evans
2014-10-25 2:53 Brian Evans
2014-10-22 19:35 Brian Evans
2014-10-21 16:38 Brian Evans
2014-10-20 20:52 Brian Evans
2014-10-08 17:28 Brian Evans
2014-09-26 20:32 Brian Evans
2014-09-17 20:24 Brian Evans
2014-09-13 14:57 Brian Evans
2014-09-03 18:10 Brian Evans
2014-08-29 20:34 Brian Evans
2014-08-29 20:34 Brian Evans
2014-08-22 18:15 Brian Evans
2014-08-21 18:25 Brian Evans
2014-08-21 17:53 Brian Evans
2014-08-19 18:41 Brian Evans
2014-08-19 18:41 Brian Evans
2014-08-10 5:48 Robin H. Johnson
2014-07-31 20:24 Brian Evans
2014-07-31 2:33 Brian Evans
2014-07-29 20:24 Robin H. Johnson
2014-07-29 17:59 Robin H. Johnson
2014-07-29 17:59 Robin H. Johnson
2014-07-02 1:02 Brian Evans
2014-06-19 17:33 Brian Evans
2014-06-19 1:35 Brian Evans
2014-06-18 19:46 Brian Evans
2014-06-04 0:51 Brian Evans
2014-05-19 17:02 Brian Evans
2014-05-16 0:25 Brian Evans
2014-05-15 18:07 Brian Evans
2014-05-15 3:11 Brian Evans
2014-05-14 14:50 Brian Evans
2014-05-14 13:37 Brian Evans
2014-05-14 2:31 Brian Evans
2014-05-13 19:19 Brian Evans
2014-05-13 3:14 Brian Evans
2014-05-08 17:20 Brian Evans
2014-05-08 17:09 Brian Evans
2014-04-30 20:39 Brian Evans
2014-04-28 18:10 Brian Evans
2014-04-28 18:10 Brian Evans
2014-04-23 13:18 Brian Evans
2014-04-22 13:58 Brian Evans
2014-04-22 1:49 Jorge Manuel B. S. Vicetto
2014-04-22 1:49 Jorge Manuel B. S. Vicetto
2014-04-22 1:49 Jorge Manuel B. S. Vicetto
2014-04-14 18:55 Brian Evans
2014-04-08 2:17 Brian Evans
2014-04-02 17:38 Brian Evans
2014-03-26 23:12 Brian Evans
2014-03-26 23:12 Brian Evans
2014-03-19 16:47 Brian Evans
2014-03-11 23:12 Brian Evans
2014-03-11 23:12 Brian Evans
2014-03-11 20:07 Brian Evans
2014-03-07 20:30 Brian Evans
2014-03-06 18:15 Brian Evans
2014-03-06 18:12 Brian Evans
2014-03-05 16:00 Brian Evans
2014-03-04 21:54 Brian Evans
2014-02-04 21:13 Brian Evans
2014-01-24 18:54 Brian Evans
2014-01-20 14:04 Brian Evans
2014-01-19 15:34 Brian Evans
2014-01-06 20:21 Brian Evans
2013-11-22 17:52 Brian Evans
2013-11-19 15:19 Brian Evans
2013-11-12 16:29 Brian Evans
2013-11-07 19:44 Brian Evans
2013-11-07 19:44 Brian Evans
2013-11-06 23:53 Jorge Manuel B. S. Vicetto
2013-11-01 14:00 Brian Evans
2013-09-24 19:16 Brian Evans
2013-09-20 22:29 Brian Evans
2013-09-20 22:29 Brian Evans
2013-09-20 15:13 Brian Evans
2013-09-18 20:32 Brian Evans
2013-08-10 15:15 Brian Evans
2013-07-18 12:44 Brian Evans
2013-07-16 2:48 Brian Evans
2013-06-27 14:20 Brian Evans
2013-06-26 19:19 Jorge Manuel B. S. Vicetto
2013-06-12 18:21 Robin H. Johnson
2013-05-01 2:04 Jorge Manuel B. S. Vicetto
2013-05-01 1:09 Jorge Manuel B. S. Vicetto
2013-04-29 23:57 Jorge Manuel B. S. Vicetto
2013-04-28 16:20 Jorge Manuel B. S. Vicetto
2013-04-28 16:20 Jorge Manuel B. S. Vicetto
2013-04-28 16:20 Jorge Manuel B. S. Vicetto
2013-04-28 16:20 Jorge Manuel B. S. Vicetto
2013-04-28 16:20 Jorge Manuel B. S. Vicetto
2013-04-25 17:38 Robin H. Johnson
2013-04-25 0:43 Jorge Manuel B. S. Vicetto
2013-03-21 19:43 Robin H. Johnson
2013-03-16 19:35 Robin H. Johnson
2013-03-16 19:20 Robin H. Johnson
2013-03-16 19:19 Robin H. Johnson
2013-03-16 19:19 Robin H. Johnson
2013-03-04 20:24 Robin H. Johnson
2013-02-12 22:47 Robin H. Johnson
2013-02-12 22:47 Robin H. Johnson
2013-02-12 22:47 Robin H. Johnson
2013-01-28 2:20 Robin H. Johnson
2013-01-28 2:13 Robin H. Johnson
2013-01-28 2:13 Robin H. Johnson
2013-01-28 2:13 Robin H. Johnson
2013-01-28 2:13 Robin H. Johnson
2013-01-28 2:13 Robin H. Johnson
2013-01-20 23:02 Robin H. Johnson
2013-01-20 23:02 Robin H. Johnson
2013-01-20 2:15 Robin H. Johnson
2013-01-20 2:15 Robin H. Johnson
2013-01-20 2:15 Robin H. Johnson
2012-11-24 19:41 Robin H. Johnson
2012-11-02 0:05 Robin H. Johnson
2012-11-01 20:20 Robin H. Johnson
2012-11-01 20:20 Robin H. Johnson
2012-11-01 20:20 Robin H. Johnson
2012-08-03 17:38 Robin H. Johnson
2012-07-31 17:01 Robin H. Johnson
2012-07-27 16:09 Robin H. Johnson
2012-07-27 16:09 Robin H. Johnson
2012-07-27 16:09 Robin H. Johnson
2012-07-27 16:09 Robin H. Johnson
2012-07-27 16:09 Robin H. Johnson
2012-07-27 16:09 Robin H. Johnson
2012-07-26 4:51 Robin H. Johnson
2012-07-26 4:51 Robin H. Johnson
2012-07-23 10:13 Jorge Manuel B. S. Vicetto
2012-07-23 10:12 Jorge Manuel B. S. Vicetto
2012-05-22 12:09 Jorge Manuel B. S. Vicetto
2012-05-15 22:50 Robin H. Johnson
2012-04-18 2:14 Robin H. Johnson
2012-04-18 2:14 Robin H. Johnson
2012-04-05 20:41 Robin H. Johnson
2012-04-02 0:21 Robin H. Johnson
2012-02-15 19:21 Jorge Manuel B. S. Vicetto
2012-02-15 4:27 Jorge Manuel B. S. Vicetto
2012-02-15 4:27 Jorge Manuel B. S. Vicetto
2012-02-15 2:45 Jorge Manuel B. S. Vicetto
2012-02-02 2:50 Robin H. Johnson
2012-01-12 19:17 Jorge Manuel B. S. Vicetto
2012-01-06 19:50 Robin H. Johnson
2012-01-06 19:50 Robin H. Johnson
2012-01-06 15:26 Jorge Manuel B. S. Vicetto
2011-12-20 9:05 Jorge Manuel B. S. Vicetto
2011-12-20 8:42 Jorge Manuel B. S. Vicetto
2011-12-20 8:42 Jorge Manuel B. S. Vicetto
2011-12-20 8:42 Jorge Manuel B. S. Vicetto
2011-12-20 8:42 Jorge Manuel B. S. Vicetto
2011-12-20 8:42 Jorge Manuel B. S. Vicetto
2011-12-20 8:42 Jorge Manuel B. S. Vicetto
2011-11-17 21:43 Robin H. Johnson
2011-10-26 19:45 Jorge Manuel B. S. Vicetto
2011-10-07 4:31 Jorge Manuel B. S. Vicetto
2011-09-30 2:53 Jorge Manuel B. S. Vicetto
2011-09-30 2:51 Jorge Manuel B. S. Vicetto
2011-09-30 2:08 Jorge Manuel B. S. Vicetto
2011-09-22 9:45 Jorge Manuel B. S. Vicetto
2011-09-22 2:08 Jorge Manuel B. S. Vicetto
2011-08-21 16:13 Jorge Manuel B. S. Vicetto
2011-08-19 20:02 Jorge Manuel B. S. Vicetto
2011-07-29 2:25 Jorge Manuel B. S. Vicetto
2011-07-21 5:56 Jorge Manuel B. S. Vicetto
2011-07-20 17:05 Jorge Manuel B. S. Vicetto
2011-07-17 12:46 Jorge Manuel B. S. Vicetto
2011-07-14 2:07 Jorge Manuel B. S. Vicetto
2011-07-13 16:06 Jorge Manuel B. S. Vicetto
2011-07-13 6:59 Robin H. Johnson
2011-07-13 6:59 Robin H. Johnson
2011-06-14 2:59 Jorge Manuel B. S. Vicetto
2011-06-12 18:22 Jorge Manuel B. S. Vicetto
2011-05-19 4:13 Jorge Manuel B. S. Vicetto
2011-05-07 19:19 Robin H. Johnson
2011-04-21 12:16 Robin H. Johnson
2011-04-21 12:14 Robin H. Johnson
2011-04-20 10:50 Jorge Manuel B. S. Vicetto
2011-04-17 17:33 Robin H. Johnson
2011-04-17 5:29 Robin H. Johnson
2011-04-17 3:56 Jorge Manuel B. S. Vicetto
2011-03-28 22:35 Jorge Manuel B. S. Vicetto
2011-03-26 22:53 Jorge Manuel B. S. Vicetto
2011-03-26 22:08 Jorge Manuel B. S. Vicetto
2011-03-03 1:08 Jorge Manuel B. S. Vicetto
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1367316810.7880308a3ef25f6e2945dc364fff3cc8a2eb84f4.jmbsvicetto@gentoo \
--to=jmbsvicetto@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox