summaryrefslogtreecommitdiff
path: root/source/ap/mariadb
diff options
context:
space:
mode:
Diffstat (limited to 'source/ap/mariadb')
-rwxr-xr-xsource/ap/mariadb/mariadb.SlackBuild22
-rw-r--r--source/ap/mariadb/mirror.url2
-rw-r--r--source/ap/mariadb/rc.mysqld15
3 files changed, 31 insertions, 8 deletions
diff --git a/source/ap/mariadb/mariadb.SlackBuild b/source/ap/mariadb/mariadb.SlackBuild
index 7ba01959..976f8517 100755
--- a/source/ap/mariadb/mariadb.SlackBuild
+++ b/source/ap/mariadb/mariadb.SlackBuild
@@ -1,7 +1,7 @@
#!/bin/sh
-# Copyright 2008, 2009, 2010, 2012, 2013 Patrick J. Volkerding, Sebeka, Minnesota, USA
-# Copyright 2011, 2012, 2013 Heinz Wiesinger, Amsterdam, The Netherlands
+# Copyright 2008, 2009, 2010, 2012, 2013, 2014 Patrick J. Volkerding, Sebeka, Minnesota, USA
+# Copyright 2011, 2012, 2013, 2014 Heinz Wiesinger, Amsterdam, The Netherlands
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -30,8 +30,8 @@ PKGNAM=mariadb
VERSION=${VERSION:-$(echo ${PKGNAM}-*.tar.?z* | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
BUILD=${BUILD:-1}
-# To reduce the package size, the embedded server my be omitted. Currently
-# only amarok uses this. To build without embedded support, set this to NO.
+# To reduce the package size, the embedded server may be omitted. Currently
+# only amarok uses this. To build without embedded support, set this to NO.
EMBEDDED=${EMBEDDED:-YES}
# Add a description tag to the $BUILD. This is used by
@@ -48,7 +48,7 @@ KEEPTESTS=${KEEPTESTS:-NO}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
- i?86) export ARCH=i486 ;;
+ i?86) export ARCH=i586 ;;
arm*) export ARCH=arm ;;
# Unless $ARCH is already set, use uname -m for all other archs:
*) export ARCH=$( uname -m ) ;;
@@ -63,6 +63,9 @@ PKG=$TMP/package-${PKGNAM}
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
+ LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
LIBDIRSUFFIX=""
@@ -91,6 +94,10 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
+# Fix linking with libwrap
+sed -i "s|\${CMAKE_REQUIRED_LIBRARIES} wrap|\${CMAKE_REQUIRED_LIBRARIES} wrap nsl|" \
+ configure.cmake
+
mkdir build
cd build
cmake \
@@ -122,10 +129,13 @@ cmake \
-DWITH_READLINE=ON \
-DWITH_SSL=system \
-DWITH_ZLIB=system \
+ -DWITH_JEMALLOC=system \
-DUSE_ARIA_FOR_TMP_TABLES=ON \
- -DMANUFACTURER="Slackware" \
..
+# not building with libwrap. Do we still need tcp_wrappers support?
+# -DWITH_LIBWRAP=ON \
+
make $NUMJOBS || make || exit 1
make install DESTDIR=$PKG
diff --git a/source/ap/mariadb/mirror.url b/source/ap/mariadb/mirror.url
index 675f2336..17354301 100644
--- a/source/ap/mariadb/mirror.url
+++ b/source/ap/mariadb/mirror.url
@@ -1 +1 @@
-ftp://ftp.osuosl.org:/pub/mariadb/mariadb-5.5.32/kvm-tarbake-jaunty-x86/mariadb-5.5.32.tar.gz
+ftp://ftp.osuosl.org/pub/mariadb/
diff --git a/source/ap/mariadb/rc.mysqld b/source/ap/mariadb/rc.mysqld
index 7c42d03c..e7b7e85e 100644
--- a/source/ap/mariadb/rc.mysqld
+++ b/source/ap/mariadb/rc.mysqld
@@ -34,6 +34,9 @@ SKIP="--skip-networking"
# Uncomment the next line to use Oracle's InnoDB plugin instead of the included XtraDB
#INNODB="--ignore-builtin-innodb --plugin-load=innodb=ha_innodb.so"
+# Uncomment the next line to use TokuDB
+#TOKUDB="--plugin-load=ha_tokudb"
+
# Start mysqld:
mysqld_start() {
if [ -x /usr/bin/mysqld_safe ]; then
@@ -44,7 +47,13 @@ mysqld_start() {
rm -f /var/run/mysql/mysql.pid
fi
fi
- /usr/bin/mysqld_safe --datadir=/var/lib/mysql --pid-file=/var/run/mysql/mysql.pid $SKIP $INNODB &
+
+ if ! [ -z "$TOKUDB" ]; then
+ echo "never" > /sys/kernel/mm/transparent_hugepage/enabled
+ echo "never" > /sys/kernel/mm/transparent_hugepage/defrag
+ fi
+
+ /usr/bin/mysqld_safe --datadir=/var/lib/mysql --pid-file=/var/run/mysql/mysql.pid $SKIP $INNODB $TOKUDB &
fi
}
@@ -65,6 +74,10 @@ mysqld_stop() {
echo "WARNING: Gave up waiting for mysqld to exit!"
sleep 15
fi
+ if ! [ -z "$TOKUDB" ]; then
+ echo "always" > /sys/kernel/mm/transparent_hugepage/enabled
+ echo "always" > /sys/kernel/mm/transparent_hugepage/defrag
+ fi
fi
}