You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
89 lines
3.6 KiB
89 lines
3.6 KiB
# --- SDE-COPYRIGHT-NOTE-BEGIN --- |
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|
# |
|
# Filename: package/.../mysql/mysql.conf |
|
# Copyright (C) 2007 - 2012 The OpenSDE Project |
|
# Copyright (C) 2004 - 2006 The T2 SDE Project |
|
# Copyright (C) 1998 - 2003 Clifford Wolf |
|
# |
|
# More information can be found in the files COPYING and README. |
|
# |
|
# This program is free software; you can redistribute it and/or modify |
|
# it under the terms of the GNU General Public License as published by |
|
# the Free Software Foundation; version 2 of the License. A copy of the |
|
# GNU General Public License can be found in the file COPYING. |
|
# --- SDE-COPYRIGHT-NOTE-END --- |
|
|
|
makeinstopt= |
|
|
|
# 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_PLUGINDIR=$libdir/$pkg/plugin" |
|
var_append cmakeopt ' ' "-DINSTALL_LIBDIR=$libdir" |
|
var_append cmakeopt ' ' "-DINSTALL_SCRIPTDIR=$bindir" |
|
var_append cmakeopt ' ' "-DINSTALL_BINDIR=$bindir" |
|
var_append cmakeopt ' ' "-DINSTALL_SBINDIR=$sbindir" |
|
var_append cmakeopt ' ' "-DINSTALL_MANDIR=$mandir" |
|
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 ' ' "-DINSTALL_SHAREDIR=$datadir" |
|
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" |
|
|
|
# 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 |
|
|
|
if [ "$SDECFG_PKG_MYSQL_CLIENTONLY" = "1" ]; then |
|
var_append extraconfopt ' ' "--without-server" |
|
fi |
|
|
|
|
|
|
|
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'
|
|
|