Commit e0cbe8f4 authored by marko's avatar marko

branches/zip: scripts/dynconfig: Minor cleanup (spelling and formatting).

parent 1f13d1f1
#!/usr/bin/perl -w
#!/usr/bin/perl -w
#
# (C)opyright Oracle/Innobase Oy. 2007.
#
......@@ -11,9 +11,12 @@
#
# RETURNS: 0 OK
use strict;
use warnings;
my $buffer;
# These are the eninges whose config parameters we need to remove.
# These are the engines whose config parameters we need to remove.
my @engines = (
"ndbcluster",
"innodb",
......@@ -25,7 +28,7 @@ my @engines = (
"embedded-server",
"partition"
);
# Map the following variables to something else. If you want to remove any
# parameters from the configure command line, simply add an "" value to the
# hashtable below.
......@@ -103,8 +106,7 @@ sub squeeze($) {
}
if ($#ARGV < 0) {
print "usage: <patch/to/mysqlbug> [options e.g. CC=xxx]\n";
exit(1);
die "usage: $0 <path/to/mysqlbug> [options e.g. CC=gcc CXX=gcc]\n";
}
open(F, $ARGV[0]) ||
......@@ -117,12 +119,10 @@ my @matched = grep(/^CONFIGURE_LINE=/, split(/\n/, $buffer));
# Check for no match
if ($#matched == -1 ) {
print "CONFIGURE_LINE= not found in : $ARGV[0]\n";
exit(1);
die "CONFIGURE_LINE= not found in : $ARGV[0]\n";
# Check if more than one line matched
} elsif ($#matched > 0) {
printf "Error too many matches found.\n";
exit(1);
die "Error: $#matched matches found.\n";
}
# Since CONFIGURE_LINE is an environment variable we extract the value,
......@@ -153,7 +153,7 @@ if (defined($ENV{"MYSQL_CONFIG_DEL"})) {
}
}
my @arr = split(/'/, $configure);
my @arr = split("'", $configure);
foreach my $param (@arr) {
......@@ -172,7 +172,7 @@ foreach my $param (@arr) {
$param = map_param($param);
if (length($param) > 0) {
print "'$param' ";
print " '$param'";
}
}
......@@ -186,9 +186,10 @@ if (defined($ENV{"MYSQL_CONFIG_ADD"})) {
if ($param =~ /^'(.+)'$/) {
$param = $1;
}
print "'$param' ";
print " '$param'";
}
}
exit(0);
print "\n";
exit(0);
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment