summaryrefslogtreecommitdiff
path: root/source/ap/mysql
diff options
context:
space:
mode:
authorPatrick J Volkerding <volkerdi@slackware.com>2010-05-19 08:58:23 +0000
committerEric Hameleers <alien@slackware.com>2018-05-31 22:43:05 +0200
commitb76270bf9e6dd375e495fec92140a79a79415d27 (patch)
tree3dbed78b2279bf9f14207a16dc634b90995cbd40 /source/ap/mysql
parent5a12e7c134274dba706667107d10d231517d3e05 (diff)
downloadcurrent-b76270bf9e6dd375e495fec92140a79a79415d27.tar.gz
Slackware 13.1slackware-13.1
Wed May 19 08:58:23 UTC 2010 Slackware 13.1 x86_64 stable is released! Lots of thanks are due -- see the RELEASE_NOTES and the rest of the ChangeLog for credits. The ISOs are on their way to replication, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. We are taking pre-orders now at store.slackware.com, and offering a discount if you sign up for a subscription. Consider picking up a copy to help support the project. Thanks again to the Slackware community for testing, contributing, and generally holding us to a high level of quality. :-) Enjoy!
Diffstat (limited to 'source/ap/mysql')
-rw-r--r--source/ap/mysql/mirror-url1
-rwxr-xr-xsource/ap/mysql/mysql-embedded.build26
-rwxr-xr-xsource/ap/mysql/mysql.SlackBuild85
3 files changed, 85 insertions, 27 deletions
diff --git a/source/ap/mysql/mirror-url b/source/ap/mysql/mirror-url
deleted file mode 100644
index 37be0283..00000000
--- a/source/ap/mysql/mirror-url
+++ /dev/null
@@ -1 +0,0 @@
-http://mysql.he.net/Downloads/MySQL-5.0/mysql-5.0.82.tar.gz
diff --git a/source/ap/mysql/mysql-embedded.build b/source/ap/mysql/mysql-embedded.build
index 9b06d386..2ac77f31 100755
--- a/source/ap/mysql/mysql-embedded.build
+++ b/source/ap/mysql/mysql-embedded.build
@@ -3,10 +3,19 @@
# by: David Cantrell <david@slackware.com>
# Currently maintained by: Patrick Volkerding <volkerdi@slackware.com>
-VERSION=5.0.84
-ARCH=${ARCH:-x86_64}
+VERSION=${VERSION:-$(echo mysql-*.tar.?z* | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
BUILD=${BUILD:-1}
+# Automatically determine the architecture we're building on:
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) export ARCH=i486 ;;
+ arm*) export ARCH=arm ;;
+ # Unless $ARCH is already set, use uname -m for all other archs:
+ *) export ARCH=$( uname -m ) ;;
+ esac
+fi
+
CWD=$(pwd)
TMP=${TMP:-/tmp}
PKG=$TMP/package-mysql
@@ -20,6 +29,9 @@ elif [ "$ARCH" = "s390" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
fi
rm -rf $PKG
@@ -29,15 +41,21 @@ rm -rf mysql-$VERSION
tar xvf $CWD/mysql-$VERSION.tar.?z* || exit 1
cd mysql-$VERSION
+if ls $CWD/*.diff.gz 1> /dev/null 2> /dev/null ; then
+ for patch in $CWD/*.diff.gz ; do
+ zcat $patch | patch -p1 --verbose || exit 1
+ done
+fi
+
CFLAGS="$SLKCFLAGS -fPIC" CXXFLAGS="$SLKCFLAGS -fPIC" \
./configure --prefix=/usr --libdir=/usr/lib${LIBDIRSUFFIX} \
--datadir=/usr/share --sysconfdir=/etc/mysql \
--libexecdir=/usr/sbin --localstatedir=/var/lib/mysql \
--without-docs --without-man --without-server \
- --with-embedded-server --without-innodb --without-bench \
+ --with-embedded-server --without-innodb \
--without-berkeley-db --without-row-based-replication \
--without-readline --disable-shared --with-charset=utf8 \
- --without-debug --with-pthread --without-openssl --without-query-cache \
+ --without-debug --with-pthread --without-ssl --without-query-cache \
--without-geometry --with-pic
make -j6 || make || exit 1
diff --git a/source/ap/mysql/mysql.SlackBuild b/source/ap/mysql/mysql.SlackBuild
index 16ba3efa..cf846ffe 100755
--- a/source/ap/mysql/mysql.SlackBuild
+++ b/source/ap/mysql/mysql.SlackBuild
@@ -1,6 +1,6 @@
#!/bin/sh
-# Copyright 2008, 2009 Patrick J. Volkerding, Sebeka, Minnesota, USA
+# Copyright 2008, 2009, 2010 Patrick J. Volkerding, Sebeka, Minnesota, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -25,11 +25,20 @@
# Currently maintained by: Patrick Volkerding <volkerdi@slackware.com>
-VERSION=5.0.84
-ARCH=${ARCH:-x86_64}
-NUMJOBS=${NUMJOBS:-" -j7 "}
-BUILD=${BUILD:-1}
+VERSION=${VERSION:-$(echo mysql-*.tar.?z* | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
+BUILD=${BUILD:-2}
+
+# Automatically determine the architecture we're building on:
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) export ARCH=i486 ;;
+ arm*) export ARCH=arm ;;
+ # Unless $ARCH is already set, use uname -m for all other archs:
+ *) export ARCH=$( uname -m ) ;;
+ esac
+fi
+NUMJOBS=${NUMJOBS:-" -j7 "}
CWD=$(pwd)
TMP=${TMP:-/tmp}
PKG=$TMP/package-mysql
@@ -43,6 +52,9 @@ elif [ "$ARCH" = "s390" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
fi
rm -rf $PKG
@@ -51,6 +63,13 @@ cd $TMP
rm -rf mysql-$VERSION
tar xvf $CWD/mysql-$VERSION.tar.?z* || exit 1
cd mysql-$VERSION
+
+if ls $CWD/*.diff.gz 1> /dev/null 2> /dev/null ; then
+ for patch in $CWD/*.diff.gz ; do
+ zcat $patch | patch -p1 --verbose || exit 1
+ done
+fi
+
chown -R root:root .
find . \
\( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
@@ -70,13 +89,13 @@ CXX=gcc \
--mandir=/usr/man \
--infodir=/usr/info \
--enable-assembler \
- --with-raid \
--without-debug \
--enable-thread-safe-client \
- --without-bench \
--with-extra-charsets=complex \
- --with-vio \
- --with-openssl \
+ --with-ssl=/usr \
+ --enable-largefile \
+ --with-innodb \
+ --with-readline \
--build=$ARCH-slackware-linux
#
# --without-readline
@@ -84,6 +103,22 @@ CXX=gcc \
make $NUMJOBS || make || exit 1
make install DESTDIR=$PKG
+# install additional headers needed for building external engine plugins
+for i in sql include regex; do
+ for j in $i/*.h; do
+ install -m 644 $j $PKG/usr/include/mysql/
+ done
+done
+
+mkdir -p $PKG/usr/include/mysql/atomic
+for i in include/atomic/*.h; do
+ install -m 644 $i $PKG/usr/include/mysql/atomic/
+done
+
+# The ./configure option to omit this has gone away, so we'll omit it
+# the old-fashioned way. It's all in the source tarball if you need it.
+rm -rf $PKG/usr/sql-bench
+
find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
@@ -94,13 +129,15 @@ cp support-files/my-{huge,large,medium,small}.cnf $PKG/etc
# Install docs
mkdir -p $PKG/usr/doc/mysql-$VERSION/Docs
cp -a \
- COPYING* MIRRORS README* \
+ COPYING* EXCEPTIONS* INSTALL-SOURCE README* \
$PKG/usr/doc/mysql-$VERSION
( cd Docs
+ # Seems most of the Docs/* are gone, but we'll leave the cp stuff
+ # in case it returns.
cp -a INSTALL-BINARY *.html *.txt Flags \
$PKG/usr/doc/mysql-$VERSION/Docs )
-# Too large to justify since the .html version is right there:
-rm $PKG/usr/doc/mysql-$VERSION/Docs/manual.txt
+## Too large to justify since the .html version is right there:
+#rm $PKG/usr/doc/mysql-$VERSION/Docs/manual.txt
find $PKG/usr/doc/mysql-$VERSION -type f -exec chmod 0644 {} \;
# This is the directory where databases are stored
@@ -127,20 +164,20 @@ zcat $CWD/doinst.sh.gz > $PKG/install/doinst.sh
cat $CWD/slack-desc > $PKG/install/slack-desc
# Add some handy library symlinks:
-if [ -r $PKG/usr/lib${LIBDIRSUFFIX}/mysql/libmysqlclient.so.15 ]; then
+if [ -r $PKG/usr/lib${LIBDIRSUFFIX}/mysql/libmysqlclient.so.16 ]; then
( cd $PKG/usr/lib${LIBDIRSUFFIX}
- rm -f libmysqlclient.so libmysqlclient.so.15
+ rm -f libmysqlclient.so libmysqlclient.so.16
ln -sf mysql/libmysqlclient.so .
- ln -sf mysql/libmysqlclient.so.15 .
+ ln -sf mysql/libmysqlclient.so.16 .
)
else
exit 1
fi
-if [ -r $PKG/usr/lib${LIBDIRSUFFIX}/mysql/libmysqlclient_r.so.15 ]; then
+if [ -r $PKG/usr/lib${LIBDIRSUFFIX}/mysql/libmysqlclient_r.so.16 ]; then
( cd $PKG/usr/lib${LIBDIRSUFFIX}
- rm -f libmysqlclient_r.so libmysqlclient_r.so.15
+ rm -f libmysqlclient_r.so libmysqlclient_r.so.16
ln -sf mysql/libmysqlclient_r.so .
- ln -sf mysql/libmysqlclient_r.so.15 .
+ ln -sf mysql/libmysqlclient_r.so.16 .
)
else
exit 1
@@ -172,11 +209,15 @@ if [ -d $PKG/usr/info ]; then
)
fi
+# If there's a ChangeLog, installing at least part of the recent history
+# is useful, but don't let it get totally out of control:
+if [ -r ChangeLog ]; then
+ DOCSDIR=$(echo $PKG/usr/doc/*-$VERSION)
+ cat ChangeLog | head -n 1000 > $DOCSDIR/ChangeLog
+ touch -r ChangeLog $DOCSDIR/ChangeLog
+fi
+
# Build package:
cd $PKG
/sbin/makepkg -l y -c n $TMP/mysql-$VERSION-$ARCH-$BUILD.txz
-if [ "$1" == "--cleanup" ]; then
- cd $TMP
- rm -rf mysql-$VERSION
-fi