summaryrefslogtreecommitdiff
path: root/indra/llvfs/lldir_win32.cpp
diff options
context:
space:
mode:
authorBryan O'Sullivan <bos@lindenlab.com>2009-08-31 13:47:47 -0700
committerBryan O'Sullivan <bos@lindenlab.com>2009-08-31 13:47:47 -0700
commit30ff6cabd61f2f083df5df1e6e70cc94742af477 (patch)
tree631935f1cf59d19a91cdad65e9a75fe825afda7d /indra/llvfs/lldir_win32.cpp
parentff11d74820c89822cd067b51727d9df1dc87d0d0 (diff)
parent3ac3a4b206c08ed06b889bdaa24074b6aa0e020a (diff)
Merge with trunk
Diffstat (limited to 'indra/llvfs/lldir_win32.cpp')
-rw-r--r--indra/llvfs/lldir_win32.cpp34
1 files changed, 32 insertions, 2 deletions
diff --git a/indra/llvfs/lldir_win32.cpp b/indra/llvfs/lldir_win32.cpp
index 19b9bcc6ea..872f2cf1c1 100644
--- a/indra/llvfs/lldir_win32.cpp
+++ b/indra/llvfs/lldir_win32.cpp
@@ -130,6 +130,7 @@ LLDir_Win32::LLDir_Win32()
else
mAppRODataDir = mExecutableDir;
+ mSkinBaseDir = mAppRODataDir + mDirDelimiter + "skins";
// Build the default cache directory
mDefaultCacheDir = buildSLOSCacheDir();
@@ -143,6 +144,8 @@ LLDir_Win32::LLDir_Win32()
llwarns << "Couldn't create LL_PATH_CACHE dir " << mDefaultCacheDir << llendl;
}
}
+
+ mLLPluginDir = mExecutableDir + mDirDelimiter + "llplugin";
}
LLDir_Win32::~LLDir_Win32()
@@ -151,8 +154,15 @@ LLDir_Win32::~LLDir_Win32()
// Implementation
-void LLDir_Win32::initAppDirs(const std::string &app_name)
+void LLDir_Win32::initAppDirs(const std::string &app_name,
+ const std::string& app_read_only_data_dir)
{
+ // Allow override so test apps can read newview directory
+ if (!app_read_only_data_dir.empty())
+ {
+ mAppRODataDir = app_read_only_data_dir;
+ mSkinBaseDir = mAppRODataDir + mDirDelimiter + "skins";
+ }
mAppName = app_name;
mOSUserAppDir = mOSUserDir;
mOSUserAppDir += "\\";
@@ -205,7 +215,14 @@ void LLDir_Win32::initAppDirs(const std::string &app_name)
llwarns << "Couldn't create LL_PATH_MOZILLA_PROFILE dir " << getExpandedFilename(LL_PATH_MOZILLA_PROFILE,"") << llendl;
}
}
-
+ res = LLFile::mkdir(getExpandedFilename(LL_PATH_USER_SKIN,""));
+ if (res == -1)
+ {
+ if (errno != EEXIST)
+ {
+ llwarns << "Couldn't create LL_PATH_SKINS dir " << getExpandedFilename(LL_PATH_USER_SKIN,"") << llendl;
+ }
+ }
mCAFile = getExpandedFilename(LL_PATH_APP_SETTINGS, "CA.pem");
}
@@ -378,6 +395,19 @@ BOOL LLDir_Win32::fileExists(const std::string &filename) const
}
+/*virtual*/ std::string LLDir_Win32::getLLPluginLauncher()
+{
+ return gDirUtilp->getLLPluginDir() + gDirUtilp->getDirDelimiter() +
+ "SLPlugin.exe";
+}
+
+/*virtual*/ std::string LLDir_Win32::getLLPluginFilename(std::string base_name)
+{
+ return gDirUtilp->getLLPluginDir() + gDirUtilp->getDirDelimiter() +
+ base_name + ".dll";
+}
+
+
#if 0
// Utility function to get version number of a DLL