summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2010-02-01 01:07:08 +0000
committerRobin H. Johnson <robbat2@gentoo.org>2010-02-01 01:07:08 +0000
commit3ec2725937bed2ee467f9b1d1b2473aac7e857f8 (patch)
tree4243caf38f5bed9d1e48ae66f3b242e718cc9470 /eclass
parentwhitespace (diff)
downloadgentoo-2-3ec2725937bed2ee467f9b1d1b2473aac7e857f8.tar.gz
gentoo-2-3ec2725937bed2ee467f9b1d1b2473aac7e857f8.tar.bz2
gentoo-2-3ec2725937bed2ee467f9b1d1b2473aac7e857f8.zip
Fixup disabling tests for 5.1 and also gcc-version usage.
Diffstat (limited to 'eclass')
-rw-r--r--eclass/mysql.eclass45
1 files changed, 38 insertions, 7 deletions
diff --git a/eclass/mysql.eclass b/eclass/mysql.eclass
index 634af30ec9c1..50c152075638 100644
--- a/eclass/mysql.eclass
+++ b/eclass/mysql.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/mysql.eclass,v 1.126 2010/01/31 05:47:21 robbat2 Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/mysql.eclass,v 1.127 2010/02/01 01:07:08 robbat2 Exp $
# @ECLASS: mysql.eclass
# @MAINTAINER:
@@ -18,7 +18,7 @@
WANT_AUTOCONF="latest"
WANT_AUTOMAKE="latest"
-inherit eutils flag-o-matic gnuconfig autotools mysql_fx versionator
+inherit eutils flag-o-matic gnuconfig autotools mysql_fx versionator toolchain-funcs
# Shorten the path because the socket path length must be shorter than 107 chars
# and we will run a mysql server during test phase
@@ -209,11 +209,42 @@ mysql_version_is_at_least "5.1.26" \
# @DESCRIPTION:
# Helper function to disable specific tests.
mysql_disable_test() {
- local testname="${1}" ; shift
- local reason="${@}"
- local mysql_disable_file="${S}/mysql-test/t/disabled.def"
+ local rawtestname testname testsuite reason mysql_disable_file
+ rawtestname="${1}" ; shift
+ reason="${@}"
+ ewarn "test '${rawtestname}' disabled: '${reason}'"
+
+ testsuite="${rawtestname/.*}"
+ testname="${rawtestname/*.}"
+ mysql_disable_file="${S}/mysql-test/t/disabled.def"
+ einfo "rawtestname=${rawtestname} testname=${testname} testsuite=${testsuite}"
echo ${testname} : ${reason} >> "${mysql_disable_file}"
- ewarn "test '${testname}' disabled: '${reason}'"
+
+ # ${S}/mysql-tests/t/disabled.def
+ #
+ # ${S}/mysql-tests/suite/federated/disabled.def
+ #
+ # ${S}/mysql-tests/suite/jp/t/disabled.def
+ # ${S}/mysql-tests/suite/ndb/t/disabled.def
+ # ${S}/mysql-tests/suite/rpl/t/disabled.def
+ # ${S}/mysql-tests/suite/parts/t/disabled.def
+ # ${S}/mysql-tests/suite/rpl_ndb/t/disabled.def
+ # ${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
+ 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
+ done
+ if [ "${mysql_disabled_file}" != "FAILED" ]; then
+ echo "${testname} : ${reason}" >> "${mysql_disable_file}"
+ else
+ ewarn "Could not find testsuite disabled.def location for ${rawtestname}"
+ fi
+ fi
}
# @FUNCTION: mysql_init_vars
@@ -555,7 +586,7 @@ mysql_pkg_setup() {
# Bug #290570 fun. Upstream made us need a fairly new GCC4.
if mysql_version_is_at_least "5.0.83" ; then
- GCC_VER=$(gcc_version)
+ GCC_VER=$(gcc-version)
case ${GCC_VER} in
2*|3*|4.0|4.1|4.2) die "Active GCC too old! Must have at least GCC4.3" ;;
esac