46 lines
1.4 KiB
Plaintext
46 lines
1.4 KiB
Plaintext
# Description: SQL database server, drop-in replacement for MySQL
|
|
# URL: https://mariadb.org/
|
|
# Maintainer: Juergen Daubert, jue at crux dot nu
|
|
# Depends on: ncurses zlib openssl cmake libaio linux-pam
|
|
|
|
name=mariadb
|
|
version=10.5.5
|
|
release=1
|
|
source=(https://downloads.mariadb.com/MariaDB//$name-$version/source/$name-$version.tar.gz
|
|
mariadb.rc mariadb.pam
|
|
pre-install)
|
|
|
|
build() {
|
|
cmake -S $name-$version -B build \
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
-DINSTALL_LAYOUT=RPM \
|
|
-DINSTALL_LIBDIR=lib \
|
|
-DINSTALL_PLUGINDIR=lib/mysql/plugin \
|
|
-DINSTALL_PCDIR=/usr/lib/pkgconfig \
|
|
-DINSTALL_PAMDIR=/lib/security \
|
|
-DMYSQL_DATADIR=/var/lib/mysql \
|
|
-DMYSQL_UNIX_ADDR=/var/run/mysqld/mysqld.sock \
|
|
-DWITH_READLINE=ON \
|
|
-DWITH_ZLIB=system \
|
|
-DWITH_SSL=system \
|
|
-DWITH_EXTRA_CHARSETS=complex \
|
|
-DWITH_EMBEDDED_SERVER=ON \
|
|
-DWITH_UNIT_TESTS=OFF \
|
|
-DSKIP_TESTS=ON
|
|
|
|
cmake --build build
|
|
DESTDIR=$PKG cmake --install build
|
|
|
|
rm -r $PKG/etc/{init.d,logrotate.d}
|
|
rm -r $PKG/usr/share/{doc,groonga*,mysql-test}
|
|
rm $PKG/usr/sbin/rcmysql
|
|
rm $PKG/usr/share/man/man1/mysql-test-run.pl.1
|
|
find $PKG/usr/share/mysql/* -type d ! -name english ! -name charsets | xargs rm -rf {} \;
|
|
|
|
install -d -m 700 -o mysql -g mysql $PKG/var/{lib,log}/mysql
|
|
install -d -m 755 -o mysql -g mysql $PKG/var/run/mysqld
|
|
|
|
install -D -m 755 $SRC/mariadb.rc $PKG/etc/rc.d/mariadb
|
|
install -D -m 644 $SRC/mariadb.pam $PKG/etc/pam.d/mysql
|
|
}
|