|
|
@ -2,7 +2,7 @@ |
|
|
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|
|
|
# |
|
|
|
# Filename: package/.../mysql/mysql.conf |
|
|
|
# Copyright (C) 2007 - 2011 The OpenSDE Project |
|
|
|
# Copyright (C) 2007 - 2012 The OpenSDE Project |
|
|
|
# Copyright (C) 2004 - 2006 The T2 SDE Project |
|
|
|
# Copyright (C) 1998 - 2003 Clifford Wolf |
|
|
|
# |
|
|
@ -14,64 +14,75 @@ |
|
|
|
# GNU General Public License can be found in the file COPYING. |
|
|
|
# --- SDE-COPYRIGHT-NOTE-END --- |
|
|
|
|
|
|
|
# Select a predefined installation layout to avoid the installation |
|
|
|
# of strange '$prefix/data' which is used when using the default |
|
|
|
# STANDALONE layout. |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_LAYOUT=DEB" |
|
|
|
makeinstopt= |
|
|
|
|
|
|
|
# tweaking install directories |
|
|
|
# tweaking install directories and stuff |
|
|
|
var_append cmakeopt ' ' "-DBUILD_CONFIG=mysql_release" |
|
|
|
var_append cmakeopt ' ' "-DFEATURE_SET='community'" |
|
|
|
var_append cmakeopt ' ' "-DCMAKE_INSTALL_PREFIX=/" |
|
|
|
var_append cmakeopt ' ' "-DCMAKE_BUILD_TYPE=Release" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_INCLUDEDIR=$includedir/$pkg" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_MYSQLSHAREDIR=$datadir/$pkg" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_SUPPORTFILESDIR=$datadir/$pkg" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_MYSQLTESTDIR=$datadir/$pkg/test" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_PLUGINDIR=$libdir/$pkg/plugin" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_LIBDIR=$libdir" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_SCRIPTDIR=$bindir" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_SQLBENCHDIR=$datadir/$pkg" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_BINDIR=$bindir" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_SBINDIR=$sbindir" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_MANDIR=$mandir" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_INFODIR=$infodir" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_DOCDIR=$docdir" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_DOCREADMEDIR=$docdir" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_MYSQLDATADIR=$localstatedir" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_INFODIR=$datadir/$pkg/docs" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_DOCDIR=$datadir/$pkg/docs" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_DOCREADMEDIR=$datadir/$pkg" |
|
|
|
var_append cmakeopt ' ' "-DINSTALL_MYSQLDATADIR=$localstatedir/lib/$pkg" |
|
|
|
var_append cmakeopt ' ' "-DMYSQL_DATADIR=$localstatedir/lib/$pkg" |
|
|
|
var_append cmakeopt ' ' "-DMYSQL_UNIX_ADDR=$localstatedir/lib/$pkg/mysql.sock" |
|
|
|
var_append cmakeopt ' ' "-DWITH_EXTRA_CHARSETS=complex" |
|
|
|
var_append cmakeopt ' ' "-DWITH_INNOBASE_STORAGE_ENGINE=1" |
|
|
|
var_append cmakeopt ' ' "-DWITH_PARTITION_STORAGE_ENGINE=1" |
|
|
|
var_append cmakeopt ' ' "-DWITHOUT_EXAMPLE_STORAGE_ENGINE=1" |
|
|
|
var_append cmakeopt ' ' "-DWITHOUT_ARCHIVE_STORAGE_ENGINE=1" |
|
|
|
var_append cmakeopt ' ' "-DWITHOUT_BLACKHOLE_STORAGE_ENGINE=1" |
|
|
|
var_append cmakeopt ' ' "-DWITHOUT_FEDERATED_STORAGE_ENGINE=1" |
|
|
|
var_append cmakeopt ' ' "-DWITH_DEBUG=OFF" |
|
|
|
|
|
|
|
# Configure the source with the same build options used by Oracle to produce |
|
|
|
# binary distributions for official MySQL releases. |
|
|
|
var_insert cmakeopt ' ' "-DBUILD_CONFIG=mysql_release" |
|
|
|
|
|
|
|
# using community feature set |
|
|
|
# alternative sets: xsmall, small, classic, large, xlarge |
|
|
|
var_insert cmakeopt ' ' "-DFEATURE_SET='community'" |
|
|
|
# using UTF8 |
|
|
|
var_append cmakeopt ' ' "-DDEFAULT_CHARSET=utf8" |
|
|
|
var_append cmakeopt ' ' "-DDEFAULT_COLLATION=utf8_general_ci" |
|
|
|
|
|
|
|
# build the libmysqld embedded server library |
|
|
|
var_append cmakeopt ' ' "-DWITH_EMBEDDED_SERVER=ON" |
|
|
|
|
|
|
|
# wether to use or not the bundles stuff in mysql |
|
|
|
for x in openssl:SSL zlib:ZLIB; do |
|
|
|
if ! pkginstalled -f "${x%:*}"; then |
|
|
|
echo_status "Could not detect ${x%:*} package (using bundled ${x%:*}" |
|
|
|
var_append cmakeopt ' ' "-DWITH_${x#*:}=bundled" |
|
|
|
else |
|
|
|
var_append cmakeopt ' ' "-DWITH_${x#*:}=system" |
|
|
|
fi |
|
|
|
done |
|
|
|
|
|
|
|
# whether to use the readline library bundled with mysql |
|
|
|
if ! pkginstalled -f readline; then |
|
|
|
echo_status "Could not detect readline package (using bundled readline)" |
|
|
|
var_append cmakeopt ' ' "-DWITH_READLINE=ON" |
|
|
|
fi |
|
|
|
|
|
|
|
# SSL support |
|
|
|
if ! pkginstalled -f openssl; then |
|
|
|
echo_status "Could not detect openssl package (using bundled openssl)" |
|
|
|
var_append cmakeopt ' ' "-DWITH_SSL=bundled" |
|
|
|
else |
|
|
|
var_append cmakeopt ' ' "-DWITH_SSL=system" |
|
|
|
fi |
|
|
|
|
|
|
|
# zlib compression support |
|
|
|
if ! pkginstalled -f zlib; then |
|
|
|
echo_status "Could not detect zlib package (using bundled zlib)" |
|
|
|
var_append cmakeopt ' ' "-DWITH_ZLIB=bundled" |
|
|
|
else |
|
|
|
var_append cmakeopt ' ' "-DWITH_ZLIB=system" |
|
|
|
fi |
|
|
|
|
|
|
|
if [ "$SDECFG_PKG_MYSQL_CLIENTONLY" = "1" ]; then |
|
|
|
var_append extraconfopt ' ' "--without-server" |
|
|
|
fi |
|
|
|
|
|
|
|
#hook_add postmake 5 "sed 's/\(.*MYSQL\)/#\1/' $root/$prefix/support-files/my-medium.cnf \ |
|
|
|
# > $root$sysconfdir/my.cnf" |
|
|
|
|
|
|
|
|
|
|
|
make_install() { |
|
|
|
SEGMENTS="Client Server IniFiles Embedded ManPages SharedLibraries Development Documentation Info Readme Server_Scripts" |
|
|
|
# We left out the following :"DataFiles SqlBench SupportFiles Test Unspecified" |
|
|
|
for segment in $SEGMENTS; do |
|
|
|
cmake -DCMAKE_INSTALL_COMPONENT=$segment -P cmake_install.cmake |
|
|
|
done |
|
|
|
|
|
|
|
unset SEGMENTS |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
hook_add postmake 9 'make_install' |