summaryrefslogtreecommitdiff
path: root/dev-db
diff options
context:
space:
mode:
authorFrancesco Riosa <vivo@gentoo.org>2005-10-22 14:29:44 +0000
committerFrancesco Riosa <vivo@gentoo.org>2005-10-22 14:29:44 +0000
commit7c5cc072ba77d1f49bdb590f26f4fbebcf586fa8 (patch)
tree969a898809afe486ad67d092e25a04d30a6fb286 /dev-db
parenttypeaheadfind patch moved to mirrors (diff)
downloadgentoo-2-7c5cc072ba77d1f49bdb590f26f4fbebcf586fa8.tar.gz
gentoo-2-7c5cc072ba77d1f49bdb590f26f4fbebcf586fa8.tar.bz2
gentoo-2-7c5cc072ba77d1f49bdb590f26f4fbebcf586fa8.zip
fix Bug #109951 and Bug #109881; cleanup ; version bump for 4.1 series
(Portage version: 2.0.52-r1)
Diffstat (limited to 'dev-db')
-rw-r--r--dev-db/mysql/ChangeLog19
-rw-r--r--dev-db/mysql/Manifest12
-rw-r--r--dev-db/mysql/files/digest-mysql-4.0.22-r22
-rw-r--r--dev-db/mysql/files/digest-mysql-4.0.242
-rw-r--r--dev-db/mysql/files/digest-mysql-4.1.15 (renamed from dev-db/mysql/files/digest-mysql-4.0.22)2
-rw-r--r--dev-db/mysql/files/digest-mysql-5.0.12_beta2
-rw-r--r--dev-db/mysql/mysql-4.0.22-r2.ebuild303
-rw-r--r--dev-db/mysql/mysql-4.0.22.ebuild274
-rw-r--r--dev-db/mysql/mysql-4.0.24.ebuild305
-rw-r--r--dev-db/mysql/mysql-4.0.25-r2.ebuild30
-rw-r--r--dev-db/mysql/mysql-4.0.26.ebuild30
-rw-r--r--dev-db/mysql/mysql-4.1.14.ebuild30
-rw-r--r--dev-db/mysql/mysql-4.1.15.ebuild (renamed from dev-db/mysql/mysql-5.0.12_beta.ebuild)118
-rw-r--r--dev-db/mysql/mysql-5.0.13_rc.ebuild32
14 files changed, 186 insertions, 975 deletions
diff --git a/dev-db/mysql/ChangeLog b/dev-db/mysql/ChangeLog
index 10b307ff1859..002f82c7c5b8 100644
--- a/dev-db/mysql/ChangeLog
+++ b/dev-db/mysql/ChangeLog
@@ -1,6 +1,23 @@
# ChangeLog for dev-db/mysql
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/ChangeLog,v 1.252 2005/10/21 08:58:03 vivo Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/ChangeLog,v 1.253 2005/10/22 14:29:44 vivo Exp $
+
+*mysql-4.1.15 (22 Oct 2005)
+
+ 22 Oct 2005; Francesco Riosa <vivo@gentoo.org> -mysql-4.0.22.ebuild,
+ -mysql-4.0.22-r2.ebuild, -mysql-4.0.24.ebuild, mysql-4.0.25-r2.ebuild,
+ mysql-4.0.26.ebuild, -mysql-4.1.13-r1.ebuild, mysql-4.1.14.ebuild,
+ +mysql-4.1.15.ebuild, -mysql-5.0.12_beta.ebuild, mysql-5.0.13_rc.ebuild:
+ - fix Bug #109951 and Bug #109881
+ Moved again creation of /var/log/mysql/* where it does not cause
+ problems with FEATURES="collision-protect".
+ Side effect of the previous bug fix is that /var/log/mysql/* files
+ are not included anymore in the binpkg
+ - cleanup of old ebuilds
+ - version bump for 4.1.15
+ Disabling "raid" support with "static" use flag
+ test suite has inverted behaviour than 4.1.14, need to use the perl
+ based one here
21 Oct 2005; Francesco Riosa <vivo@gentoo.org> mysql-4.0.25-r2.ebuild,
mysql-4.0.26.ebuild, mysql-4.1.14.ebuild, mysql-5.0.12_beta.ebuild,
diff --git a/dev-db/mysql/Manifest b/dev-db/mysql/Manifest
index 771097ad7c58..6f93fb0d7d82 100644
--- a/dev-db/mysql/Manifest
+++ b/dev-db/mysql/Manifest
@@ -1,23 +1,23 @@
-MD5 93eb56e06059b67713409ca833453b4f mysql-5.0.12_beta.ebuild 18257
-MD5 aaee8e5a4acc3549a448b555a8ca301e mysql-4.1.14.ebuild 18271
-MD5 1fdc869b8c6cc92b4474962f7b9af12a mysql-4.0.26.ebuild 14859
-MD5 6a036bc0b84595dc9c1a14a8bca015fa mysql-5.0.13_rc.ebuild 18413
+MD5 605577e54e439ef997c60dbf81910081 mysql-4.1.14.ebuild 18737
+MD5 ca01c6c3bcaaff7d2e1848d93d8eac21 mysql-4.0.26.ebuild 15325
+MD5 40594422ca09721d79a605bf596eeb32 mysql-5.0.13_rc.ebuild 18879
MD5 c3f09dc9b5a59873d8ebe67b2096789b mysql-4.1.13-r1.ebuild 17592
+MD5 c4c41430e8e3d8eb9e2fbcd6ee2272ec mysql-4.1.15.ebuild 18859
MD5 b4e651d8ffcb8b7a92b9bf186081d6e3 mysql-4.0.22.ebuild 8941
MD5 00acf2c6bc09118694e11fafdb7e3970 mysql-4.0.22-r2.ebuild 9814
MD5 eb11a08abb447b7a69b192a6f9be3dbf mysql-3.23.58-r1.ebuild 7219
MD5 ac74397784bc6979c6cee6319f5be131 mysql-4.0.24.ebuild 9833
MD5 62dc1ede4735f8845489e769c7af37de ChangeLog 45557
MD5 a2a9fdc7d010a7c04c96cb3b7c05f06b metadata.xml 158
-MD5 0e2f7e25b805f757847ac60711442bf4 mysql-4.0.25-r2.ebuild 13800
+MD5 6dfee6b40829be9d45c336f4386562e9 mysql-4.0.25-r2.ebuild 14266
MD5 5990b9d1cb5ba35bb7c9d56a00d10f58 files/digest-mysql-4.1.13-r1 139
MD5 625b4007f035e3da9a4f1eeee1db6b9c files/mysql-4.0.15.rc6 1187
MD5 c6fcd70c34bed04e59808ec71c5bedfb files/digest-mysql-3.23.58-r1 140
-MD5 0c3c016fee3edff9a0585290e58f1c26 files/digest-mysql-5.0.12_beta 144
MD5 631ed23db7ff8777599dee1c45edae0f files/digest-mysql-4.0.22 139
MD5 1a7299f19831c9bc9930bd76f381da80 files/digest-mysql-4.0.24 139
MD5 201c8b31cd9eb58eec712e37d6f0c328 files/digest-mysql-4.0.26 139
MD5 4e6e76e3945e29b6795ce6d1a66bc98f files/digest-mysql-4.1.14 139
+MD5 b8eda6b8ec67faff78e5d01023e6eefb files/digest-mysql-4.1.15 139
MD5 73be6460f548f6f73c70246a4cfd13a0 files/mysql.init 886
MD5 713dc46b7ffa15edda542a15508ce07c files/digest-mysql-5.0.13_rc 142
MD5 d200345efa421d012cf858134d2c8884 files/logrotate.mysql 440
diff --git a/dev-db/mysql/files/digest-mysql-4.0.22-r2 b/dev-db/mysql/files/digest-mysql-4.0.22-r2
deleted file mode 100644
index 035eb2307c3d..000000000000
--- a/dev-db/mysql/files/digest-mysql-4.0.22-r2
+++ /dev/null
@@ -1,2 +0,0 @@
-MD5 fab53259c3ba9f729a319bf271fc8587 mysql-4.0.22.tar.gz 14395535
-MD5 5a936d382232f7b4b15fc7d025e9fa8e mysql-extras-20050920.tar.bz2 51007
diff --git a/dev-db/mysql/files/digest-mysql-4.0.24 b/dev-db/mysql/files/digest-mysql-4.0.24
deleted file mode 100644
index 1ccabb481e7e..000000000000
--- a/dev-db/mysql/files/digest-mysql-4.0.24
+++ /dev/null
@@ -1,2 +0,0 @@
-MD5 408d3001ed715ddc90009c247e548638 mysql-4.0.24.tar.gz 16885399
-MD5 5a936d382232f7b4b15fc7d025e9fa8e mysql-extras-20050920.tar.bz2 51007
diff --git a/dev-db/mysql/files/digest-mysql-4.0.22 b/dev-db/mysql/files/digest-mysql-4.1.15
index 035eb2307c3d..6b4725ac1cef 100644
--- a/dev-db/mysql/files/digest-mysql-4.0.22
+++ b/dev-db/mysql/files/digest-mysql-4.1.15
@@ -1,2 +1,2 @@
-MD5 fab53259c3ba9f729a319bf271fc8587 mysql-4.0.22.tar.gz 14395535
+MD5 65a0841e592641b8816f9212aaa40176 mysql-4.1.15.tar.gz 17257765
MD5 5a936d382232f7b4b15fc7d025e9fa8e mysql-extras-20050920.tar.bz2 51007
diff --git a/dev-db/mysql/files/digest-mysql-5.0.12_beta b/dev-db/mysql/files/digest-mysql-5.0.12_beta
deleted file mode 100644
index e2a1b673c4e2..000000000000
--- a/dev-db/mysql/files/digest-mysql-5.0.12_beta
+++ /dev/null
@@ -1,2 +0,0 @@
-MD5 52ce66773505a9128accc64b44d1ecf2 mysql-5.0.12-beta.tar.gz 18798040
-MD5 5a936d382232f7b4b15fc7d025e9fa8e mysql-extras-20050920.tar.bz2 51007
diff --git a/dev-db/mysql/mysql-4.0.22-r2.ebuild b/dev-db/mysql/mysql-4.0.22-r2.ebuild
deleted file mode 100644
index d4c1176b72a8..000000000000
--- a/dev-db/mysql/mysql-4.0.22-r2.ebuild
+++ /dev/null
@@ -1,303 +0,0 @@
-# Copyright 1999-2005 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.0.22-r2.ebuild,v 1.26 2005/10/17 13:49:25 vivo Exp $
-
-inherit eutils gnuconfig
-#to accomodate -laadeedah releases
-NEWP=${P}
-
-SVER=${PV%.*}
-#normal releases:
-SDIR=MySQL-${SVER}
-#for a pre-release:
-#SDIR=MySQL-${SVER}-Pre
-
-S=${WORKDIR}/${NEWP}
-
-DESCRIPTION="A fast, multi-threaded, multi-user SQL database server"
-HOMEPAGE="http://www.mysql.com/"
-SRC_URI="mirror://mysql/Downloads/${SDIR}/${NEWP}.tar.gz
- mirror://gentoo/mysql-extras-20050920.tar.bz2"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="alpha amd64 arm hppa ia64 mips ppc ppc64 s390 sparc x86"
-IUSE="static readline innodb berkdb tcpd ssl perl debug selinux"
-
-DEPEND="readline? ( >=sys-libs/readline-4.1 )
- bdb? ( sys-apps/ed )
- tcpd? ( >=sys-apps/tcp-wrappers-7.6-r6 )
- ssl? ( >=dev-libs/openssl-0.9.6d )
- perl? ( dev-lang/perl )
- >=sys-libs/zlib-1.2.3
- >=sys-apps/texinfo-4.7-r1
- sys-process/procps
- >=sys-apps/sed-4"
-PDEPEND="perl? ( dev-perl/DBI dev-perl/DBD-mysql )"
-RDEPEND="${DEPEND} selinux? ( sec-policy/selinux-mysql )"
-
-mysql_upgrade_warning() {
- ewarn
- ewarn "If you're upgrading from MySQL-3.x to 4.0, or 4.0.x to 4.1.x, you"
- ewarn "must recompile the other packages on your system that link with"
- ewarn "libmysqlclient after the upgrade completes. To obtain such a list"
- ewarn "of packages for your system, you may use 'revdep-rebuild' from"
- ewarn "app-portage/gentoolkit."
- ewarn
- epause 5
-}
-
-
-mysql_get_datadir() {
- DATADIR=""
- if [ -f '/etc/mysql/my.cnf' ] ; then
- #DATADIR=`grep ^datadir /etc/mysql/my.cnf | sed -e 's/.*= //'`
- #DATADIR=`/usr/sbin/mysqld --help |grep '^datadir' | awk '{print $2}'`
- #DATADIR=`my_print_defaults mysqld | grep -- '^--datadir' | tail -n1 | sed -e 's|^--datadir=||'`
- DATADIR=`my_print_defaults mysqld | sed -ne '/datadir/s|^--datadir=||p' | tail -n1`
- fi
- if [ -z "${DATADIR}" ]; then
- DATADIR="/var/lib/mysql/"
- einfo "Using default DATADIR"
- fi
- einfo "MySQL DATADIR is ${DATADIR}"
- export DATADIR
-}
-
-pkg_setup() {
- use innodb || ewarn "InnoDB support is not selected to be compiled in."
- mysql_upgrade_warning
- mysql_get_datadir
-}
-
-src_unpack() {
- if use static && use ssl; then
- local msg="MySQL does not support building statically with SSL support"
- eerror "${msg}"
- die "${msg}"
- fi
- unpack ${A} || die
-
- local MY_PATCH_SOURCE="${WORKDIR}/mysql-extras"
-
- #zap startup script messages
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0.21-install-db-sh.diff || die
- #zap binary distribution stuff
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0.18-mysqld-safe-sh.diff" || die
- #required for qmail-mysql
- EPATCH_OPTS="-p0 -d ${S}" \
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0-nisam.h.diff" || die
- #for correct hardcoded sysconf directory
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0-my-print-defaults.diff" || die
- # NPTL support
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0.18-gentoo-nptl.diff" || die
- # bad tmpfiles in mysqlaccess, see bug 77805
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/mysql-accesstmp.patch || die
-
- # attempt to get libmysqlclient_r linked against ssl if USE="ssl" enabled
- # i would really prefer to fix this at the Makefile.am level, but can't
- # get the software to autoreconf as distributed - too many missing files
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0.21-thrssl.patch" || die
-
-
- if use tcpd; then
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0.14-r1-tcpd-vars-fix.diff" || die
- fi
-
- # security fix from http://lists.mysql.com/internals/15185
- # gentoo bug #60744
- #EPATCH_OPTS="-p1 -d ${S}" epatch ${MY_PATCH_SOURCE}/${PN}-4.0-mysqlhotcopy-security.patch
- # Already included upstream in 4.0.21
-
- for d in ${S} ${S}/innobase; do
- cd ${d}
- # WARNING, plain autoconf breaks it!
- #autoconf
- # must use this instead
- WANT_AUTOCONF=2.59 autoreconf --force
- # Fix the evil "libtool.m4 and ltmain.sh have a version mismatch!"
- libtoolize --copy --force
- # Saving this for a rainy day, in case we need it again
- #WANT_AUTOMAKE=1.7 automake
- gnuconfig_update
- done
-
- # upstream bug http://bugs.mysql.com/bug.php?id=7971
- # names conflict with stuff in 2.6.10 kernel headers
- echo ${S}/client/mysqltest.c ${S}/extra/replace.c | xargs -n1 \
- sed -i \
- -e "s/set_bit/my__set_bit/g" \
- -e "s/clear_bit/my__clear_bit/g" \
- || die "Failed to fix bitops"
-}
-
-src_compile() {
- local myconf
-
- #The following fix is due to a bug with bdb on sparc's. See:
- #http://www.geocrawler.com/mail/msg.php3?msg_id=4754814&list=8
- if use sparc || use alpha || use hppa || use mips
- then
- myconf="${myconf} --without-berkeley-db"
- else
- use berkdb \
- && myconf="${myconf} --with-berkeley-db=./bdb" \
- || myconf="${myconf} --without-berkeley-db"
- fi
-
- #readline pair reads backwards on purpose, DONT change it around, Ok?
- # this is because it refers to the building of a bundled readline
- # versus the system copy
- use readline && myconf="${myconf} --without-readline"
- use readline || myconf="${myconf} --with-readline"
-
- use static \
- && myconf="${myconf} --with-mysqld-ldflags=-all-static --disable-shared" \
- || myconf="${myconf} --enable-shared --enable-static"
-
- myconf="${myconf} `use_with tcpd libwrap`"
- myconf="${myconf} `use_with innodb`"
-
- use ssl \
- && myconf="${myconf} --with-vio --with-openssl" \
- || myconf="${myconf} --without-openssl"
-
- myconf="${myconf} `use_with debug`"
-
- #glibc-2.3.2_pre fix; bug #16496
- export CFLAGS="${CFLAGS} -DHAVE_ERRNO_AS_DEFINE=1"
-
- #bug fix for #15099, should make this api backward compatible
- export CFLAGS="${CFLAGS} -DUSE_OLD_FUNCTIONS"
-
- #the compiler flags are as per their "official" spec ;)
- #CFLAGS="${CFLAGS/-O?/} -O3" \
- CXXFLAGS="${CXXFLAGS} -felide-constructors -fno-exceptions -fno-rtti" \
- econf \
- --libexecdir=/usr/sbin \
- --sysconfdir=/etc/mysql \
- --localstatedir=/var/lib/mysql \
- --with-raid \
- --with-low-memory \
- --enable-assembler \
- --with-charset=latin1 \
- --enable-local-infile \
- --with-mysqld-user=mysql \
- --with-extra-charsets=all \
- --enable-thread-safe-client \
- --with-client-ldflags=-lstdc++ \
- --with-comment="Gentoo Linux ${PF}" \
- --with-unix-socket-path=/var/run/mysqld/mysqld.sock \
- --with-embedded-server \
- ${myconf} || die "bad ./configure"
-
- emake || die "compile problem"
-}
-
-src_install() {
- make install DESTDIR=${D} benchdir_root=/usr/share/mysql || die
-
- #move client libs, install a couple of missing headers
- mv ${D}/usr/$(get_libdir)/mysql/libmysqlclient*.so* ${D}/usr/$(get_libdir)
- dosym ../libmysqlclient.so /usr/$(get_libdir)/mysql/libmysqlclient.so
- dosym ../libmysqlclient_r.so /usr/$(get_libdir)/mysql/libmysqlclient_r.so
- insinto /usr/include/mysql ; doins include/{my_config.h,my_dir.h}
-
- #convenience links
- dosym /usr/bin/mysqlcheck /usr/bin/mysqlanalyze
- dosym /usr/bin/mysqlcheck /usr/bin/mysqlrepair
- dosym /usr/bin/mysqlcheck /usr/bin/mysqloptimize
-
- #various junk
- rm -f ${D}/usr/share/mysql/mysql.server
- rm -f ${D}/usr/share/mysql/binary-configure
- rm -f ${D}/usr/share/mysql/make_binary_distribution
- rm -f ${D}/usr/share/mysql/mysql-log-rotate
- rm -f ${D}/usr/share/mysql/{post,pre}install
- rm -f ${D}/usr/share/mysql/mi_test*
- rm -f ${D}/usr/share/mysql/*.spec # Redhat gunk
- rm -f ${D}/usr/share/mysql/*.plist # Apple gunk
- rm -f ${D}/usr/share/mysql/my-*.cnf # Put them elsewhere
-
- # All of these (ab)use Perl.
- if ! use perl; then
- rm -f ${D}/usr/bin/mysql_setpermission
- rm -rf ${D}/usr/share/mysql/sql-bench
- fi
-
- dohtml Docs/*.html
- rm -f Docs/*.html
- dodoc README COPYING Docs/manual.*
- docinto conf-samples
- dodoc support-files/my-*.cnf
-
- insinto /etc/mysql
- newins ${FILESDIR}/my.cnf-4.0.14-r1 my.cnf
- doins scripts/mysqlaccess.conf
- exeinto /etc/init.d
- newexe ${FILESDIR}/mysql-4.0.15.rc6 mysql
-
- insinto /etc/logrotate.d
- newins ${FILESDIR}/logrotate.mysql mysql
-}
-
-pkg_config() {
- mysql_get_datadir
-
- if [ ! -d ${ROOT}/${DATADIR}/mysql ] ; then
- einfo "Press ENTER to create the mysql database and set proper"
- einfo "permissions on it, or Control-C to abort now..."
- read
- ${ROOT}/usr/bin/mysql_install_db #>>/var/log/mysql/mysql.err 2>&1
- # changing ownership of newly created databases to mysql.mysql
- chown -R mysql:mysql ${ROOT}/${DATADIR}
- chmod 0750 ${ROOT}/${DATADIR}
- ewarn "For security reasons you should set your MySQL root"
- ewarn "password as soon as possible."
-
- else
- einfo "Hmm, it appears as though you already have the mysql"
- einfo "database in place. If you are having problems trying"
- einfo "to start mysqld, perhaps you need to manually run"
- einfo "/usr/bin/mysql_install_db and/or check your config"
- einfo "file(s) and/or database(s) and/or logfile(s)."
- fi
-}
-
-pkg_preinst() {
- enewgroup mysql 60 || die "problem adding group mysql"
- enewuser mysql 60 -1 /var/lib/mysql mysql || die "problem adding user mysql"
-}
-
-pkg_postinst() {
- mysql_get_datadir
-
- #empty dirs...
- [ -d "${ROOT}/${DATADIR}" ] || install -d -m0750 -o mysql -g mysql ${ROOT}/var/lib/mysql
- [ -d "${ROOT}/var/run/mysqld" ] || install -d -m0755 -o mysql -g mysql ${ROOT}/var/run/mysqld
- [ -d "${ROOT}/var/log/mysql" ] || install -d -m0755 -o mysql -g mysql ${ROOT}/var/log/mysql
-
- #secure the logfiles... does this bother anybody?
- touch ${ROOT}/var/log/mysql/mysql.{log,err}
- chown mysql:mysql ${ROOT}/var/log/mysql/mysql*
- chmod 0660 ${ROOT}/var/log/mysql/mysql*
- # secure some directories
- chmod 0750 ${ROOT}/var/log/mysql ${ROOT}/${DATADIR}
-
- #your friendly public service announcement...
- einfo
- einfo "You might want to run:"
- einfo "\"emerge --config =${PF}\""
- einfo "if this is a new install."
- einfo
-
- mysql_upgrade_warning
- use innodb || ewarn "InnoDB support is not selected to be compiled in."
-}
diff --git a/dev-db/mysql/mysql-4.0.22.ebuild b/dev-db/mysql/mysql-4.0.22.ebuild
deleted file mode 100644
index cca39defbc39..000000000000
--- a/dev-db/mysql/mysql-4.0.22.ebuild
+++ /dev/null
@@ -1,274 +0,0 @@
-# Copyright 1999-2005 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.0.22.ebuild,v 1.24 2005/10/17 13:49:25 vivo Exp $
-
-inherit eutils gnuconfig
-#to accomodate -laadeedah releases
-NEWP=${P}
-
-SVER=${PV%.*}
-#normal releases:
-SDIR=MySQL-${SVER}
-#for a pre-release:
-#SDIR=MySQL-${SVER}-Pre
-
-S=${WORKDIR}/${NEWP}
-
-DESCRIPTION="A fast, multi-threaded, multi-user SQL database server"
-HOMEPAGE="http://www.mysql.com/"
-SRC_URI="mirror://mysql/Downloads/${SDIR}/${NEWP}.tar.gz
- mirror://gentoo/mysql-extras-20050920.tar.bz2"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="alpha amd64 arm hppa ia64 mips ppc ppc64 s390 sparc x86"
-IUSE="static readline innodb berkdb tcpd ssl perl debug selinux"
-
-DEPEND="readline? ( >=sys-libs/readline-4.1 )
- bdb? ( sys-apps/ed )
- tcpd? ( >=sys-apps/tcp-wrappers-7.6-r6 )
- ssl? ( >=dev-libs/openssl-0.9.6d )
- perl? ( dev-lang/perl )
- >=sys-libs/zlib-1.2.3
- >=sys-apps/texinfo-4.7-r1
- sys-process/procps
- >=sys-apps/sed-4"
-PDEPEND="perl? ( dev-perl/DBI dev-perl/DBD-mysql )"
-RDEPEND="${DEPEND} selinux? ( sec-policy/selinux-mysql )"
-
-warning() {
- ewarn
- ewarn "If you're upgrading from MySQL-3.x to 4.0, or 4.0.x to 4.1.x, you"
- ewarn "must recompile the other packages on your system that link with"
- ewarn "libmysqlclient after the upgrade completes. To obtain such a list"
- ewarn "of packages for your system, you may use 'revdep-rebuild' from"
- ewarn "app-portage/gentoolkit."
- ewarn
- epause 5
-}
-
-pkg_setup() {
- use innodb || ewarn "InnoDB support is not selected to be compiled in."
- warning
-}
-
-src_unpack() {
- if use static && use ssl; then
- local msg="MySQL does not support building statically with SSL support"
- eerror "${msg}"
- die "${msg}"
- fi
- unpack ${A} || die
-
- local MY_PATCH_SOURCE="${WORKDIR}/mysql-extras"
-
- #zap startup script messages
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0.21-install-db-sh.diff || die
- #zap binary distribution stuff
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0.18-mysqld-safe-sh.diff || die
- #required for qmail-mysql
- EPATCH_OPTS="-p0 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0-nisam.h.diff || die
- #for correct hardcoded sysconf directory
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0-my-print-defaults.diff || die
- # NPTL support
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0.18-gentoo-nptl.diff || die
-
- # attempt to get libmysqlclient_r linked against ssl if USE="ssl" enabled
- # i would really prefer to fix this at the Makefile.am level, but can't
- # get the software to autoreconf as distributed - too many missing files
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0.21-thrssl.patch || die
-
- if use tcpd; then
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0.14-r1-tcpd-vars-fix.diff || die
- fi
-
- # security fix from http://lists.mysql.com/internals/15185
- # gentoo bug #60744
- #EPATCH_OPTS="-p1 -d ${S}" epatch ${MY_PATCH_SOURCE}/${PN}-4.0-mysqlhotcopy-security.patch
- # Already included upstream in 4.0.21
-
- cd ${S}
- autoconf
- # Saving this for a rainy day, in case we need it again
- #WANT_AUTOMAKE=1.7 automake
- gnuconfig_update
-
- # upstream bug http://bugs.mysql.com/bug.php?id=7971
- # names conflict with stuff in 2.6.10 kernel headers
- echo ${S}/client/mysqltest.c ${S}/extra/replace.c | xargs -n1 \
- sed -i \
- -e "s/set_bit/my__set_bit/g" \
- -e "s/clear_bit/my__clear_bit/g" \
- || die "Failed to fix bitops"
-}
-
-src_compile() {
- local myconf
-
- #The following fix is due to a bug with bdb on sparc's. See:
- #http://www.geocrawler.com/mail/msg.php3?msg_id=4754814&list=8
- if use sparc || use alpha || use hppa || use mips
- then
- myconf="${myconf} --without-berkeley-db"
- else
- use berkdb \
- && myconf="${myconf} --with-berkeley-db=./bdb" \
- || myconf="${myconf} --without-berkeley-db"
- fi
-
- #readline pair reads backwards on purpose, DONT change it around, Ok?
- # this is because it refers to the building of a bundled readline
- # versus the system copy
- use readline && myconf="${myconf} --without-readline"
- use readline || myconf="${myconf} --with-readline"
-
- use static \
- && myconf="${myconf} --with-mysqld-ldflags=-all-static --disable-shared" \
- || myconf="${myconf} --enable-shared --enable-static"
-
- myconf="${myconf} `use_with tcpd libwrap`"
- myconf="${myconf} `use_with innodb`"
-
- use ssl \
- && myconf="${myconf} --with-vio --with-openssl" \
- || myconf="${myconf} --without-openssl"
-
- myconf="${myconf} `use_with debug`"
-
- #glibc-2.3.2_pre fix; bug #16496
- export CFLAGS="${CFLAGS} -DHAVE_ERRNO_AS_DEFINE=1"
-
- #bug fix for #15099, should make this api backward compatible
- export CFLAGS="${CFLAGS} -DUSE_OLD_FUNCTIONS"
-
- #the compiler flags are as per their "official" spec ;)
- #CFLAGS="${CFLAGS/-O?/} -O3" \
- CXXFLAGS="${CXXFLAGS} -felide-constructors -fno-exceptions -fno-rtti" \
- econf \
- --libexecdir=/usr/sbin \
- --sysconfdir=/etc/mysql \
- --localstatedir=/var/lib/mysql \
- --with-raid \
- --with-low-memory \
- --enable-assembler \
- --with-charset=latin1 \
- --enable-local-infile \
- --with-mysqld-user=mysql \
- --with-extra-charsets=all \
- --enable-thread-safe-client \
- --with-client-ldflags=-lstdc++ \
- --with-comment="Gentoo Linux ${PF}" \
- --with-unix-socket-path=/var/run/mysqld/mysqld.sock \
- --with-embedded-server \
- ${myconf} || die "bad ./configure"
-
- emake || die "compile problem"
-}
-
-src_install() {
- make install DESTDIR=${D} benchdir_root=/usr/share/mysql || die
-
- #move client libs, install a couple of missing headers
- mv ${D}/usr/$(get_libdir)/mysql/libmysqlclient*.so* ${D}/usr/$(get_libdir)
- dosym ../libmysqlclient.so /usr/$(get_libdir)/mysql/libmysqlclient.so
- dosym ../libmysqlclient_r.so /usr/$(get_libdir)/mysql/libmysqlclient_r.so
- insinto /usr/include/mysql ; doins include/{my_config.h,my_dir.h}
-
- #convenience links
- dosym /usr/bin/mysqlcheck /usr/bin/mysqlanalyze
- dosym /usr/bin/mysqlcheck /usr/bin/mysqlrepair
- dosym /usr/bin/mysqlcheck /usr/bin/mysqloptimize
-
- #various junk
- rm -f ${D}/usr/share/mysql/mysql.server
- rm -f ${D}/usr/share/mysql/binary-configure
- rm -f ${D}/usr/share/mysql/make_binary_distribution
- rm -f ${D}/usr/share/mysql/mysql-log-rotate
- rm -f ${D}/usr/share/mysql/{post,pre}install
- rm -f ${D}/usr/share/mysql/mi_test*
- rm -f ${D}/usr/share/mysql/*.spec # Redhat gunk
- rm -f ${D}/usr/share/mysql/*.plist # Apple gunk
- rm -f ${D}/usr/share/mysql/my-*.cnf # Put them elsewhere
-
- # All of these (ab)use Perl.
- if ! use perl; then
- rm -f ${D}/usr/bin/mysql_setpermission
- rm -rf ${D}/usr/share/mysql/sql-bench
- fi
-
- dohtml Docs/*.html
- rm -f Docs/*.html
- dodoc README COPYING Docs/manual.*
- docinto conf-samples
- dodoc support-files/my-*.cnf
-
- insinto /etc/mysql
- newins ${FILESDIR}/my.cnf-4.0.14-r1 my.cnf
- doins scripts/mysqlaccess.conf
- exeinto /etc/init.d
- newexe ${FILESDIR}/mysql-4.0.15.rc6 mysql
-}
-
-pkg_config() {
- if [ ! -d ${ROOT}/var/lib/mysql/mysql ] ; then
- einfo "Press ENTER to create the mysql database and set proper"
- einfo "permissions on it, or Control-C to abort now..."
- read
- ${ROOT}/usr/bin/mysql_install_db #>>/var/log/mysql/mysql.err 2>&1
- # changing ownership of newly created databases to mysql.mysql
- local DATADIR=""
- if [ -f '/etc/mysql/my.cnf' ] ; then
- #DATADIR=`grep ^datadir /etc/mysql/my.cnf | sed -e 's/.*= //'`
- #DATADIR=`/usr/sbin/mysqld --help |grep '^datadir' | awk '{print $2}'`
- #DATADIR=`my_print_defaults mysqld | grep -- '^--datadir' | tail -n1 | sed -e 's|^--datadir=||'`
- DATADIR=`my_print_defaults mysqld | sed -ne '/datadir/s|^--datadir=||p' | tail -n1`
- fi
- if [ -z "${DATADIR}" ]; then
- DATADIR="/var/lib/mysql/"
- fi
- chown -R mysql:mysql ${DATADIR}
- chmod 0750 ${DATADIR}
- else
- einfo "Hmm, it appears as though you already have the mysql"
- einfo "database in place. If you are having problems trying"
- einfo "to start mysqld, perhaps you need to manually run"
- einfo "/usr/bin/mysql_install_db and/or check your config"
- einfo "file(s) and/or database(s) and/or logfile(s)."
- fi
-}
-
-pkg_preinst() {
- enewgroup mysql 60 || die "problem adding group mysql"
- enewuser mysql 60 -1 /var/lib/mysql mysql || die "problem adding user mysql"
-}
-
-pkg_postinst() {
- #empty dirs...
- install -d -m0750 -o mysql -g mysql ${ROOT}/var/lib/mysql
- install -d -m0755 -o mysql -g mysql ${ROOT}/var/run/mysqld
- install -d -m0755 -o mysql -g mysql ${ROOT}/var/log/mysql
-
- #secure the logfiles... does this bother anybody?
- touch ${ROOT}/var/log/mysql/mysql.{log,err}
- chown mysql:mysql ${ROOT}/var/log/mysql/mysql*
- chmod 0660 ${ROOT}/var/log/mysql/mysql*
- # secure some directories
- chmod 0750 ${ROOT}/var/log/mysql ${ROOT}/var/lib/mysql
-
- #your friendly public service announcement...
- einfo
- einfo "You might want to run:"
- einfo "\"emerge --config =${PF}\""
- einfo "if this is a new install."
- einfo
-
- warning
- use innodb || ewarn "InnoDB support is not selected to be compiled in."
-}
diff --git a/dev-db/mysql/mysql-4.0.24.ebuild b/dev-db/mysql/mysql-4.0.24.ebuild
deleted file mode 100644
index 55fcc06fec75..000000000000
--- a/dev-db/mysql/mysql-4.0.24.ebuild
+++ /dev/null
@@ -1,305 +0,0 @@
-# Copyright 1999-2005 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.0.24.ebuild,v 1.20 2005/10/17 13:49:25 vivo Exp $
-
-inherit eutils gnuconfig
-#to accomodate -laadeedah releases
-NEWP=${P}
-
-SVER=${PV%.*}
-#normal releases:
-SDIR=MySQL-${SVER}
-#for a pre-release:
-#SDIR=MySQL-${SVER}-Pre
-
-S=${WORKDIR}/${NEWP}
-
-DESCRIPTION="A fast, multi-threaded, multi-user SQL database server"
-HOMEPAGE="http://www.mysql.com/"
-SRC_URI="mirror://mysql/Downloads/${SDIR}/${NEWP}.tar.gz
- mirror://gentoo/mysql-extras-20050920.tar.bz2"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="alpha amd64 arm hppa ia64 mips ppc ppc64 s390 sparc x86"
-IUSE="static readline innodb berkdb tcpd ssl perl debug selinux"
-
-DEPEND="readline? ( >=sys-libs/readline-4.1 )
- bdb? ( sys-apps/ed )
- tcpd? ( >=sys-apps/tcp-wrappers-7.6-r6 )
- ssl? ( >=dev-libs/openssl-0.9.6d )
- perl? ( dev-lang/perl )
- >=sys-libs/zlib-1.2.3
- >=sys-apps/texinfo-4.7-r1
- sys-process/procps
- >=sys-apps/sed-4"
-PDEPEND="perl? ( dev-perl/DBI dev-perl/DBD-mysql )"
-RDEPEND="${DEPEND} selinux? ( sec-policy/selinux-mysql )"
-
-mysql_upgrade_warning() {
- ewarn
- ewarn "If you're upgrading from MySQL-3.x to 4.0, or 4.0.x to 4.1.x, you"
- ewarn "must recompile the other packages on your system that link with"
- ewarn "libmysqlclient after the upgrade completes. To obtain such a list"
- ewarn "of packages for your system, you may use 'revdep-rebuild' from"
- ewarn "app-portage/gentoolkit."
- ewarn
- epause 5
-}
-
-
-mysql_get_datadir() {
- DATADIR=""
- if [ -f '/etc/mysql/my.cnf' ] ; then
- #DATADIR=`grep ^datadir /etc/mysql/my.cnf | sed -e 's/.*= //'`
- #DATADIR=`/usr/sbin/mysqld --help |grep '^datadir' | awk '{print $2}'`
- #DATADIR=`my_print_defaults mysqld | grep -- '^--datadir' | tail -n1 | sed -e 's|^--datadir=||'`
- DATADIR=`my_print_defaults mysqld | sed -ne '/datadir/s|^--datadir=||p' | tail -n1`
- fi
- if [ -z "${DATADIR}" ]; then
- DATADIR="/var/lib/mysql/"
- einfo "Using default DATADIR"
- fi
- einfo "MySQL DATADIR is ${DATADIR}"
- export DATADIR
-}
-
-pkg_setup() {
- use innodb || ewarn "InnoDB support is not selected to be compiled in."
- mysql_upgrade_warning
- mysql_get_datadir
-}
-
-src_unpack() {
- if use static && use ssl; then
- local msg="MySQL does not support building statically with SSL support"
- eerror "${msg}"
- die "${msg}"
- fi
- unpack ${A} || die
-
- local MY_PATCH_SOURCE="${WORKDIR}/mysql-extras"
-
- #zap startup script messages
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0.23-install-db-sh.diff" || die
- #zap binary distribution stuff
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0.18-mysqld-safe-sh.diff" || die
- #required for qmail-mysql
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0-nisam.h.diff" || die
- #for correct hardcoded sysconf directory
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0-my-print-defaults.diff" || die
- # NPTL support
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0.18-gentoo-nptl.diff" || die
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0.18-gentoo-nptl.diff || die
- # Merged upstream as of 4.0.24
- # bad tmpfiles in mysqlaccess, see bug 77805
- #EPATCH_OPTS="-p1 -d ${S}" \
- #epatch ${MY_PATCH_SOURCE}/mysql-accesstmp.patch
-
- EPATCH_OPTS="-p1 -d ${S}" \
- epatch ${MY_PATCH_SOURCE}/${PN}-4.0.24-manual.texi.patch || die
-
- # attempt to get libmysqlclient_r linked against ssl if USE="ssl" enabled
- # i would really prefer to fix this at the Makefile.am level, but can't
- # get the software to autoreconf as distributed - too many missing files
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0.21-thrssl.patch" || die
-
-
- if use tcpd; then
- epatch "${MY_PATCH_SOURCE}/${PN}-4.0.14-r1-tcpd-vars-fix.diff" || die
- fi
-
- for d in ${S} ${S}/innobase; do
- cd ${d}
- # WARNING, plain autoconf breaks it!
- #autoconf
- # must use this instead
- WANT_AUTOCONF=2.59 autoreconf --force
- # Fix the evil "libtool.m4 and ltmain.sh have a version mismatch!"
- libtoolize --copy --force
- # Saving this for a rainy day, in case we need it again
- #WANT_AUTOMAKE=1.7 automake
- gnuconfig_update
- done
-
- # upstream bug http://bugs.mysql.com/bug.php?id=7971
- # names conflict with stuff in 2.6.10 kernel headers
- echo ${S}/client/mysqltest.c ${S}/extra/replace.c | xargs -n1 \
- sed -i \
- -e "s/\<set_bit\>/my__set_bit/g" \
- -e "s/\<clear_bit\>/my__clear_bit/g" \
- || die "Failed to fix bitops"
-}
-
-src_compile() {
- local myconf
-
- #The following fix is due to a bug with bdb on sparc's. See:
- #http://www.geocrawler.com/mail/msg.php3?msg_id=4754814&list=8
- if use sparc || use alpha || use hppa || use mips
- then
- myconf="${myconf} --without-berkeley-db"
- else
- use berkdb \
- && myconf="${myconf} --with-berkeley-db=./bdb" \
- || myconf="${myconf} --without-berkeley-db"
- fi
-
- #readline pair reads backwards on purpose, DONT change it around, Ok?
- # this is because it refers to the building of a bundled readline
- # versus the system copy
- use readline && myconf="${myconf} --without-readline"
- use readline || myconf="${myconf} --with-readline"
-
- use static \
- && myconf="${myconf} --with-mysqld-ldflags=-all-static --disable-shared" \
- || myconf="${myconf} --enable-shared --enable-static"
-
- myconf="${myconf} `use_with tcpd libwrap`"
- myconf="${myconf} `use_with innodb`"
-
- use ssl \
- && myconf="${myconf} --with-vio --with-openssl" \
- || myconf="${myconf} --without-openssl"
-
- myconf="${myconf} `use_with debug`"
-
- #glibc-2.3.2_pre fix; bug #16496
- export CFLAGS="${CFLAGS} -DHAVE_ERRNO_AS_DEFINE=1"
-
- #bug fix for #15099, should make this api backward compatible
- export CFLAGS="${CFLAGS} -DUSE_OLD_FUNCTIONS"
-
- #the compiler flags are as per their "official" spec ;)
- #CFLAGS="${CFLAGS/-O?/} -O3" \
- CXXFLAGS="${CXXFLAGS} -felide-constructors -fno-exceptions -fno-rtti" \
- econf \
- --libexecdir=/usr/sbin \
- --sysconfdir=/etc/mysql \
- --localstatedir=/var/lib/mysql \
- --with-raid \
- --with-low-memory \
- --enable-assembler \
- --with-charset=latin1 \
- --enable-local-infile \
- --with-mysqld-user=mysql \
- --with-extra-charsets=all \
- --enable-thread-safe-client \
- --with-client-ldflags=-lstdc++ \
- --with-comment="Gentoo Linux ${PF}" \
- --with-unix-socket-path=/var/run/mysqld/mysqld.sock \
- --with-embedded-server \
- ${myconf} || die "bad ./configure"
-
- emake || die "compile problem"
-}
-
-src_install() {
- make install DESTDIR=${D} benchdir_root=/usr/share/mysql || die
-
- #move client libs, install a couple of missing headers
- mv ${D}/usr/$(get_libdir)/mysql/libmysqlclient*.so* ${D}/usr/$(get_libdir)
- dosym ../libmysqlclient.so /usr/$(get_libdir)/mysql/libmysqlclient.so
- dosym ../libmysqlclient_r.so /usr/$(get_libdir)/mysql/libmysqlclient_r.so
- insinto /usr/include/mysql ; doins include/{my_config.h,my_dir.h}
-
- #convenience links
- dosym /usr/bin/mysqlcheck /usr/bin/mysqlanalyze
- dosym /usr/bin/mysqlcheck /usr/bin/mysqlrepair
- dosym /usr/bin/mysqlcheck /usr/bin/mysqloptimize
-
- #various junk
- rm -f ${D}/usr/share/mysql/mysql.server
- rm -f ${D}/usr/share/mysql/binary-configure
- rm -f ${D}/usr/share/mysql/make_binary_distribution
- rm -f ${D}/usr/share/mysql/mysql-log-rotate
- rm -f ${D}/usr/share/mysql/{post,pre}install
- rm -f ${D}/usr/share/mysql/mi_test*
- rm -f ${D}/usr/share/mysql/*.spec # Redhat gunk
- rm -f ${D}/usr/share/mysql/*.plist # Apple gunk
- rm -f ${D}/usr/share/mysql/my-*.cnf # Put them elsewhere
-
- # All of these (ab)use Perl.
- if ! use perl; then
- rm -f ${D}/usr/bin/mysql_setpermission
- rm -rf ${D}/usr/share/mysql/sql-bench
- fi
-
- dohtml Docs/*.html
- rm -f Docs/*.html
- dodoc README COPYING Docs/manual.*
- docinto conf-samples
- dodoc support-files/my-*.cnf
-
- insinto /etc/mysql
- newins ${FILESDIR}/my.cnf-4.0.14-r1 my.cnf
- doins scripts/mysqlaccess.conf
- exeinto /etc/init.d
- newexe ${FILESDIR}/mysql-4.0.15.rc6 mysql
-
- insinto /etc/logrotate.d
- newins ${FILESDIR}/logrotate.mysql mysql
-}
-
-src_test() {
- cd ${S}
- echo ">>> Test phase [check]: ${CATEGORY}/${PF}"
- make check || die "make check failed"
- echo ">>> Test phase [test]: ${CATEGORY}/${PF}"
- addpredict /this-dir-does-not-exist/t9.MYI
- make test || die "make test failed"
-}
-
-pkg_config() {
- mysql_get_datadir
-
- if [ ! -d ${ROOT}/${DATADIR}/mysql ] ; then
- einfo "Press ENTER to create the mysql database and set proper"
- einfo "permissions on it, or Control-C to abort now..."
- read
- ${ROOT}/usr/bin/mysql_install_db #>>/var/log/mysql/mysql.err 2>&1
- # changing ownership of newly created databases to mysql.mysql
- chown -R mysql:mysql ${ROOT}/${DATADIR}
- chmod 0750 ${ROOT}/${DATADIR}
- ewarn "For security reasons you should set your MySQL root"
- ewarn "password as soon as possible."
-
- else
- einfo "Hmm, it appears as though you already have the mysql"
- einfo "database in place. If you are having problems trying"
- einfo "to start mysqld, perhaps you need to manually run"
- einfo "/usr/bin/mysql_install_db and/or check your config"
- einfo "file(s) and/or database(s) and/or logfile(s)."
- fi
-}
-
-pkg_preinst() {
- enewgroup mysql 60 || die "problem adding group mysql"
- enewuser mysql 60 -1 /var/lib/mysql mysql || die "problem adding user mysql"
-}
-
-pkg_postinst() {
- mysql_get_datadir
-
- #empty dirs...
- [ -d "${ROOT}/${DATADIR}" ] || install -d -m0750 -o mysql -g mysql ${ROOT}/var/lib/mysql
- [ -d "${ROOT}/var/run/mysqld" ] || install -d -m0755 -o mysql -g mysql ${ROOT}/var/run/mysqld
- [ -d "${ROOT}/var/log/mysql" ] || install -d -m0755 -o mysql -g mysql ${ROOT}/var/log/mysql
-
- #secure the logfiles... does this bother anybody?
- touch ${ROOT}/var/log/mysql/mysql.{log,err}
- chown mysql:mysql ${ROOT}/var/log/mysql/mysql*
- chmod 0660 ${ROOT}/var/log/mysql/mysql*
- # secure some directories
- chmod 0750 ${ROOT}/var/log/mysql ${ROOT}/${DATADIR}
-
- #your friendly public service announcement...
- einfo
- einfo "You might want to run:"
- einfo "\"emerge --config =${PF}\""
- einfo "if this is a new install."
- einfo
-
- mysql_upgrade_warning
- use innodb || ewarn "InnoDB support is not selected to be compiled in."
-}
diff --git a/dev-db/mysql/mysql-4.0.25-r2.ebuild b/dev-db/mysql/mysql-4.0.25-r2.ebuild
index 919b6b7edc0e..aba88505e6a3 100644
--- a/dev-db/mysql/mysql-4.0.25-r2.ebuild
+++ b/dev-db/mysql/mysql-4.0.25-r2.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.0.25-r2.ebuild,v 1.22 2005/10/21 08:58:03 vivo Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.0.25-r2.ebuild,v 1.23 2005/10/22 14:29:44 vivo Exp $
inherit eutils gnuconfig flag-o-matic versionator
@@ -334,13 +334,14 @@ src_install() {
chown -R mysql:mysql "${D}/${DATADIR}"
fi
- diropts "-m0755"
- dodir "/var/log/mysql"
- touch ${D}/var/log/mysql/mysql.{log,err}
- chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
- keepdir "/var/log/mysql"
- chown -R mysql:mysql "${D}/var/log/mysql"
+ #diropts "-m0755"
+ #dodir "/var/log/mysql"
+ #touch ${D}/var/log/mysql/mysql.{log,err}
+ #chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
+ #keepdir "/var/log/mysql"
+ #chown -R mysql:mysql "${D}/var/log/mysql"
+ diropts "-m0755"
dodir "/var/run/mysqld"
keepdir "/var/run/mysqld"
@@ -459,3 +460,18 @@ pkg_config() {
einfo "done"
}
+
+pkg_postinst() {
+ # mind at FEATURES=collision-protect before to remove this
+ #empty dirs...
+ [ -d "${ROOT}/var/log/mysql" ] \
+ || install -d -m0755 -o mysql -g mysql ${ROOT}/var/log/mysql
+
+ #secure the logfiles... does this bother anybody?
+ touch ${ROOT}/var/log/mysql/mysql.{log,err}
+ chown mysql:mysql ${ROOT}/var/log/mysql/mysql*
+ chmod 0660 ${ROOT}/var/log/mysql/mysql*
+ # secure some directories
+ chmod 0750 ${ROOT}/var/log/mysql
+}
+
diff --git a/dev-db/mysql/mysql-4.0.26.ebuild b/dev-db/mysql/mysql-4.0.26.ebuild
index df138407ada7..e4ee326df451 100644
--- a/dev-db/mysql/mysql-4.0.26.ebuild
+++ b/dev-db/mysql/mysql-4.0.26.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.0.26.ebuild,v 1.11 2005/10/21 08:58:03 vivo Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.0.26.ebuild,v 1.12 2005/10/22 14:29:44 vivo Exp $
inherit eutils gnuconfig flag-o-matic versionator
@@ -363,13 +363,14 @@ src_install() {
chown -R mysql:mysql "${D}/${DATADIR}"
fi
- diropts "-m0755"
- dodir "/var/log/mysql"
- touch ${D}/var/log/mysql/mysql.{log,err}
- chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
- keepdir "/var/log/mysql"
- chown -R mysql:mysql "${D}/var/log/mysql"
+ #diropts "-m0755"
+ #dodir "/var/log/mysql"
+ #touch ${D}/var/log/mysql/mysql.{log,err}
+ #chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
+ #keepdir "/var/log/mysql"
+ #chown -R mysql:mysql "${D}/var/log/mysql"
+ diropts "-m0755"
dodir "/var/run/mysqld"
keepdir "/var/run/mysqld"
@@ -488,3 +489,18 @@ pkg_config() {
einfo "done"
}
+
+pkg_postinst() {
+ # mind at FEATURES=collision-protect before to remove this
+ #empty dirs...
+ [ -d "${ROOT}/var/log/mysql" ] \
+ || install -d -m0755 -o mysql -g mysql ${ROOT}/var/log/mysql
+
+ #secure the logfiles... does this bother anybody?
+ touch ${ROOT}/var/log/mysql/mysql.{log,err}
+ chown mysql:mysql ${ROOT}/var/log/mysql/mysql*
+ chmod 0660 ${ROOT}/var/log/mysql/mysql*
+ # secure some directories
+ chmod 0750 ${ROOT}/var/log/mysql
+}
+
diff --git a/dev-db/mysql/mysql-4.1.14.ebuild b/dev-db/mysql/mysql-4.1.14.ebuild
index 2acdaa8cc6a9..7924731bc84e 100644
--- a/dev-db/mysql/mysql-4.1.14.ebuild
+++ b/dev-db/mysql/mysql-4.1.14.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.1.14.ebuild,v 1.17 2005/10/21 08:58:03 vivo Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.1.14.ebuild,v 1.18 2005/10/22 14:29:44 vivo Exp $
inherit eutils gnuconfig flag-o-matic versionator
@@ -444,13 +444,14 @@ src_install() {
chown -R mysql:mysql "${D}/${DATADIR}"
fi
- diropts "-m0755"
- dodir "/var/log/mysql"
- touch ${D}/var/log/mysql/mysql.{log,err}
- chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
- keepdir "/var/log/mysql"
- chown -R mysql:mysql "${D}/var/log/mysql"
+ #diropts "-m0755"
+ #dodir "/var/log/mysql"
+ #touch ${D}/var/log/mysql/mysql.{log,err}
+ #chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
+ #keepdir "/var/log/mysql"
+ #chown -R mysql:mysql "${D}/var/log/mysql"
+ diropts "-m0755"
dodir "/var/run/mysqld"
keepdir "/var/run/mysqld"
@@ -594,3 +595,18 @@ pkg_config() {
rm "${sqltmp}"
einfo "done"
}
+
+pkg_postinst() {
+ # mind at FEATURES=collision-protect before to remove this
+ #empty dirs...
+ [ -d "${ROOT}/var/log/mysql" ] \
+ || install -d -m0755 -o mysql -g mysql ${ROOT}/var/log/mysql
+
+ #secure the logfiles... does this bother anybody?
+ touch ${ROOT}/var/log/mysql/mysql.{log,err}
+ chown mysql:mysql ${ROOT}/var/log/mysql/mysql*
+ chmod 0660 ${ROOT}/var/log/mysql/mysql*
+ # secure some directories
+ chmod 0750 ${ROOT}/var/log/mysql
+}
+
diff --git a/dev-db/mysql/mysql-5.0.12_beta.ebuild b/dev-db/mysql/mysql-4.1.15.ebuild
index 6c6580e71e46..42b581c3a37a 100644
--- a/dev-db/mysql/mysql-5.0.12_beta.ebuild
+++ b/dev-db/mysql/mysql-4.1.15.ebuild
@@ -1,12 +1,12 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-5.0.12_beta.ebuild,v 1.15 2005/10/21 08:58:03 vivo Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-4.1.15.ebuild,v 1.1 2005/10/22 14:29:44 vivo Exp $
-inherit eutils flag-o-matic versionator
+inherit eutils gnuconfig flag-o-matic versionator
SVER=${PV%.*}
NEWP="${PN}-${PV}"
-NEWP="${NEWP/_beta/-beta}"
+#NEWP="${NEWP/_beta/-beta}"
# shorten the path because the socket path length must be shorter than 107 chars
@@ -20,13 +20,13 @@ SRC_URI="mirror://mysql/Downloads/MySQL-${SVER}/${NEWP}.tar.gz
LICENSE="GPL-2"
SLOT="0"
-#KEYWORDS="~x86 ~amd64 ~sparc ~ia64 ~ppc ~ppc64"
-KEYWORDS="~x86 ~amd64"
-IUSE="big-tables berkdb debug doc minimal perl readline selinux ssl static"
+KEYWORDS="~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE="big-tables berkdb debug doc minimal perl readline selinux ssl static tcpd"
RESTRICT="primaryuri"
DEPEND="readline? ( >=sys-libs/readline-4.1 )
bdb? ( sys-apps/ed )
+ tcpd? ( >=sys-apps/tcp-wrappers-7.6-r6 )
ssl? ( >=dev-libs/openssl-0.9.6d )
perl? ( dev-lang/perl )
userland_GNU? ( sys-process/procps )
@@ -38,7 +38,12 @@ RDEPEND="${DEPEND} selinux? ( sec-policy/selinux-mysql )"
PDEPEND="perl? ( >=dev-perl/DBD-mysql-2.9004 )"
if version_is_at_least "4.1.3" ; then
- IUSE="${IUSE} cluster utf8 geometry extraengine"
+ # 2005-09-29
+ # geometry has been removed due to repeated compile problems _without_ it.
+ # From now on it will be *always* enabled
+ # if you need to compile *without it* take a look at
+ # http://lists.mysql.com/internals/29559
+ IUSE="${IUSE} cluster utf8 extraengine"
fi
mysql_upgrade_error() {
@@ -47,11 +52,13 @@ mysql_upgrade_error() {
ewarn "Some gentoo documentation on how to do it:"
ewarn "http://www.gentoo.org/doc/en/mysql-upgrading.xml"
ewarn "Also on the MySQL website:"
- ewarn "http://dev.mysql.com/doc/refman/5.0/en/upgrading-from-4-1.html"
+ ewarn "http://dev.mysql.com/doc/refman/4.1/en/upgrading-from-4-0.html"
ewarn ""
ewarn "You can also choose to preview some new MySQL 4.1 behaviour"
ewarn "adding a section \"[mysqld-4.0]\" followed by the word \"new\""
ewarn "into /etc/mysql/my.cnf (you need a recent MySQL version)"
+ ewarn ""
+
}
mysql_upgrade_warning() {
@@ -103,7 +110,7 @@ pkg_setup() {
if [[ -z $MYSQL_STRAIGHT_UPGRADE ]] ; then
mysql_get_datadir
- local curversion="dev-db/${PN}-${PV%.*}"
+ local local curversion="dev-db/${PN}-${PV%.*}"
local oldversion="$(best_version dev-db/mysql)"
oldversion=${oldversion%.*}
@@ -138,10 +145,9 @@ src_unpack() {
if version_is_at_least "4.1.3" \
&& useq cluster \
- || useq geometry \
|| useq extraengine \
&& useq minimal ; then
- die "USEs cluster, geometry, extraengine conflicts with \"minimal\""
+ die "USEs cluster, extraengine conflicts with \"minimal\""
fi
unpack ${A} || die
@@ -153,30 +159,22 @@ src_unpack() {
local MY_PATCH_SOURCE="${WORKDIR}/mysql-extras"
- epatch "${MY_PATCH_SOURCE}/010_all_my-print-defaults-r2.patch" || die
- epatch "${MY_PATCH_SOURCE}/035_x86_asm-pic-fixes-r7.patch" || die
- epatch "${MY_PATCH_SOURCE}/703_all_test-rpl_rotate_logs.patch" || die
- epatch "${MY_PATCH_SOURCE}/705_all_view_geometry.patch" || die
-
- find . -name Makefile -o -name Makefile.in -o -name configure -exec rm {} \;
- aclocal && autoheader \
- || die "failed reconfigure step 01"
- libtoolize --automake --force \
- || die "failed reconfigure step 02"
- automake --force --add-missing && autoconf \
- || die "failed reconfigure step 03"
-
- if version_is_at_least "5.1_alpha" ; then
- pushd storage/innobase || die "failed chdir"
- else
- pushd innobase || die "failed chroot"
- fi
- aclocal && autoheader && autoconf && automake
- popd
-
- pushd bdb/dist && sh s_all \
- || die "failed bdb reconfigure"
- popd
+ epatch ${MY_PATCH_SOURCE}/010_all_my-print-defaults-r0.patch || die
+ epatch ${MY_PATCH_SOURCE}/030_all_thrssl-r1.patch || die
+ epatch ${MY_PATCH_SOURCE}/040_all_tcpd-vars-fix.patch || die
+
+ for d in ${S} ${S}/innobase; do
+ cd ${d}
+ # WARNING, plain autoconf breaks it!
+ #autoconf
+ # must use this instead
+ WANT_AUTOCONF="2.59" autoreconf --force
+ # Fix the evil "libtool.m4 and ltmain.sh have a version mismatch!"
+ libtoolize --copy --force
+ # Saving this for a rainy day, in case we need it again
+ #WANT_AUTOMAKE=1.7 automake
+ gnuconfig_update
+ done
# Temporary workaround for bug in test suite, a correct solution
# should work inside the include files to enable/disable the tests
@@ -200,7 +198,6 @@ src_unpack() {
&> /dev/null
done
fi
-
}
src_compile() {
@@ -220,8 +217,7 @@ src_compile() {
myconf="${myconf} --enable-shared --enable-static"
fi
- #myconf="${myconf} `use_with tcpd libwrap`"
- myconf="${myconf} --without-libwrap"
+ myconf="${myconf} `use_with tcpd libwrap`"
if useq ssl ; then
# --with-vio is not needed anymore, it's on by default and
@@ -256,11 +252,17 @@ src_compile() {
# these are things we exclude from a minimal build
# note that the server actually does get built and installed
# but we then delete it before packaging.
- local minimal_exclude_list="server embedded-server extra-tools innodb raid"
+ local minimal_exclude_list="server embedded-server extra-tools innodb"
if ! useq minimal; then
for i in ${minimal_exclude_list}; do
myconf="${myconf} --with-${i}"
done
+ if useq static ; then
+ myconf="${myconf} --without-raid"
+ ewarn "disabling raid support, has problem with static"
+ else
+ myconf="${myconf} --with-raid"
+ fi
if ! version_is_at_least "5.0_alpha" ; then
if version_is_at_least "4.1_alpha" && useq utf8; then
@@ -288,7 +290,8 @@ src_compile() {
fi
if version_is_at_least "4.1.3" ; then
- myconf="${myconf} $(use_with geometry)"
+ myconf="${myconf} -with-geometry"
+ #myconf="${myconf} $(use_with geometry)"
myconf="${myconf} $(use_with cluster ndbcluster)"
fi
@@ -331,7 +334,6 @@ src_compile() {
export CXXFLAGS="${CXXFLAGS} -felide-constructors -fno-exceptions -fno-rtti"
version_is_at_least "5.0_alpha" \
&& export CXXFLAGS="${CXXFLAGS} -fno-implicit-templates"
-
econf \
--libexecdir=/usr/sbin \
--sysconfdir=/etc/mysql \
@@ -360,9 +362,9 @@ src_test() {
local retstatus
addpredict /this-dir-does-not-exist/t9.MYI
- version_is_at_least "5.0.6_beta" \
- && make test-force \
- || make test
+ version_is_at_least "5.0.13_rc" \
+ && make test-force-pl \
+ || make test-pl
retstatus=$?
# to be sure ;)
@@ -444,13 +446,14 @@ src_install() {
chown -R mysql:mysql "${D}/${DATADIR}"
fi
- diropts "-m0755"
- dodir "/var/log/mysql"
- touch ${D}/var/log/mysql/mysql.{log,err}
- chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
- keepdir "/var/log/mysql"
- chown -R mysql:mysql "${D}/var/log/mysql"
+ #diropts "-m0755"
+ #dodir "/var/log/mysql"
+ #touch ${D}/var/log/mysql/mysql.{log,err}
+ #chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
+ #keepdir "/var/log/mysql"
+ #chown -R mysql:mysql "${D}/var/log/mysql"
+ diropts "-m0755"
dodir "/var/run/mysqld"
keepdir "/var/run/mysqld"
@@ -594,3 +597,18 @@ pkg_config() {
rm "${sqltmp}"
einfo "done"
}
+
+pkg_postinst() {
+ # mind at FEATURES=collision-protect before to remove this
+ #empty dirs...
+ [ -d "${ROOT}/var/log/mysql" ] \
+ || install -d -m0755 -o mysql -g mysql ${ROOT}/var/log/mysql
+
+ #secure the logfiles... does this bother anybody?
+ touch ${ROOT}/var/log/mysql/mysql.{log,err}
+ chown mysql:mysql ${ROOT}/var/log/mysql/mysql*
+ chmod 0660 ${ROOT}/var/log/mysql/mysql*
+ # secure some directories
+ chmod 0750 ${ROOT}/var/log/mysql
+}
+
diff --git a/dev-db/mysql/mysql-5.0.13_rc.ebuild b/dev-db/mysql/mysql-5.0.13_rc.ebuild
index f0358e2fd2a0..5a8ac7ce4c05 100644
--- a/dev-db/mysql/mysql-5.0.13_rc.ebuild
+++ b/dev-db/mysql/mysql-5.0.13_rc.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-5.0.13_rc.ebuild,v 1.5 2005/10/21 08:58:03 vivo Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/mysql-5.0.13_rc.ebuild,v 1.6 2005/10/22 14:29:44 vivo Exp $
inherit eutils flag-o-matic versionator
@@ -22,7 +22,7 @@ SRC_URI="mirror://mysql/Downloads/MySQL-${SVER}/${NEWP}.tar.gz
LICENSE="GPL-2"
SLOT="0"
#KEYWORDS="~x86 ~amd64 ~sparc ~ia64 ~ppc ~ppc64"
-KEYWORDS="~x86 ~amd64"
+KEYWORDS="~amd64 ~ppc ~x86"
IUSE="big-tables berkdb debug doc minimal perl readline selinux ssl static"
RESTRICT="primaryuri"
@@ -448,13 +448,14 @@ src_install() {
chown -R mysql:mysql "${D}/${DATADIR}"
fi
- diropts "-m0755"
- dodir "/var/log/mysql"
- touch ${D}/var/log/mysql/mysql.{log,err}
- chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
- keepdir "/var/log/mysql"
- chown -R mysql:mysql "${D}/var/log/mysql"
+ #diropts "-m0755"
+ #dodir "/var/log/mysql"
+ #touch ${D}/var/log/mysql/mysql.{log,err}
+ #chmod 0660 ${D}/var/log/mysql/mysql.{log,err}
+ #keepdir "/var/log/mysql"
+ #chown -R mysql:mysql "${D}/var/log/mysql"
+ diropts "-m0755"
dodir "/var/run/mysqld"
keepdir "/var/run/mysqld"
@@ -598,3 +599,18 @@ pkg_config() {
rm "${sqltmp}"
einfo "done"
}
+
+pkg_postinst() {
+ # mind at FEATURES=collision-protect before to remove this
+ #empty dirs...
+ [ -d "${ROOT}/var/log/mysql" ] \
+ || install -d -m0755 -o mysql -g mysql ${ROOT}/var/log/mysql
+
+ #secure the logfiles... does this bother anybody?
+ touch ${ROOT}/var/log/mysql/mysql.{log,err}
+ chown mysql:mysql ${ROOT}/var/log/mysql/mysql*
+ chmod 0660 ${ROOT}/var/log/mysql/mysql*
+ # secure some directories
+ chmod 0750 ${ROOT}/var/log/mysql
+}
+