summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorunknown <kent@mysql.com/kent-amd64.(none)>2006-12-02 23:16:47 +0100
committerunknown <kent@mysql.com/kent-amd64.(none)>2006-12-02 23:16:47 +0100
commit1172c8ae5568374de74037644a9a082722df9fab (patch)
tree9b1fa0a5db3a3cbc452349f2f40cf07832746ab3 /scripts
parentca35cae78be2a5152a6dd50a0b929a7ffb64b3c6 (diff)
downloadmariadb-git-1172c8ae5568374de74037644a9a082722df9fab.tar.gz
mysql_install_db.sh:
If --srcdir and --windows is given, check if error message file is in source or build tree (bug#24557) Makefile.am: Cleaned up "ali_check" target, to satisfy "distcleancheck" (bug#24557) mysql_install_db.sh: Added --srcdir=DIR option, used from top Makefile.am in dist-hook target, to find "fill_help_tables.sql" in VPATH build (bug#24557) Makefile.am: Work around problem with "distcleancheck", "sql_yacc.cc" might be in both the source and build tree. Call "mysql_install_db" with new option --srcdir, to enable the script to find all that is needed, if source and build directory is not the same (bug#24557) scripts/mysql_install_db.sh: If --srcdir and --windows is given, check if error message file is in source or build tree (bug#24557) Makefile.am: Work around problem with "distcleancheck", "sql_yacc.cc" might be in both the source and build tree. Call "mysql_install_db" with new option --srcdir, to enable the script to find all that is needed, if source and build directory is not the same (bug#24557) include/Makefile.am: Cleaned up "ali_check" target, to satisfy "distcleancheck" (bug#24557)
Diffstat (limited to 'scripts')
-rw-r--r--scripts/mysql_install_db.sh36
1 files changed, 25 insertions, 11 deletions
diff --git a/scripts/mysql_install_db.sh b/scripts/mysql_install_db.sh
index 5d7933e5277..e43b586054e 100644
--- a/scripts/mysql_install_db.sh
+++ b/scripts/mysql_install_db.sh
@@ -33,6 +33,7 @@ parse_arguments() {
case "$arg" in
--force) force=1 ;;
--basedir=*) basedir=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
+ --srcdir=*) srcdir=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
--ldata=*|--datadir=*) ldata=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
--user=*)
# Note that the user will be passed to mysqld so that it runs
@@ -78,6 +79,7 @@ ldata=
execdir=
bindir=
basedir=
+srcdir=
force=0
verbose=0
fill_help_tables=""
@@ -106,18 +108,24 @@ else
fi
# find fill_help_tables.sh
-for i in $basedir/support-files $basedir/share $basedir/share/mysql $basedir/scripts `pwd` `pwd`/scripts @pkgdatadir@
-do
- if test -f $i/fill_help_tables.sql
- then
- pkgdatadir=$i
- fi
-done
-
-if test -f $pkgdatadir/fill_help_tables.sql
+if test -n "$srcdir"
then
- fill_help_tables=$pkgdatadir/fill_help_tables.sql
+ fill_help_tables=$srcdir/scripts/fill_help_tables.sql
else
+ for i in $basedir/support-files $basedir/share $basedir/share/mysql \
+ $basedir/scripts `pwd` `pwd`/scripts @pkgdatadir@
+ do
+ if test -f $i/fill_help_tables.sql
+ then
+ pkgdatadir=$i
+ fi
+ done
+
+ fill_help_tables=$pkgdatadir/fill_help_tables.sql
+fi
+
+if test ! -f $fill_help_tables
+then
echo "Could not find help file 'fill_help_tables.sql' in @pkgdatadir@ or inside $basedir".
exit 1;
fi
@@ -130,7 +138,13 @@ scriptdir=$bindir
if test "$windows" = 1
then
mysqld="./sql/mysqld"
- mysqld_opt="--language=./sql/share/english"
+ if test -n "$srcdir" -a -f $srcdir/sql/share/english/errmsg.sys
+ then
+ langdir=$srcdir/sql/share/english
+ else
+ langdir=./sql/share/english
+ fi
+ mysqld_opt="--language=$langdir"
scriptdir="./scripts"
fi