Commit 50361d9a authored by unknown's avatar unknown
Browse files

Merge mjorgensen@bk-internal.mysql.com:/home/bk/mysql-5.0-sage

into  tiger.mmj.dk:/Users/mmj/bktrees/mysql-5.0


configure.in:
  Auto merged
mysql-test/install_test_db.sh:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
scripts/mysql_install_db.sh:
  Auto merged
sql/CMakeLists.txt:
  Auto merged
sql/mysqld.cc:
  Auto merged
win/configure.js:
  Auto merged
parents c11c3b08 a4817ace
Loading
Loading
Loading
Loading
+16 −0
Original line number Diff line number Diff line
@@ -713,6 +713,22 @@ else
  AC_MSG_RESULT([no])
fi

# If we should allow init-file, skip-grant-table and bootstrap options
AC_MSG_CHECKING(If we should should enable init-file, skip-grant-table options and bootstrap)
AC_ARG_ENABLE(grant-options,
    [  --disable-grant-options Disables the use of --init-file, --skip-grant-tables and --bootstrap options],
    [ mysql_grant_options_enabled=$enableval ],
    [ mysql_grant_options_enabled=yes ]
    )
if test "$mysql_grant_options_enabled" = "yes"
then
  AC_MSG_RESULT([yes])
else
  AC_DEFINE([DISABLE_GRANT_OPTIONS], [1],
            [Disables the use of --init-file, --skip-grant-tables and --bootstrap options])
  AC_MSG_RESULT([no])
fi

MYSQL_SYS_LARGEFILE

# Types that must be checked AFTER large file support is checked
+10 −4
Original line number Diff line number Diff line
@@ -67,14 +67,17 @@ fi
mdata=$data/mysql
EXTRA_ARG=""

if test ! -x $execdir/mysqld
mysqld=
if test -x $execdir/mysqld
then
  mysqld=$execdir/mysqld
else
  if test ! -x $libexecdir/mysqld
  then
    echo "mysqld is missing - looked in $execdir and in $libexecdir"
    exit 1
  else
    execdir=$libexecdir
    mysqld=$libexecdir/mysqld
  fi
fi

@@ -100,8 +103,11 @@ basedir=.
EXTRA_ARG="--language=../sql/share/english/ --character-sets-dir=../sql/share/charsets/"
fi

mysqld_boot=" $execdir/mysqld --no-defaults --bootstrap --skip-grant-tables \
    --basedir=$basedir --datadir=$ldata --skip-innodb --skip-ndbcluster --skip-bdb \
mysqld_boot="${MYSQLD_BOOTSTRAP-$mysqld}"

mysqld_boot="$mysqld_boot --no-defaults --bootstrap --skip-grant-tables \
    --basedir=$basedir --datadir=$ldata \
    --skip-innodb --skip-ndbcluster --skip-bdb \
    $EXTRA_ARG"
echo "running $mysqld_boot"

+9 −2
Original line number Diff line number Diff line
@@ -2873,12 +2873,19 @@ sub install_db ($$) {
    mtr_add_arg($args, "--character-sets-dir=%s", $path_charsetsdir);
  }

  # If DISABLE_GRANT_OPTIONS is defined when the server is compiled (e.g.,
  # configure --disable-grant-options), mysqld will not recognize the
  # --bootstrap or --skip-grant-tables options.  The user can set
  # MYSQLD_BOOTSTRAP to the full path to a mysqld which does accept
  # --bootstrap, to accommodate this.
  my $exe_mysqld_bootstrap = $ENV{'MYSQLD_BOOTSTRAP'} || $exe_mysqld;

  # Log bootstrap command
  my $path_bootstrap_log= "$opt_vardir/log/bootstrap.log";
  mtr_tofile($path_bootstrap_log,
	     "$exe_mysqld " . join(" ", @$args) . "\n");
	     "$exe_mysqld_bootstrap " . join(" ", @$args) . "\n");

  if ( mtr_run($exe_mysqld, $args, $init_db_sql_tmp,
  if ( mtr_run($exe_mysqld_bootstrap, $args, $init_db_sql_tmp,
               $path_bootstrap_log, $path_bootstrap_log,
	       "", { append_log_file => 1 }) != 0 )

+8 −0
Original line number Diff line number Diff line
@@ -292,6 +292,14 @@ void install_db(char *datadir)
    die("Unable to create init_db.sql.");
  /* args */
  init_args(&al);
  /*
    XXX: If mysqld is compiled with DISABLE_GRANT_OPTIONS defined, it
    will not recognize the --bootstrap, --init-file or --skip-grant-
    tables options.  If this is needed here, please check
    MYSQLD_BOOTSTRAP in the environment, and use its value instead of
    mysqld_file if it is set.  See mysql-test-run.pl and
    mysql_install_db.
  */
  add_arg(&al, mysqld_file);
  add_arg(&al, "--no-defaults");
  add_arg(&al, "--bootstrap");
+2 −1
Original line number Diff line number Diff line
@@ -236,7 +236,8 @@ if test "$in_rpm" -eq 0 -a "$windows" -eq 0
then
  echo "Installing all prepared tables"
fi
mysqld_install_cmd_line="$mysqld $defaults $mysqld_opt --bootstrap \
mysqld_bootstrap="${MYSQLD_BOOTSTRAP-$mysqld}"
mysqld_install_cmd_line="$mysqld_bootstrap $defaults $mysqld_opt --bootstrap \
--skip-grant-tables --basedir=$basedir --datadir=$ldata --skip-innodb \
--skip-bdb --skip-ndbcluster $args --max_allowed_packet=8M --net_buffer_length=16K"
if $scriptdir/mysql_create_system_tables $create_option $mdata $hostname $windows \
Loading