summaryrefslogtreecommitdiff
path: root/Build-tools/Do-compile
diff options
context:
space:
mode:
authormonty@hundin.mysql.fi <>2002-08-17 18:02:56 +0300
committermonty@hundin.mysql.fi <>2002-08-17 18:02:56 +0300
commitf7c8bd0e47b8a037f4eb0a7dca2816af97604d07 (patch)
treecb6c69dea958c68e0dfee4737f5b9a8f63b37aee /Build-tools/Do-compile
parentca2e3aacff23f38a89bc005afe6bc34a616e561f (diff)
downloadmariadb-git-f7c8bd0e47b8a037f4eb0a7dca2816af97604d07.tar.gz
Portability fixes for 4.0.3 build.
Don't update MyISAM index file on UPDATE if index is not changed
Diffstat (limited to 'Build-tools/Do-compile')
-rwxr-xr-xBuild-tools/Do-compile32
1 files changed, 20 insertions, 12 deletions
diff --git a/Build-tools/Do-compile b/Build-tools/Do-compile
index 53a79017f1a..58bd2e49a38 100755
--- a/Build-tools/Do-compile
+++ b/Build-tools/Do-compile
@@ -75,6 +75,19 @@ $ENV{"PERL5LIB"}="$pwd/$host/perl5:$pwd/$host/perl5/site_perl";
$slave_port=$mysql_tcp_port+16;
$manager_port=$mysql_tcp_port+1;
+if ($opt_stage == 0)
+{
+ system("mkdir Logs") if (! -d "Logs");
+ system("mv $log ${log}-old") if (-f $log);
+ unlink($log);
+}
+
+open(LOG,">>$log") || abort("Can't open log file, error $?");
+select LOG;
+$|=1;
+select STDOUT;
+$|=1;
+
if (-x "$host/bin/mysqladmin")
{
log_system("$host/bin/mysqladmin --no-defaults -u root -S $mysql_unix_port -s shutdown");
@@ -97,17 +110,8 @@ if ($opt_stage == 0)
}
rm_all("$host/test");
system("mkdir $host/test") if (! -d "$host/test");
- system("mkdir Logs") if (! -d "Logs");
- system("mv $log ${log}-old") if (-f $log);
- unlink($log);
}
-open(LOG,">>$log") || abort("Can't open log file, error $?");
-select LOG;
-$|=1;
-select STDOUT;
-$|=1;
-
safe_cd($host);
if ($opt_stage == 0 && ! $opt_use_old_distribution)
{
@@ -553,13 +557,17 @@ sub rm_all
sub kill_all
{
my ($pattern) = @_;
- my ($USER,$BSD,$LINUX,$pscmd, $user, $pid);
+ my ($USER,$BSD,$LINUX, $pscmd, $user, $pid);
$user=$ENV{'USER'};
- $BSD = -f '/vmunix' || $ENV{"OS"} eq "SunOS4";
+ $BSD = -f '/vmunix' || $ENV{"OS"} eq "SunOS4" || $^O eq 'darwin';
$LINUX = $^O eq 'linux';
$pscmd = $BSD ? "/bin/ps -auxww" : $LINUX ? "/bin/ps axuw" : "/bin/ps -ef";
- open(PS, "$pscmd|") || die "can't run $pscmd: $!";
+ if (!open(PS, "$pscmd|"))
+ {
+ print "Warning: Can't run $pscmd: $!\n";
+ exit;
+ }
# Catch any errors with eval. A bad pattern, for instance.
process: