|
|
|
@ -39,6 +39,7 @@
|
|
|
|
|
**********************************************************************/
|
|
|
|
|
|
|
|
|
|
#include "qplatformdefs.h"
|
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
|
|
|
|
|
// POSIX Large File Support redefines open -> open64
|
|
|
|
|
static inline int qt_open( const char *pathname, int flags, mode_t mode )
|
|
|
|
@ -468,7 +469,19 @@ QSettingsPrivate::QSettingsPrivate( QSettings::Format format )
|
|
|
|
|
Q_UNUSED( format );
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
QString appSettings(QDir::homeDirPath() + "/.qt/");
|
|
|
|
|
QString home;
|
|
|
|
|
home = getenv("QT_HOME_DIR");
|
|
|
|
|
if ( !home.isEmpty() ) {
|
|
|
|
|
home += "/";
|
|
|
|
|
QFileInfo i( home + "qtrc" );
|
|
|
|
|
if ( !i.isReadable() ) {
|
|
|
|
|
home = QDir::homeDirPath() + "/.qt/";
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
home = QDir::homeDirPath() + "/.qt/";
|
|
|
|
|
}
|
|
|
|
|
QString appSettings(home);
|
|
|
|
|
|
|
|
|
|
QString defPath;
|
|
|
|
|
#ifdef Q_WS_WIN
|
|
|
|
|
#ifdef Q_OS_TEMP
|
|
|
|
@ -517,6 +530,16 @@ QSettingsPrivate::QSettingsPrivate( QSettings::Format format )
|
|
|
|
|
|
|
|
|
|
if ( !!defPath )
|
|
|
|
|
searchPaths.append(defPath);
|
|
|
|
|
|
|
|
|
|
QString system;
|
|
|
|
|
system = getenv("QT_SYSTEM_DIR");
|
|
|
|
|
if ( !system.isEmpty() && system[0] == '/') {
|
|
|
|
|
QFileInfo i( system + "/qtrc" );
|
|
|
|
|
if ( i.isReadable() ) {
|
|
|
|
|
searchPaths.append(system);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
searchPaths.append(dir.path());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|