Don't use "readlink -e" in docs generation script, it's not portable.
"readlink" command also exists under OS X but with a completely different syntax than under Linux, so just use "pwd -P" to get the physical path name instead, this should hopefully work everywhere as it's POSIX. Closes #14796. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72879 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -21,14 +21,11 @@ path=${0%%/$me} # path from which the script has been launched
|
|||||||
current=$(pwd)
|
current=$(pwd)
|
||||||
cd $path
|
cd $path
|
||||||
if [[ -z "$WXWIDGETS" ]]; then
|
if [[ -z "$WXWIDGETS" ]]; then
|
||||||
WXWIDGETS=`cd ../.. && pwd`
|
# Notice the use of -P to ensure we get the canonical path even if there
|
||||||
# Use the real path in case it's a symlink
|
# are symlinks in the current path. This is important because Doxygen
|
||||||
if command -v readlink; then
|
# strips this string from the paths in the generated files textually and it
|
||||||
normalized=`readlink -e $WXWIDGETS`
|
# wouldn't work if it contained symlinks.
|
||||||
if [[ -n $normalized ]]; then
|
WXWIDGETS=`cd ../.. && pwd -P`
|
||||||
WXWIDGETS=$normalized
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
if [ "$OSTYPE" = "cygwin" ]; then
|
if [ "$OSTYPE" = "cygwin" ]; then
|
||||||
WXWIDGETS=`cygpath -w $WXWIDGETS`
|
WXWIDGETS=`cygpath -w $WXWIDGETS`
|
||||||
fi
|
fi
|
||||||
|
Reference in New Issue
Block a user