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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
5758da14
Commit
5758da14
authored
Jan 24, 2003
by
Sinisa@sinisa.nasamreza.org
Browse files
Options
Browse Files
Download
Plain Diff
Merge sinisa@work.mysql.com:/home/bk/mysql
into sinisa.nasamreza.org:/mnt/work/mysql
parents
a90a0cc9
cd02b19f
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
65 additions
and
28 deletions
+65
-28
Build-tools/Do-compile
Build-tools/Do-compile
+60
-23
Makefile.am
Makefile.am
+1
-1
client/mysqladmin.c
client/mysqladmin.c
+2
-2
configure.in
configure.in
+1
-1
scripts/make_binary_distribution.sh
scripts/make_binary_distribution.sh
+1
-1
No files found.
Build-tools/Do-compile
View file @
5758da14
...
...
@@ -8,7 +8,7 @@ use Getopt::Long;
$opt_distribution
=
$opt_user
=
$opt_config_env
=
"";
$opt_dbd_options
=
$opt_perl_options
=
$opt_config_options
=
$opt_make_options
=
$opt_suffix
=
"";
$opt_tmp
=
$opt_version_suffix
=
"";
$opt_help
=
$opt_delete
=
$opt_debug
=
$opt_stage
=
$opt_no_test
=
$opt_no_perl
=
$opt_with_low_memory
=
$opt_fast_benchmark
=
$opt_static_client
=
$opt_static_server
=
$opt_static_perl
=
$opt_sur
=
$opt_with_small_disk
=
$opt_local_perl
=
$opt_tcpip
=
$opt_build_thread
=
$opt_use_old_distribution
=
$opt_enable_shared
=
$opt_no_crash_me
=
$opt_no_strip
=
0
;
$opt_help
=
$opt_delete
=
$opt_debug
=
$opt_stage
=
$opt_no_test
=
$opt_no_perl
=
$opt_with_low_memory
=
$opt_fast_benchmark
=
$opt_static_client
=
$opt_static_server
=
$opt_static_perl
=
$opt_sur
=
$opt_with_small_disk
=
$opt_local_perl
=
$opt_tcpip
=
$opt_build_thread
=
$opt_use_old_distribution
=
$opt_enable_shared
=
$opt_no_crash_me
=
$opt_no_strip
=
$opt_with_debug
=
$opt_no_benchmark
=
$opt_no_mysqltest
=
0
;
$opt_innodb
=
$opt_bdb
=
$opt_raid
=
$opt_libwrap
=
0
;
GetOptions
(
...
...
@@ -30,7 +30,9 @@ GetOptions(
"
no-crash-me
",
"
no-perl
",
"
no-strip
",
"
no-test|no-mysqltest
",
"
no-test
",
"
no-mysqltest
",
"
no-benchmark
",
"
perl-files=s
",
"
perl-options=s
",
"
raid
",
...
...
@@ -126,7 +128,7 @@ $ENV{'MYSQL_TCP_PORT'}= $mysql_tcp_port= 3334 + $opt_build_thread*2;
$ENV
{'
MYSQL_UNIX_PORT
'}
=
$mysql_unix_port
=
"
$opt_tmp
/mysql
$opt_suffix
.build
";
$ENV
{"
PERL5LIB
"}
=
"
$pwd
/
$host
/perl5:
$pwd
/
$host
/perl5/site_perl
";
$slave_port
=
$mysql_tcp_port
+
16
;
$m
anager_port
=
$mysql_tcp_port
+
1
;
$m
ysqladmin_args
=
"
--no-defaults -u root
"
;
if
(
$opt_stage
==
0
)
{
...
...
@@ -142,19 +144,26 @@ select STDOUT;
$|
=
1
;
info
("
Compiling MySQL
$opt_version_suffix
at
$host$opt_suffix
, stage:
$opt_stage
\n
");
log_timestamp
();
if
(
-
x
"
$host
/bin/mysqladmin
")
{
log_system
("
$host
/bin/mysqladmin
--no-defaults -u root
-S
$mysql_unix_port
-s shutdown
");
log_system
("
$host
/bin/mysqladmin
--no-defaults -u root
-P
$mysql_tcp_port
-h
$host
-s shutdown
");
log_system
("
$host
/bin/mysqladmin
--no-defaults -u root
-P
$slave_port
-h
$host
-s shutdown
");
log_system
("
$host
/bin/mysqladmin
--no-defaults -u root
-P 9306 -h
$host
-s shutdown
");
log_system
("
$host
/bin/mysqladmin
--no-defaults -u root
-P 9307 -h
$host
-s shutdown
");
log_system
("
$host
/bin/mysqladmin
$mysqladmin_args
-S
$mysql_unix_port
-s shutdown
");
log_system
("
$host
/bin/mysqladmin
$mysqladmin_args
-P
$mysql_tcp_port
-h
$host
-s shutdown
");
log_system
("
$host
/bin/mysqladmin
$mysqladmin_args
-P
$slave_port
-h
$host
-s shutdown
");
log_system
("
$host
/bin/mysqladmin
$mysqladmin_args
-P 9306 -h
$host
-s shutdown
");
log_system
("
$host
/bin/mysqladmin
$mysqladmin_args
-P 9307 -h
$host
-s shutdown
");
}
kill_all
("
mysqlmanager
");
#
# Kill all old processes that are in the build directories
# This is to find any old mysqld servers left from previous builds
kill_all
("
$pwd
/host/mysql
");
kill_all
("
$pwd
/host/test
");
if
(
$opt_stage
==
0
)
{
log_timestamp
();
print
"
$host
: Removing old distribution
\n
"
if
(
$opt_debug
);
if
(
!
$opt_use_old_distribution
)
{
...
...
@@ -203,6 +212,7 @@ safe_cd("$pwd/$host/$ver");
if
(
$opt_stage
<=
1
)
{
# Fix files if this is in another timezone than the build host
log_timestamp
();
unlink
("
config.cache
");
unlink
("
bdb/build_unix/config.cache
");
unlink
("
innobase/config.cache
");
...
...
@@ -246,6 +256,7 @@ if ($opt_stage <= 1)
if
(
$opt_stage
<=
2
)
{
my
(
$command
);
log_timestamp
();
unlink
(
$opt_distribution
)
if
(
$opt_delete
&&
!
$opt_use_old_distribution
);
$command
=
$make
;
$command
.=
"
$opt_make_options
"
if
(
defined
(
$opt_make_options
)
&&
$opt_make_options
ne
"");
...
...
@@ -258,6 +269,7 @@ if ($opt_stage <= 2)
if
(
$opt_stage
<=
3
)
{
my
$flags
=
"";
log_timestamp
();
log_system
("
rm -fr mysql-3* mysql-4*
$pwd
/
$host
/*.tar.gz
");
log_system
("
nm -n sql/mysqld | gzip -9 -v 2>&1 > sql/mysqld.sym.gz | cat
");
...
...
@@ -286,6 +298,7 @@ if (!defined($tar_file))
#
if
(
$opt_stage
<=
4
&&
!
$opt_no_test
)
{
log_timestamp
();
rm_all
(
<
$pwd
/$host/
test
/*>
);
safe_cd
("
$pwd
/
$host
/test
");
safe_system
("
gunzip <
$tar_file
|
$tar
xf -
");
...
...
@@ -294,13 +307,15 @@ if ($opt_stage <= 4 && !$opt_no_test)
$tar_file
=~
/(mysql[^\/]*)\.tar/
;
$ver
=
$1
;
$test_dir
=
"
$pwd
/
$host
/test/
$ver
";
$ENV
{"
LD_LIBRARY_PATH
"}
=
"
$test_dir
/lib:
"
.
$ENV
{"
LD_LIBRARY_PATH
"};
$ENV
{"
LD_LIBRARY_PATH
"}
=
("
$test_dir
/lib
"
.
(
defined
(
$ENV
{"
LD_LIBRARY_PATH
"})
?
"
:
"
.
$ENV
{"
LD_LIBRARY_PATH
"}
:
""));
#
# Run the test suite
#
if
(
$opt_stage
<=
5
&&
!
$opt_no_test
)
if
(
$opt_stage
<=
5
&&
!
$opt_no_test
&&
!
$opt_no_mysqltest
)
{
log_timestamp
();
system
("
mkdir
$bench_tmpdir
")
if
(
!
-
d
$bench_tmpdir
);
safe_cd
("
${test_dir}
/mysql-test
");
check_system
("
./mysql-test-run --tmpdir=
$bench_tmpdir
--master_port=
$mysql_tcp_port
--slave_port=
$slave_port
--sleep=10
",
"
tests were successful
");
...
...
@@ -309,11 +324,11 @@ if ($opt_stage <= 5 && !$opt_no_test)
#
# Start the server if we are going to run any of the benchmarks
#
if
(
!
$opt_no_test
)
if
(
!
$opt_no_test
&&
!
$opt_no_benchmark
)
{
my
$extra
;
safe_cd
(
$test_dir
);
log_system
("
./bin/mysqladmin
--no-defaults -u root
-S
$mysql_unix_port
-s shutdown
")
||
info
("
There was no mysqld running
\n
");
log_system
("
./bin/mysqladmin
$mysqladmin_args
-S
$mysql_unix_port
-s shutdown
")
||
info
("
There was no mysqld running
\n
");
sleep
(
2
);
log_system
("
rm -f ./data/mysql/*
");
check_system
("
scripts/mysql_install_db --no-defaults --skip-locking
","
https://order
");
...
...
@@ -333,8 +348,10 @@ if (!$opt_no_test)
#
# Compile and install the required Perl modules
#
if
(
$opt_stage
<=
7
&&
$opt_perl_files
&&
!
$opt_no_perl
&&
!
$opt_no_test
)
if
(
$opt_stage
<=
7
&&
$opt_perl_files
&&
!
$opt_no_perl
&&
!
$opt_no_test
&&
!
$opt_no_benchmark
)
{
log_timestamp
();
safe_cd
(
$test_dir
);
rm_all
("
perl
");
safe_system
("
mkdir perl
");
...
...
@@ -370,6 +387,7 @@ if ($opt_stage <= 7 && $opt_perl_files && !$opt_no_perl && !$opt_no_test)
#
if
(
$opt_stage
<=
8
&&
!
$opt_no_test
&&
!
$opt_no_crash_me
)
{
log_timestamp
();
safe_cd
("
$test_dir
/sql-bench
");
log_system
("
rm -f limits/mysql.cfg
");
safe_system
("
perl ./crash-me --force --batch-mode
$connect_option
");
...
...
@@ -378,8 +396,9 @@ if ($opt_stage <= 8 && !$opt_no_test && !$opt_no_crash_me)
#
# Run sql-bench Benchmarks
#
if
(
$opt_stage
<=
9
&&
!
$opt_no_test
)
if
(
$opt_stage
<=
9
&&
!
$opt_no_test
&&
!
$opt_no_benchmark
)
{
log_timestamp
();
safe_cd
("
$test_dir
/sql-bench
");
log_system
("
rm -f output/*
");
$tmp
=
$opt_fast_benchmark
?
"
--fast --user root --small-test
"
:
"";
...
...
@@ -399,7 +418,7 @@ if ($opt_stage <= 9 && !$opt_no_test)
rm_all
(
$bench_tmpdir
);
rm_all
("
$opt_tmp
")
if
(
$new_opt_tmp
);
log_system
("
$pwd
/
$host
/bin/mysqladmin
--no-defaults -S
$mysql_unix_port
-u roo
t shutdown
");
log_system
("
$pwd
/
$host
/bin/mysqladmin
$mysqladmin_args
-S
$mysql_unix_por
t
shutdown
");
print
LOG
"
ok
\n
";
close
LOG
;
print
"
$host
: ok
\n
";
...
...
@@ -410,7 +429,7 @@ exit 0;
sub
usage
{
print
<<EOF;
$0 version 1.
4
$0 version 1.
5
$0 takes the following options:
...
...
@@ -463,7 +482,13 @@ Do not run the "crash-me" test
Do not strip the binaries included in the binary distribution
--no-test
Do not run any tests
Do not run any tests.
--no-benchmark
Do not run the benchmark test (written in perl)
--no-mysqltest
Do not run the the mysql-test-run test (Same as 'make test')
--perl-files=list of files
Compile and install the given perl modules.
...
...
@@ -526,6 +551,7 @@ sub abort
my
(
$mail_header_file
);
print
LOG
"
\n
$message
\n
";
print
"
$host
:
$message
\n
"
if
(
$opt_debug
);
print
LOG
"
Aborting
\n
";
close
LOG
;
if
(
$opt_user
)
...
...
@@ -541,7 +567,6 @@ sub abort
unlink
(
$mail_header_file
);
unlink
("
$log
.mail
");
}
print
LOG
"
Aborting
\n
";
exit
1
;
}
...
...
@@ -683,9 +708,10 @@ sub rm_all
sub
kill_all
{
my
(
$pattern
)
=
@_
;
my
(
$USER
,
$BSD
,
$LINUX
,
$pscmd
,
$user
,
$pid
);
my
(
$USER
,
$BSD
,
$LINUX
,
$pscmd
,
$user
,
$
os
,
$
pid
);
$user
=
$ENV
{'
USER
'};
$BSD
=
-
f
'
/vmunix
'
||
$ENV
{"
OS
"}
eq
"
SunOS4
"
||
$^O
eq
'
darwin
';
$os
=
defined
(
$ENV
{'
OS
'})
?
$ENV
{'
OS
'}
:
"
unknown
";
$BSD
=
-
f
'
/vmunix
'
||
$os
eq
"
SunOS4
"
||
$^O
eq
'
darwin
';
$LINUX
=
$^O
eq
'
linux
';
$pscmd
=
$BSD
?
"
/bin/ps -auxww
"
:
$LINUX
?
"
/bin/ps axuw
"
:
"
/bin/ps -ef
";
...
...
@@ -701,7 +727,7 @@ sub kill_all
{
chop
(
$cand
);
(
$pid_user
,
$pid
)
=
split
('
',
$cand
);
next
if
$pid
==
$$
;
next
if
$pid
eq
$$
;
next
process
if
(
!
(
$cand
=~
$pattern
)
||
$pid_user
ne
$user
);
print
LOG
"
Killing
$_
\n
";
&
killpid
(
$pid
);
...
...
@@ -724,3 +750,14 @@ sub killpid
}
print
LOG
"
$pid
will not die!
\n
";
}
#
# return the current date as a string (YYYY-MM-DD HH:MM:SS)
#
sub
log_timestamp
{
my
@ta
=
localtime
(
time
());
print
LOG
sprintf
("
%4d-%02d-%02d %02d:%02d:%02d
\n
",
$ta
[
5
]
+
1900
,
$ta
[
4
]
+
1
,
$ta
[
3
],
$ta
[
2
],
$ta
[
1
],
$ta
[
0
]);
}
Makefile.am
View file @
5758da14
...
...
@@ -24,7 +24,7 @@ EXTRA_DIST = INSTALL-SOURCE README \
SUBDIRS
=
.
include @docs_dirs@ @readline_dir@
\
@thread_dirs@ @sql_client_dirs@
\
@sql_server_dirs@ scripts tests man
\
@bench_dirs@ support-files os2
libmysql_r
@bench_dirs@ support-files os2
# Relink after clean
CLEANFILES
=
linked_client_sources linked_server_sources linked_libmysql_sources linked_libmysql_r_sources linked_include_sources
...
...
client/mysqladmin.c
View file @
5758da14
...
...
@@ -24,7 +24,7 @@
#endif
#define ADMIN_VERSION "8.23"
#define MAX_MYSQL_VAR
64
#define MAX_MYSQL_VAR
256
#define SHUTDOWN_DEF_TIMEOUT 3600
/* Wait for shutdown */
#define MAX_TRUNC_LENGTH 3
...
...
@@ -986,7 +986,7 @@ static void print_relative_row(MYSQL_RES *result, MYSQL_ROW cur, uint row)
printf
(
"| %-*s|"
,
field
->
max_length
+
1
,
cur
[
0
]);
field
=
mysql_fetch_field
(
result
);
tmp
=
cur
[
1
]
?
strtoull
(
cur
[
1
],
NULL
,
0
)
:
(
ulonglong
)
0
;
tmp
=
cur
[
1
]
?
strtoull
(
cur
[
1
],
NULL
,
1
0
)
:
(
ulonglong
)
0
;
printf
(
" %-*s|
\n
"
,
field
->
max_length
+
1
,
llstr
((
tmp
-
last_values
[
row
]),
buff
));
last_values
[
row
]
=
tmp
;
...
...
configure.in
View file @
5758da14
...
...
@@ -4,7 +4,7 @@ dnl Process this file with autoconf to produce a configure script.
AC_INIT
(
sql/mysqld.cc
)
AC_CANONICAL_SYSTEM
# The Docs Makefile.am parses this line!
AM_INIT_AUTOMAKE
(
mysql, 3.23.5
5
)
AM_INIT_AUTOMAKE
(
mysql, 3.23.5
6
)
AM_CONFIG_HEADER
(
config.h
)
PROTOCOL_VERSION
=
10
...
...
scripts/make_binary_distribution.sh
View file @
5758da14
...
...
@@ -189,7 +189,7 @@ which_1 ()
# Create the result tar file
#
tar
=
`
which_1 gtar
`
tar
=
`
which_1 g
nutar g
tar
`
if
test
"
$?
"
=
"1"
-o
"
$tar
"
=
""
then
tar
=
tar
...
...
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