Do not assume FHS in scripts
On systems that do not follow the Filesystem Hierarchy Standard, such as guix, the hardcoded `/bin/pwd` will fail to be found so that the script will fail. Use `pwd`, instead, so that the command can be found through the normal path search mechanism. Change-Id: Ib5480aeda5ca9d241286be6d1f95e9a0810476a8 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
This commit is contained in:
parent
9a6c32bed1
commit
3388de698b
@ -2,6 +2,6 @@
|
||||
|
||||
# The directory of this script is the expanded absolute path of the "$qt_prefix/bin" directory.
|
||||
script_dir_path=`dirname $0`
|
||||
script_dir_path=`(cd "$script_dir_path"; /bin/pwd)`
|
||||
script_dir_path=`(cd "$script_dir_path"; pwd)`
|
||||
|
||||
@host_qt_bindir@/@tool_name@@tool_version@ -qtconf "$script_dir_path/target_qt.conf" $*
|
||||
|
@ -5,7 +5,7 @@ HELP_MESSAGE="Usage
|
||||
|
||||
# The directory of this script is the expanded absolute path of the "$qt_prefix/bin" directory.
|
||||
script_dir_path=`dirname $0`
|
||||
script_dir_path=`(cd "$script_dir_path"; /bin/pwd)`
|
||||
script_dir_path=`(cd "$script_dir_path"; pwd)`
|
||||
|
||||
# Try to use original cmake, otherwise to make it relocatable, use any cmake found in PATH.
|
||||
original_cmake_path="@CMAKE_COMMAND@"
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
# The directory of this script is the expanded absolute path of the "$qt_prefix/bin" directory.
|
||||
script_dir_path=`dirname $0`
|
||||
script_dir_path=`(cd "$script_dir_path"; /bin/pwd)`
|
||||
script_dir_path=`(cd "$script_dir_path"; pwd)`
|
||||
|
||||
# Try to use original cmake, otherwise to make it relocatable, use any cmake found in PATH.
|
||||
original_cmake_path="@CMAKE_COMMAND@"
|
||||
|
@ -2,7 +2,7 @@
|
||||
set -eu
|
||||
|
||||
script_dir_path=`dirname $0`
|
||||
script_dir_path=`(cd "$script_dir_path"; /bin/pwd)`
|
||||
script_dir_path=`(cd "$script_dir_path"; pwd)`
|
||||
|
||||
printUsage()
|
||||
{
|
||||
|
4
configure
vendored
4
configure
vendored
@ -9,9 +9,9 @@
|
||||
|
||||
# the directory of this script is the "source tree"
|
||||
relpath=`dirname "$0"`
|
||||
relpath=`(cd "$relpath"; /bin/pwd)`
|
||||
relpath=`(cd "$relpath"; pwd)`
|
||||
# the current directory is the "build tree" or "object tree"
|
||||
outpath=`/bin/pwd`
|
||||
outpath=`pwd`
|
||||
outpathPrefix=$outpath
|
||||
|
||||
# do this early so we don't store it in config.status
|
||||
|
@ -1,5 +1,5 @@
|
||||
#!/bin/sh
|
||||
script_dir_path=`dirname $0`
|
||||
script_dir_path=`(cd "$script_dir_path"; /bin/pwd)`
|
||||
script_dir_path=`(cd "$script_dir_path"; pwd)`
|
||||
|
||||
"$script_dir_path/@relative_path_from_libexec_dir_to_bin_dir@/qt-cmake" @script_passed_args@ "$@"
|
||||
|
@ -1,5 +1,5 @@
|
||||
#!/bin/sh
|
||||
script_dir_path=`dirname $0`
|
||||
script_dir_path=`(cd "$script_dir_path"; /bin/pwd)`
|
||||
script_dir_path=`(cd "$script_dir_path"; pwd)`
|
||||
|
||||
"$script_dir_path/@relative_path_from_libexec_dir_to_bin_dir@/qt-cmake" @script_passed_args@ "$@"
|
||||
|
Loading…
x
Reference in New Issue
Block a user