/[gentoo-x86]/dev-db/mariadb/mariadb-5.1.50.ebuild
Gentoo

Contents of /dev-db/mariadb/mariadb-5.1.50.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Fri Apr 13 17:55:05 2012 UTC (2 years, 3 months ago) by ulm
Branch: MAIN
Changes since 1.3: +2 -2 lines
Move EAPI assignment to top of ebuild, bug 411875.

(Portage version: 2.1.10.56/cvs/Linux x86_64)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/dev-db/mariadb/mariadb-5.1.50.ebuild,v 1.3 2012/01/08 23:55:47 jmbsvicetto Exp $
4
5 EAPI="4"
6 MY_EXTRAS_VER="20101006-0004Z"
7
8 inherit toolchain-funcs mysql
9 # only to make repoman happy. it is really set in the eclass
10 IUSE="$IUSE"
11
12 # REMEMBER: also update eclass/mysql*.eclass before committing!
13 KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd"
14
15 # When MY_EXTRAS is bumped, the index should be revised to exclude these.
16 EPATCH_EXCLUDE=''
17
18 # Most of these are in the eclass
19 RDEPEND=""
20 DEPEND="|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
21 >=sys-devel/libtool-2.2.10"
22
23 # Please do not add a naive src_unpack to this ebuild
24 # If you want to add a single patch, copy the ebuild to an overlay
25 # and create your own mysql-extras tarball, looking at 000_index.txt
26 src_prepare() {
27 sed -i \
28 -e '/^noinst_PROGRAMS/s/basic-t//g' \
29 "${S}"/unittest/mytap/t/Makefile.am
30 mysql_src_prepare
31 }
32
33 # Official test instructions:
34 # USE='berkdb -cluster embedded extraengine perl ssl community' \
35 # FEATURES='test userpriv -usersandbox' \
36 # ebuild mysql-X.X.XX.ebuild \
37 # digest clean package
38 src_test() {
39 # Bug #213475 - MySQL _will_ object strenously if your machine is named
40 # localhost. Also causes weird failures.
41 [[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
42
43 emake check || die "make check failed"
44 if ! use "minimal" ; then
45 if [[ $UID -eq 0 ]]; then
46 die "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
47 fi
48 has usersandbox $FEATURES && eerror "Some tests may fail with FEATURES=usersandbox"
49 cd "${S}"
50 einfo ">>> Test phase [test]: ${CATEGORY}/${PF}"
51 local retstatus_unit
52 local retstatus_ns
53 local retstatus_ps
54 local t
55 addpredict /this-dir-does-not-exist/t9.MYI
56
57 # Ensure that parallel runs don't die
58 export MTR_BUILD_THREAD="$((${RANDOM} % 100))"
59
60 # archive_gis really sucks a lot, but it's only relevant for the
61 # USE=extraengines case
62 case ${PV} in
63 5.0.42)
64 mysql_disable_test "archive_gis" "Totally broken in 5.0.42"
65 ;;
66
67 5.0.4[3-9]|5.0.[56]*|5.0.70|5.0.87)
68 [ "$(tc-endian)" == "big" ] && \
69 mysql_disable_test \
70 "archive_gis" \
71 "Broken in 5.0.43-70 and 5.0.87 on big-endian boxes only"
72 ;;
73 esac
74
75 # This was a slight testcase breakage when the read_only security issue
76 # was fixed.
77 case ${PV} in
78 5.0.54|5.0.51*)
79 mysql_disable_test \
80 "read_only" \
81 "Broken in 5.0.51-54, output in wrong order"
82 ;;
83 esac
84
85 # Ditto to read_only
86 [ "${PV}" == "5.0.51a" ] && \
87 mysql_disable_test \
88 "view" \
89 "Broken in 5.0.51, output in wrong order"
90
91 # x86-specific, OOM issue with some subselects on low memory servers
92 [ "${PV}" == "5.0.54" ] && \
93 [ "${ARCH/x86}" != "${ARCH}" ] && \
94 mysql_disable_test \
95 "subselect" \
96 "Testcase needs tuning on x86 for oom condition"
97
98 # Broke with the YaSSL security issue that didn't affect Gentoo.
99 [ "${PV}" == "5.0.56" ] && \
100 for t in openssl_1 rpl_openssl rpl_ssl ssl \
101 ssl_8k_key ssl_compress ssl_connect ; do \
102 mysql_disable_test \
103 "$t" \
104 "OpenSSL tests broken on 5.0.56"
105 done
106
107 # New test was broken in first time
108 # Upstream bug 41066
109 # http://bugs.mysql.com/bug.php?id=41066
110 [ "${PV}" == "5.0.72" ] && \
111 mysql_disable_test \
112 "status2" \
113 "Broken in 5.0.72, new test is broken, upstream bug #41066"
114
115 # The entire 5.0 series has pre-generated SSL certificates, they have
116 # mostly expired now. ${S}/mysql-tests/std-data/*.pem
117 # The certs really SHOULD be generated for the tests, so that they are
118 # not expiring like this. We cannot do so ourselves as the tests look
119 # closely as the cert path data, and we do not have the CA key to regen
120 # ourselves. Alternatively, upstream should generate them with at least
121 # 50-year validity.
122 #
123 # Known expiry points:
124 # 4.1.*, 5.0.0-5.0.22, 5.1.7: Expires 2013/09/09
125 # 5.0.23-5.0.77, 5.1.7-5.1.22?: Expires 2009/01/27
126 # 5.0.78-5.0.90, 5.1.??-5.1.42: Expires 2010/01/28
127 #
128 # mysql-test/std_data/untrusted-cacert.pem is MEANT to be
129 # expired/invalid.
130 case ${PV} in
131 5.0.*|5.1.*|5.4.*|5.5.*)
132 for t in openssl_1 rpl_openssl rpl.rpl_ssl rpl.rpl_ssl1 ssl ssl_8k_key \
133 ssl_compress ssl_connect rpl.rpl_heartbeat_ssl ; do \
134 mysql_disable_test \
135 "$t" \
136 "These OpenSSL tests break due to expired certificates"
137 done
138 ;;
139 esac
140
141 # These are also failing in MySQL 5.1 for now, and are believed to be
142 # false positives:
143 #
144 # main.mysql_comment, main.mysql_upgrade, main.information_schema,
145 # funcs_1.is_columns_mysql funcs_1.is_tables_mysql funcs_1.is_triggers:
146 # fails due to USE=-latin1 / utf8 default
147 #
148 # main.mysql_client_test:
149 # segfaults at random under Portage only, suspect resource limits.
150 #
151 # main.not_partition:
152 # Failure reason unknown at this time, must resolve before package.mask
153 # removal FIXME
154 case ${PV} in
155 5.1.*|5.4.*|5.5.*)
156 for t in main.mysql_client_test main.mysql_comments \
157 main.mysql_upgrade \
158 main.information_schema \
159 main.not_partition funcs_1.is_columns_mysql \
160 funcs_1.is_tables_mysql funcs_1.is_triggers; do
161 mysql_disable_test "$t" "False positives in Gentoo"
162 done
163 ;;
164 esac
165
166 # New failures in 5.1.50/5.1.51, reported by jmbsvicetto.
167 # These tests are picking up a 'connect-timeout' config from somewhere,
168 # which is not valid, and since it does not have 'loose-' in front of
169 # it, it's causing a failure
170 case ${PV} in
171 5.1.5*|5.4.*|5.5.*|6*)
172 for t in rpl.rpl_mysql_upgrade main.log_tables_upgrade ; do
173 mysql_disable_test "$t" \
174 "False positives in Gentoo: connect-timeout"
175 done
176 ;;
177 esac
178
179 use profiling && use community \
180 || mysql_disable_test main.profiling \
181 "Profiling test needs profiling support"
182
183 if [ "${PN}" == "mariadb" ]; then
184 for t in \
185 parts.part_supported_sql_func_ndb \
186 parts.partition_auto_increment_ndb ; do
187 mysql_disable_test $t "ndb not supported in mariadb"
188 done
189 fi
190
191 # create directories because mysqladmin might make out of order
192 mkdir -p "${S}"/mysql-test/var-{ps,ns}{,/log}
193
194 # We run the test protocols seperately
195 emake test-unit
196 retstatus_unit=$?
197 [[ $retstatus_unit -eq 0 ]] || eerror "test-unit failed"
198
199 emake test-ns force="--force --vardir=${S}/mysql-test/var-ns"
200 retstatus_ns=$?
201 [[ $retstatus_ns -eq 0 ]] || eerror "test-ns failed"
202 has usersandbox $FEATURES && eerror "Some tests may fail with FEATURES=usersandbox"
203
204 emake test-ps force="--force --vardir=${S}/mysql-test/var-ps"
205 retstatus_ps=$?
206 [[ $retstatus_ps -eq 0 ]] || eerror "test-ps failed"
207 has usersandbox $FEATURES && eerror "Some tests may fail with FEATURES=usersandbox"
208
209 # TODO:
210 # When upstream enables the pr and nr testsuites, we need those as well.
211
212 # Cleanup is important for these testcases.
213 pkill -9 -f "${S}/ndb" 2>/dev/null
214 pkill -9 -f "${S}/sql" 2>/dev/null
215 failures=""
216 [[ $retstatus_unit -eq 0 ]] || failures="${failures} test-unit"
217 [[ $retstatus_ns -eq 0 ]] || failures="${failures} test-ns"
218 [[ $retstatus_ps -eq 0 ]] || failures="${failures} test-ps"
219 has usersandbox $FEATURES && eerror "Some tests may fail with FEATURES=usersandbox"
220 [[ -z "$failures" ]] || die "Test failures: $failures"
221 einfo "Tests successfully completed"
222 else
223 einfo "Skipping server tests due to minimal build."
224 fi
225 }

  ViewVC Help
Powered by ViewVC 1.1.20