make unspecified/empty HostPrefix fall back to Prefix

this is needed for backwards-compatibility, and generally makes sense.

Task-number: QTBUG-24839
Change-Id: I42b008a9dfb43cc2ebe49c8baa2c29f5d6a75897
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
This commit is contained in:
Oswald Buddenhagen 2012-03-20 18:55:28 +01:00 committed by Qt by Nokia
parent b492f54b98
commit a985fa5c51

View File

@ -295,6 +295,12 @@ QLibraryInfo::rawLocation(LibraryLocation loc)
ret = config->value(key, defaultValue).toString();
#ifdef QT_BUILD_QMAKE
if (ret.isEmpty() && loc == HostPrefixPath)
ret = config->value(QLatin1String(qtConfEntries[PrefixPath].key),
QLatin1String(qtConfEntries[PrefixPath].value)).toString();
#endif
// expand environment variables in the form $(ENVVAR)
int rep;
QRegExp reg_var(QLatin1String("\\$\\(.*\\)"));