summaryrefslogtreecommitdiff
path: root/scripts/mysql_config.sh
diff options
context:
space:
mode:
authormonty@hundin.mysql.fi <>2002-01-30 16:37:47 +0200
committermonty@hundin.mysql.fi <>2002-01-30 16:37:47 +0200
commit79796e989f13c98df32e13d404571b76b1ae6dab (patch)
tree3ca7f6fddbb9bdc0b635f243af69c6606924c3c2 /scripts/mysql_config.sh
parentc396824b2a733651acbe5a23a40a0e59ce628678 (diff)
parent3457b6fde0ee4c08a45a2a1584522b260c444768 (diff)
downloadmariadb-git-79796e989f13c98df32e13d404571b76b1ae6dab.tar.gz
Merge from 3.23.48 tree
Diffstat (limited to 'scripts/mysql_config.sh')
-rw-r--r--scripts/mysql_config.sh17
1 files changed, 11 insertions, 6 deletions
diff --git a/scripts/mysql_config.sh b/scripts/mysql_config.sh
index 31e3ed42e0a..6a31db9a2b3 100644
--- a/scripts/mysql_config.sh
+++ b/scripts/mysql_config.sh
@@ -58,12 +58,16 @@ fix_path ()
done
}
-abs_path=`expr \( substr $0 1 1 \) = '/'`
-if [ "x$abs_path" = "x1" ] ; then
- me=$0
-else
- me=`which $0`
-fi
+get_full_path ()
+{
+ case $1 in
+ /*) echo "$1";;
+ ./*) tmp=`pwd`/$1; echo $tmp | sed -e 's;/./;/;' ;;
+ *) which $1 ;;
+ esac
+}
+
+me=`get_full_path $0`
basedir=`echo $me | sed -e 's;/bin/mysql_config;;'`
@@ -81,6 +85,7 @@ ldflags='@LDFLAGS@'
client_libs='@CLIENT_LIBS@'
libs="$ldflags -L'$pkglibdir' -lmysqlclient $client_libs"
+libs=`echo $libs | sed -e 's; +;;'`
cflags="-I'$pkgincludedir'"
embedded_libs="$ldflags -L'$pkglibdir' -lmysqld @LIBS@ @innodb_system_libs@"