Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
0c2545c2
Commit
0c2545c2
authored
Apr 19, 2013
by
Rich Prohaska
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
release and debug build scripts for mysql
parent
1b5fb9d4
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
88 additions
and
4 deletions
+88
-4
scripts/make.mysql.bash
scripts/make.mysql.bash
+4
-4
scripts/make.mysql.debug.env.bash
scripts/make.mysql.debug.env.bash
+84
-0
No files found.
scripts/make.mysql.bash
View file @
0c2545c2
...
@@ -208,11 +208,11 @@ function generate_cmake_cmd() {
...
@@ -208,11 +208,11 @@ function generate_cmake_cmd() {
echo
-n
cmake ..
$extra_flags
-DBUILD_CONFIG
=
mysql_release
-DCMAKE_BUILD_TYPE
=
$cmake_build_type
echo
-n
cmake ..
$extra_flags
-DBUILD_CONFIG
=
mysql_release
-DCMAKE_BUILD_TYPE
=
$cmake_build_type
if
[
$system
=
linux
]
;
then
if
[
$system
=
linux
]
;
then
echo
-n
" "
\
echo
-n
" "
\
-D
CMAKE_EXE_LINKER_FLAGS
=
\"
-Wl
,--whole-archive
\$
TOKUFRACTALTREE/lib/libjemalloc.a
-Wl
,-no-whole-archive
\"
-D
TOKU_JEMALLOC_LIBRARY
=
\"
-Wl
,--whole-archive
\$
TOKUFRACTALTREE/lib/libjemalloc.a
-Wl
,-no-whole-archive
\"
elif
[
$system
=
darwin
]
;
then
elif
[
$system
=
darwin
]
;
then
echo
-n
" "
\
echo
-n
" "
\
-DWITH_SAFEMALLOC
=
OFF
-DWITH_SSL
=
system
\
-DWITH_SAFEMALLOC
=
OFF
-DWITH_SSL
=
system
\
-D
CMAKE_EXE_LINKER_FLAGS
=
\"
-Wl
,-force_load
-Wl
,
\$
TOKUFRACTALTREE/lib/libjemalloc.a
\"
-D
TOKU_JEMALLOC_LIBRARY
=
\"
-Wl
,-force_load
-Wl
,
\$
TOKUFRACTALTREE/lib/libjemalloc.a
\"
else
else
exit
1
exit
1
fi
fi
...
@@ -367,7 +367,7 @@ function generate_build_from_src() {
...
@@ -367,7 +367,7 @@ function generate_build_from_src() {
echo
'sed -i -e"s/README/& %{src_dir}\/README-TOKUDB/" SPECS/$specfile'
echo
'sed -i -e"s/README/& %{src_dir}\/README-TOKUDB/" SPECS/$specfile'
# add jemalloc to the linker flags
# add jemalloc to the linker flags
echo
'sed -i -e"s/^\(.*-DMYSQL_SERVER_SUFFIX=.*\)$/& -D
CMAKE_EXE_LINKER_FLAGS
=\"-Wl,--whole-archive \$\{TOKUFRACTALTREE\}\/lib\/libjemalloc.a -Wl,-no-whole-archive\"/" SPECS/$specfile'
echo
'sed -i -e"s/^\(.*-DMYSQL_SERVER_SUFFIX=.*\)$/& -D
TOKU_JEMALLOC_LIBRARY
=\"-Wl,--whole-archive \$\{TOKUFRACTALTREE\}\/lib\/libjemalloc.a -Wl,-no-whole-archive\"/" SPECS/$specfile'
# add the hot backup lib to the server package file list
# add the hot backup lib to the server package file list
echo
'sed -i -e"s/%{_datadir}\/mysql\/$/&\n%attr(755, root, root) %{_libdir}\/libHotBackup*.so/" SPECS/$specfile'
echo
'sed -i -e"s/%{_datadir}\/mysql\/$/&\n%attr(755, root, root) %{_libdir}\/libHotBackup*.so/" SPECS/$specfile'
...
@@ -463,7 +463,7 @@ function build_mysql_src() {
...
@@ -463,7 +463,7 @@ function build_mysql_src() {
# add README-TOKUDB
# add README-TOKUDB
if
[
!
-f
$mysqlsrc
/README-TOKUDB
]
;
then
if
[
!
-f
$mysqlsrc
/README-TOKUDB
]
;
then
cp
ft-
engine
/README-TOKUDB
$mysqlsrc
cp
ft-
index
/README-TOKUDB
$mysqlsrc
fi
fi
sed
-i
-e
's/FILES README DESTINATION/FILES README README-TOKUDB DESTINATION/'
$mysqlsrc
/CMakeLists.txt
sed
-i
-e
's/FILES README DESTINATION/FILES README README-TOKUDB DESTINATION/'
$mysqlsrc
/CMakeLists.txt
...
...
scripts/make.mysql.debug.env.bash
0 → 100755
View file @
0c2545c2
#!/usr/bin/env bash
function
usage
()
{
echo
"generate a script that builds a debug mysql from subversion"
}
shopt
-s
compat31 2>/dev/null
while
[
$#
-ne
0
]
;
do
arg
=
$1
;
shift
if
[[
$arg
=
~
--
(
.
*
)=(
.
*
)
]]
;
then
eval
${
BASH_REMATCH
[1]
}
=
${
BASH_REMATCH
[2]
}
;
else
usage
;
exit
1
;
fi
done
echo
'# setup environment variables'
echo
builddir
=
\$
PWD/mysql-build
echo
installdir
=
\$
PWD/mysql
echo mkdir
\$
builddir
\$
installdir
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo export
TOKUFRACTALTREE
=
\$
builddir/ft-index/install.debug
echo export
TOKUFRACTALTREE_LIBNAME
=
tokudb
echo export
TOKUPORTABILITY_LIBNAME
=
tokuportability
echo export
TOKUDB_VERSION
=
0
echo
'# checkout the fractal tree'
echo cd
\$
builddir
echo
git clone git@github.com:Tokutek/jemalloc
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
git clone git@github.com:Tokutek/ft-index
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
'# build the fractal tree'
echo cd
\$
builddir/ft-index
echo mkdir
build.debug
echo cd
build.debug
echo
CC
=
gcc47
CXX
=
g++47 cmake
-DCMAKE_INSTALL_PREFIX
=
\$
TOKUFRACTALTREE
-D
BUILD_TESTING
=
OFF
-D
CMAKE_BUILD_TYPE
=
Debug
-D
JEMALLOC_SOURCE_DIR
=
\$
builddir/jemalloc ..
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
make
install
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
'# checkout mysql'
echo cd
\$
builddir
echo
git clone git@github.com:Tokutek/mysql
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
'# checkout the community backup'
echo cd
\$
builddir
echo
git clone git@github.com:Tokutek/backup-community
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
'# checkout the tokudb handlerton'
echo cd
\$
builddir
echo
git clone git@github.com:Tokutek/ft-engine
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
'pushd mysql/storage; ln -s ../../ft-engine/storage/tokudb tokudb; popd'
echo
'pushd mysql; ln -s ../backup-community/backup toku_backup; popd'
echo
'# build in the mysql directory'
echo cd
\$
builddir/mysql
echo export
TOKUFRACTALTREE_LIBNAME
=
\$
{
TOKUFRACTALTREE_LIBNAME
}
_static
echo export
TOKUPORTABILITY_LIBNAME
=
\$
{
TOKUPORTABILITY_LIBNAME
}
_static
echo mkdir
build.debug
echo cd
build.debug
echo
CC
=
gcc47
CXX
=
g++47 cmake
-DCMAKE_BUILD_TYPE
=
Debug
-DCMAKE_INSTALL_PREFIX
=
\$
installdir ..
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
'# install'
echo
make
-j4
install
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
'# create a var directory so mysql does not complain'
echo
'cd $installdir'
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo mkdir
var
echo
'if [ $? != 0 ] ; then exit 1; fi'
echo
'# install the databases in msyql'
echo
scripts/mysql_install_db
--defaults-file
=
\$
HOME/my.cnf
echo
'if [ $? != 0 ] ; then exit 1; fi'
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment