diff options
author | unknown <monty@tik.mysql.fi> | 2002-03-05 15:46:30 +0200 |
---|---|---|
committer | unknown <monty@tik.mysql.fi> | 2002-03-05 15:46:30 +0200 |
commit | 326d80ea649ed1dd0d13640b6e95f5c1df1ae458 (patch) | |
tree | c6069be49c4dde6952ca4a60d0897ab7d509c5b3 | |
parent | 4c164621185c8493de06281ae68ef35f977c13a9 (diff) | |
download | mariadb-git-326d80ea649ed1dd0d13640b6e95f5c1df1ae458.tar.gz |
Update scripts for new POSIX spec
Fix for --enable-local-infile
Portability fix for bison
bdb/dist/s_recover:
Update for new POSIX spec
configure.in:
Fix for --enable-local-infile
libmysql/libmysql.c:
Cleanup
mysql-test/mysql-test-run.sh:
Update for new POSIX spec
scripts/safe_mysqld.sh:
Update for new POSIX spec
sql-bench/server-cfg.sh:
Update for new POSIX spec
sql/sql_yacc.yy:
Portability fix for bison
-rwxr-xr-x | bdb/dist/s_recover | 12 | ||||
-rw-r--r-- | configure.in | 2 | ||||
-rw-r--r-- | libmysql/libmysql.c | 2 | ||||
-rw-r--r-- | mysql-test/mysql-test-run.sh | 11 | ||||
-rw-r--r-- | scripts/safe_mysqld.sh | 2 | ||||
-rw-r--r-- | sql-bench/server-cfg.sh | 2 | ||||
-rw-r--r-- | sql/sql_yacc.yy | 2 |
7 files changed, 22 insertions, 11 deletions
diff --git a/bdb/dist/s_recover b/bdb/dist/s_recover index 0e8b3731c77..b0593cfc052 100755 --- a/bdb/dist/s_recover +++ b/bdb/dist/s_recover @@ -12,6 +12,13 @@ rm -f $loglist trap 'rm -f $t; exit 1' 1 2 3 13 15 +# Use the standard -k option if it works; +# otherwise fall back on the traditional notation. +if sort -k 1,1 /dev/null +then sort_2_etc='-k 2' +else sort_2_etc='+1' +fi + # Check to make sure we haven't duplicated a log record entry, and build # the list of log record types that the test suite uses. for i in $DIR; do @@ -19,13 +26,14 @@ for i in $DIR; do for f in ../$i/*.src; do # Grab the PREFIX; there should only be one per file, and # so it's okay to just take the first. - grep '^PREFIX' $f | head -1 + grep '^PREFIX' $f | sed q egrep '^DEPRECATED[ ]|^BEGIN[ ]' $f | \ awk '{print $1 "\t" $2 "\t" $3}' done done > $loglist -grep -v '^PREFIX' $loglist | awk '{print $2 "\t" $3}' | sort +1 -n | \ +grep -v '^PREFIX' $loglist | awk '{print $2 "\t" $3}' | \ + sort $sort_2_etc -n | \ uniq -d -f 1 > $t [ -s $t ] && { echo "DUPLICATE LOG VALUES:" diff --git a/configure.in b/configure.in index f11e2354dfd..0cd1bf8a145 100644 --- a/configure.in +++ b/configure.in @@ -591,6 +591,8 @@ AC_ARG_ENABLE(local-infile, [ ENABLED_LOCAL_INFILE=no ] ) +AC_SUBST(ENABLE_LOCAL_INFILE) + # Use Paul Eggerts macros from GNU tar to check for large file support. MYSQL_SYS_LARGEFILE diff --git a/libmysql/libmysql.c b/libmysql/libmysql.c index c75bb0ad462..348e3942a63 100644 --- a/libmysql/libmysql.c +++ b/libmysql/libmysql.c @@ -1022,7 +1022,7 @@ mysql_init(MYSQL *mysql) /* Only enable LOAD DATA INFILE by default if configured with - --with-enabled-local-inflile + --enable-local-infile */ #ifdef ENABLED_LOCAL_INFILE mysql->options.client_flag|= CLIENT_LOCAL_FILES; diff --git a/mysql-test/mysql-test-run.sh b/mysql-test/mysql-test-run.sh index 09cdab9664b..76abbc75557 100644 --- a/mysql-test/mysql-test-run.sh +++ b/mysql-test/mysql-test-run.sh @@ -44,21 +44,22 @@ which () # No paths below as we can't be sure where the program is! -BASENAME=`which basename | head -1` -DIFF=`which diff | head -1` +SED=sed + +BASENAME=`which basename | $SED q` +DIFF=`which diff | $SED q` CAT=cat CUT=cut TAIL=tail ECHO=echo # use internal echo if possible EXPR=expr # use internal if possible FIND=find -GCOV=`which gcov | head -1` +GCOV=`which gcov | $SED q` PRINTF=printf RM=rm TIME=time TR=tr -XARGS=`which xargs | head -1` -SED=sed +XARGS=`which xargs | $SED q` # Are we using a source or a binary distribution? diff --git a/scripts/safe_mysqld.sh b/scripts/safe_mysqld.sh index e7418819604..3494e3d707e 100644 --- a/scripts/safe_mysqld.sh +++ b/scripts/safe_mysqld.sh @@ -253,7 +253,7 @@ do I=1 while test "$I" -le "$numofproces" do - PROC=`ps xa | grep $ledir/$MYSQLD | grep -v "grep" | tail -1` + PROC=`ps xa | grep $ledir/$MYSQLD | grep -v "grep" | sed -n '$p'` for T in $PROC do break diff --git a/sql-bench/server-cfg.sh b/sql-bench/server-cfg.sh index b4e134cd2c1..886c428e3b9 100644 --- a/sql-bench/server-cfg.sh +++ b/sql-bench/server-cfg.sh @@ -932,7 +932,7 @@ sub version { if ($dir && -e "$dir/bin/solcon") { - $version=`$dir/bin/solcon -e"ver" $main::opt_user $main::opt_password | grep Server | head -1`; + $version=`$dir/bin/solcon -e"ver" $main::opt_user $main::opt_password | grep Server | sed q`; if ($? == 0) { chomp($version); diff --git a/sql/sql_yacc.yy b/sql/sql_yacc.yy index 54a03d4a714..0cbf6f45194 100644 --- a/sql/sql_yacc.yy +++ b/sql/sql_yacc.yy @@ -30,7 +30,7 @@ extern void yyerror(const char*); int yylex(void *yylval); -#define yyoverflow(A,B,C,D,E,F) if (my_yyoverflow((B),(D),(F))) { yyerror((char*) (A)); return 2; } +#define yyoverflow(A,B,C,D,E,F) if (my_yyoverflow((B),(D),(int*) (F))) { yyerror((char*) (A)); return 2; } inline Item *or_or_concat(Item* A, Item* B) { |