3 # Usage: fixQtModulePaths _dir_
5 # Find Qt module definitions in directory _dir_ and patch the module paths.
9 local lib
="${!outputLib}"
11 if [ -d "$dir" ]; then
12 find "$dir" -name 'qt_*.pri' |
while read pr; do
13 if grep -q '\$\$QT_MODULE_' "${pr:?}"; then
14 echo "fixQtModulePaths: Fixing module paths in \`${pr:?}'..."
16 -e "s|\\\$\\\$QT_MODULE_LIB_BASE|$lib/lib|g" \
17 -e "s|\\\$\\\$QT_MODULE_HOST_LIB_BASE|$lib/lib|g" \
18 -e "s|\\\$\\\$QT_MODULE_INCLUDE_BASE|$lib/include|g" \
19 -e "s|\\\$\\\$QT_MODULE_BIN_BASE|$lib/bin|g"
22 elif [ -e "$dir" ]; then
23 echo "fixQtModulePaths: Warning: \`$dir' is not a directory"
25 echo "fixQtModulePaths: Warning: \`$dir' does not exist"