wok-next view mariadb/receipt @ rev 21569

updated cryptopp (5.6.5 -> 8.2.0)
author Hans-G?nter Theisgen
date Mon Jun 22 16:34:56 2020 +0100 (2020-06-22)
parents bfe1f37ff436
children
line source
1 # SliTaz package receipt v2.
3 PACKAGE="mariadb"
4 VERSION="10.3.10"
5 CATEGORY="office"
6 SHORT_DESC="SQL database system"
7 MAINTAINER="devel@slitaz.org"
8 LICENSE="GPL2"
9 WEB_SITE="https://mariadb.org/"
11 TARBALL="$PACKAGE-$VERSION.tar.gz"
12 WGET_URL="https://downloads.mariadb.org/interstitial/mariadb-$VERSION/source/$TARBALL"
14 BUILD_DEPENDS="cmake libaio-dev valgrind-dev zlib-dev openssl-dev ncurses-dev \
15 pcre-dev curl-dev libxml2-dev xz-dev boost-dev git"
17 SPLIT="\
18 $PACKAGE-test $PACKAGE-common $PACKAGE-client $PACKAGE-bench \
19 $PACKAGE-backup $PACKAGE-embedded $PACKAGE-mytop $PACKAGE-server-utils \
20 $PACKAGE-plugin-rocksdb $PACKAGE-dev $PACKAGE"
22 case $ARCH in
23 i?86) SPLIT="${SPLIT/$PACKAGE-plugin-rocksdb/}";;
24 esac
26 compile_rules() {
27 case $ARCH in
28 i?86) ARCH_ARGS='-DPLUGIN_ROCKSDB=NO';;
29 *) ARCH_ARGS='-DPLUGIN_ROCKSDB=YES';;
30 esac
32 cmake \
33 -DBUILD_CONFIG=mysql_release \
34 -DCMAKE_INSTALL_PREFIX=/usr \
35 -DSYSCONFDIR=/etc \
36 -DSYSCONF2DIR=/etc/my.cnf.d \
37 -DMYSQL_DATADIR=/var/lib/mysql \
38 -DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock \
39 -DDEFAULT_CHARSET=utf8 \
40 -DDEFAULT_COLLATION=utf8_general_ci \
41 -DENABLED_LOCAL_INFILE=ON \
42 -DINSTALL_INFODIR=share/info \
43 -DINSTALL_MANDIR=share/man \
44 -DINSTALL_PLUGINDIR=lib/mariadb/plugin \
45 -DINSTALL_SCRIPTDIR=bin \
46 -DINSTALL_INCLUDEDIR=include/mysql \
47 -DINSTALL_DOCREADMEDIR=share/doc/mariadb \
48 -DINSTALL_SUPPORTFILESDIR=share/mariadb \
49 -DINSTALL_MYSQLSHAREDIR=share/mariadb \
50 -DINSTALL_DOCDIR=share/doc/mariadb \
51 -DTMPDIR=/var/tmp \
52 -DCONNECT_WITH_MYSQL=ON \
53 -DCONNECT_WITH_LIBXML2=system \
54 -DCONNECT_WITH_ODBC=NO \
55 -DCONNECT_WITH_JDBC=NO \
56 -DPLUGIN_ARCHIVE=YES \
57 -DPLUGIN_ARIA=YES \
58 -DPLUGIN_BLACKHOLE=YES \
59 -DPLUGIN_CASSANDRA=NO \
60 -DPLUGIN_CSV=YES \
61 -DPLUGIN_MYISAM=YES \
62 -DPLUGIN_MROONGA=NO \
63 -DPLUGIN_OQGRAPH=NO \
64 -DPLUGIN_PARTITION=YES \
65 -DPLUGIN_SPHINX=NO \
66 -DPLUGIN_TOKUDB=NO \
67 -DPLUGIN_AUTH_PAM=NO \
68 -DPLUGIN_AUTH_GSSAPI=NO \
69 -DPLUGIN_AUTH_GSSAPI_CLIENT=OFF \
70 -DPLUGIN_CRACKLIB_PASSWORD_CHECK=NO \
71 -DWITH_ASAN=OFF \
72 -DWITH_EMBEDDED_SERVER=ON \
73 -DWITH_EXTRA_CHARSETS=complex \
74 -DWITH_INNODB_BZIP2=OFF \
75 -DWITH_INNODB_LZ4=OFF \
76 -DWITH_INNODB_LZMA=ON \
77 -DWITH_INNODB_LZO=OFF \
78 -DWITH_INNODB_SNAPPY=OFF \
79 -DWITH_ROCKSDB_BZIP2=OFF \
80 -DWITH_ROCKSDB_JEMALLOC=OFF \
81 -DWITH_ROCKSDB_LZ4=OFF \
82 -DWITH_ROCKSDB_ZSTD=OFF \
83 -DWITH_ROCKSDB_SNAPPY=OFF \
84 -DWITH_JEMALLOC=NO \
85 -DWITH_LIBARCHIVE=system \
86 -DWITH_LIBNUMA=NO \
87 -DWITH_LIBWRAP=OFF \
88 -DWITH_LIBWSEP=OFF \
89 -DWITH_MARIABACKUP=ON \
90 -DWITH_PCRE=system \
91 -DWITH_READLINE=ON \
92 -DWITH_SYSTEMD=no \
93 -DWITH_SSL=system \
94 -DWITH_VALGRIND=OFF \
95 -DWITH_ZLIB=system \
96 -DSKIP_TESTS=ON \
97 $ARCH_ARGS \
98 . &&
99 # print config options to log
100 cmake -L &&
101 make &&
102 make install || return 1
104 # fix Perl files permissions
105 find $install -type f -perm 664 -exec chmod 644 '{}' \;
106 find $install -type f -perm 775 -exec chmod 755 '{}' \;
107 find $install -type d -perm 775 -exec chmod 755 '{}' \;
109 # install conf files
110 install -Dm600 $stuff/my.cnf $install/etc/my.cnf
111 install -Dm600 $stuff/mariadb-server.cnf $install/etc/my.cnf.d/mariadb-server.cnf
113 mv $install/usr/sql-bench $install/usr/share
115 install -Dm755 $stuff/etc/init.d/mysql $install/etc/init.d/mysql
117 # move to bin and leave symlink instead
118 mv $install/usr/mysql-test/lib/My/SafeProcess/my_safe_process \
119 $install/usr/bin/
120 ln -s ../../../../bin/my_safe_process \
121 $install/usr/mysql-test/lib/My/SafeProcess/my_safe_process
122 }
124 genpkg_rules() {
125 case $PACKAGE in
126 *-test)
127 copy bin/mysql_client_test bin/my_safe_process \
128 bin/mysqltest bin/mysqltest_embedded mysql-test/
129 CAT="development|test suite"
130 DEPENDS=""
131 ;;
132 *-common)
133 copy charsets/ errmsg.sys
134 CAT="office|common files for both server and client"
135 DEPENDS=" "
136 ;;
137 *-client)
138 copy bin/myisam_ftdump bin/mysql bin/mysql_find_rows \
139 bin/mysql_fix_extensions bin/mysql_waitpid bin/mysqlaccess \
140 bin/mysqladmin bin/mysqlcheck bin/mysqldump bin/mysqldumpslow \
141 bin/mysqlimport bin/mysqlshow
142 DEPENDS="mariadb-common"
143 CAT="office|client"
144 ;;
145 *-bench)
146 copy sql-bench/
147 DEPENDS=""
148 CAT="office|benchmark scripts and data"
149 ;;
150 *-backup)
151 copy bin/mariabackup bin/mbstream
152 CAT="office|mariabackup tool for physical online backups"
153 DEPENDS=" "
154 ;;
155 *-embedded)
156 copy libmariadbd.so* libmysqld.so
157 CAT="office|embeddable library"
158 DEPENDS="mariadb-common"
159 ;;
160 *-mytop)
161 copy bin/mytop
162 DEPENDS="perl perl-dbi perl-dbd-mysql perl-getopt-long perl-socket \
163 perl-term-readkey"
164 ;;
165 *-server-utils)
166 copy bin/mysql_convert_table_format bin/mysql_setpermission \
167 bin/mysqld_multi bin/mysqlhotcopy bin/mysql_upgrade bin/perror \
168 bin/mysqld_safe_helper
169 CAT="office|non-essential server utilities"
170 DEPENDS=""
171 ;;
172 *-plugin-rocksdb)
173 copy ha_rocksdb.so
174 CAT="RocksDB (MyRocks) plugin"
175 ;;
176 *-dev)
177 copy @dev @rm
178 CAT="office|CLI tool for monitoring MariaDB performance"
179 DEPENDS=""
180 ;;
181 mariadb)
182 copy @std @rm
183 TAZPANEL_DAEMON="man|edit::/etc/mysql/my.cnf|options|web::$WEB_SITE"
184 PROVIDE="mysql"
185 CONFIG_FILES="/etc/my.cnf"
186 DATABASE_FILES="/var/lib/mysql"
187 DEPENDS="mariadb-common zlib slitaz-base-files"
188 esac
189 }
191 post_install_mariadb() {
192 local user
193 local group
195 user=mysql
196 group=mysql
198 if ! grep -q $user "$1/etc/passwd"; then
199 chroot "$1/" addgroup -S $group
200 chroot "$1/" adduser -s /bin/false -S -D -H -G $group $user
201 fi
203 [ -s "$quiet" ] || cat <<EOF
205 .------------------------------------------------.
206 | To start mariadb server you can run: |
207 | |
208 | /etc/init.d/mariadb start |
209 | |
210 | or add mariadb to RUN_DAEMONS in /etc/rcS.conf |
211 '------------------------------------------------'
212 EOF
213 }
215 post_remove_mariadb() {
216 chroot "$1/" deluser mysql
217 }