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)
parent cbf52979
...@@ -49,6 +49,14 @@ BUILT_SOURCES = linked_client_sources linked_server_sources \ ...@@ -49,6 +49,14 @@ BUILT_SOURCES = linked_client_sources linked_server_sources \
CLEANFILES = $(BUILT_SOURCES) bdb/build_unix/db.h CLEANFILES = $(BUILT_SOURCES) bdb/build_unix/db.h
DISTCLEANFILES = ac_available_languages_fragment DISTCLEANFILES = ac_available_languages_fragment
# Our current filtering of "sql_yacc.cc" in "sql/Makefile.am" creates
# a problem, if a VPATH build and "sql_yacc.cc" was part of the source
# distribution we end up with one "sql_yacc.cc" in the source tree,
# and one in the build tree. This breaks "distcleancheck", until this
# is sorted out we redefine the find that scans for files not removed
distcleancheck_listfiles = find . -name sql_yacc.cc -o -type f -print
linked_include_sources: linked_include_sources:
cd include; $(MAKE) link_sources cd include; $(MAKE) link_sources
echo timestamp > linked_include_sources echo timestamp > linked_include_sources
...@@ -93,17 +101,11 @@ bin-dist: all ...@@ -93,17 +101,11 @@ bin-dist: all
dist-hook: dist-hook:
rm -rf `find $(distdir) -type d -name SCCS -print` rm -rf `find $(distdir) -type d -name SCCS -print`
rm -f `find $(distdir) -type l -print` rm -f `find $(distdir) -type l -print`
if echo "$(distdir)" | grep -q '^/' ; then \ mkdir -p $(distdir)/win
mkdir -p "$(distdir)/win" ; \
scripts/mysql_install_db --no-defaults --windows \
--basedir=$(top_srcdir) \
--datadir="$(distdir)/win/data"; \
else \
mkdir -p "$$(pwd)/$(distdir)/win" ; \
scripts/mysql_install_db --no-defaults --windows \ scripts/mysql_install_db --no-defaults --windows \
--basedir=$(top_srcdir) \ --basedir=$(top_builddir) \
--datadir="$$(pwd)/$(distdir)/win/data"; \ --datadir=$(distdir)/win/data \
fi --srcdir=$(top_srcdir)
tags: tags:
support-files/build-tags support-files/build-tags
......
...@@ -15,14 +15,17 @@ ...@@ -15,14 +15,17 @@
# Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, # Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
# MA 02111-1307, USA # MA 02111-1307, USA
BUILT_SOURCES = mysql_version.h my_config.h BUILT_SOURCES = $(HEADERS_GEN) abi_check
pkginclude_HEADERS = my_dbug.h m_string.h my_sys.h my_list.h my_xml.h \ HEADERS_GEN = mysql_version.h my_config.h
mysql.h mysql_com.h mysql_embed.h \ HEADERS_ABI = mysql.h mysql_com.h mysql_time.h \
my_list.h my_alloc.h typelib.h
pkginclude_HEADERS = $(HEADERS_ABI) my_dbug.h m_string.h my_sys.h \
my_xml.h mysql_embed.h \
my_semaphore.h my_pthread.h my_no_pthread.h raid.h \ my_semaphore.h my_pthread.h my_no_pthread.h raid.h \
errmsg.h my_global.h my_net.h my_alloc.h \ errmsg.h my_global.h my_net.h \
my_getopt.h sslopt-longopts.h my_dir.h typelib.h \ my_getopt.h sslopt-longopts.h my_dir.h \
sslopt-vars.h sslopt-case.h sql_common.h keycache.h \ sslopt-vars.h sslopt-case.h sql_common.h keycache.h \
mysql_time.h m_ctype.h $(BUILT_SOURCES) m_ctype.h $(HEADERS_GEN)
noinst_HEADERS = config-win.h config-os2.h config-netware.h \ noinst_HEADERS = config-win.h config-os2.h config-netware.h \
heap.h my_bitmap.h\ heap.h my_bitmap.h\
myisam.h myisampack.h myisammrg.h ft_global.h\ myisam.h myisampack.h myisammrg.h ft_global.h\
...@@ -59,8 +62,7 @@ dist-hook: ...@@ -59,8 +62,7 @@ dist-hook:
# #
# Create a icheck file and compare it to the reference # Create a icheck file and compare it to the reference
abi_check: mysql.h mysql_version.h mysql_com.h mysql_time.h my_list.h \ abi_check: $(HEADERS_ABI) mysql_version.h mysql_h.ic
my_alloc.h typelib.h mysql_h.ic
@set -ex; \ @set -ex; \
if [ @ICHECK@ != no ] ; then \ if [ @ICHECK@ != no ] ; then \
@ICHECK@ --canonify --skip-from-re /usr/ -o $@.ic mysql.h; \ @ICHECK@ --canonify --skip-from-re /usr/ -o $@.ic mysql.h; \
...@@ -68,8 +70,5 @@ abi_check: mysql.h mysql_version.h mysql_com.h mysql_time.h my_list.h \ ...@@ -68,8 +70,5 @@ abi_check: mysql.h mysql_version.h mysql_com.h mysql_time.h my_list.h \
fi; \ fi; \
touch abi_check; touch abi_check;
all: abi_check
# Don't update the files from bitkeeper # Don't update the files from bitkeeper
%::SCCS/s.% %::SCCS/s.%
...@@ -33,6 +33,7 @@ parse_arguments() { ...@@ -33,6 +33,7 @@ parse_arguments() {
case "$arg" in case "$arg" in
--force) force=1 ;; --force) force=1 ;;
--basedir=*) basedir=`echo "$arg" | sed -e 's/^[^=]*=//'` ;; --basedir=*) basedir=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
--srcdir=*) srcdir=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
--ldata=*|--datadir=*) ldata=`echo "$arg" | sed -e 's/^[^=]*=//'` ;; --ldata=*|--datadir=*) ldata=`echo "$arg" | sed -e 's/^[^=]*=//'` ;;
--user=*) --user=*)
# Note that the user will be passed to mysqld so that it runs # Note that the user will be passed to mysqld so that it runs
...@@ -78,6 +79,7 @@ ldata= ...@@ -78,6 +79,7 @@ ldata=
execdir= execdir=
bindir= bindir=
basedir= basedir=
srcdir=
force=0 force=0
verbose=0 verbose=0
fill_help_tables="" fill_help_tables=""
...@@ -106,18 +108,24 @@ else ...@@ -106,18 +108,24 @@ else
fi fi
# find fill_help_tables.sh # find fill_help_tables.sh
for i in $basedir/support-files $basedir/share $basedir/share/mysql $basedir/scripts `pwd` `pwd`/scripts @pkgdatadir@ if test -n "$srcdir"
do then
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 if test -f $i/fill_help_tables.sql
then then
pkgdatadir=$i pkgdatadir=$i
fi fi
done done
if test -f $pkgdatadir/fill_help_tables.sql
then
fill_help_tables=$pkgdatadir/fill_help_tables.sql fill_help_tables=$pkgdatadir/fill_help_tables.sql
else fi
if test ! -f $fill_help_tables
then
echo "Could not find help file 'fill_help_tables.sql' in @pkgdatadir@ or inside $basedir". echo "Could not find help file 'fill_help_tables.sql' in @pkgdatadir@ or inside $basedir".
exit 1; exit 1;
fi fi
...@@ -130,7 +138,13 @@ scriptdir=$bindir ...@@ -130,7 +138,13 @@ scriptdir=$bindir
if test "$windows" = 1 if test "$windows" = 1
then then
mysqld="./sql/mysqld" 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" scriptdir="./scripts"
fi fi
......
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