Merge remote-tracking branch 'upstream/master'

actorid
Nikolay Kasyanov 13 years ago
commit 3875c0f97a

@ -188,7 +188,6 @@ void DataFilesPage::setupDataFiles()
// Put the paths in a boost::filesystem vector to use with Files::Collections
Files::PathContainer dataDirs(variables["data"].as<Files::PathContainer>());
mCfgMgr.processPaths(dataDirs);
std::string local(variables["data-local"].as<std::string>());
if (!local.empty())
@ -201,6 +200,8 @@ void DataFilesPage::setupDataFiles()
dataDirs.push_back(mCfgMgr.getLocalPath());
}
mCfgMgr.processPaths(dataDirs);
// Create a file collection for the dataDirs
Files::Collections fileCollections(dataDirs, !variables["fs-strict"].as<bool>());

@ -246,8 +246,6 @@ void OMW::Engine::enableFSStrict(bool fsStrict)
void OMW::Engine::setDataDirs (const Files::PathContainer& dataDirs)
{
/// \todo remove mDataDir, once resources system can handle multiple directories
assert (!dataDirs.empty());
mDataDirs = dataDirs;
mFileCollections = Files::Collections (dataDirs, !mFSStrict);
}

@ -35,6 +35,23 @@
#include "config.hpp"
#include <boost/version.hpp>
/**
* Workaround for problems with whitespaces in paths in older versions of Boost library
*/
#if (BOOST_VERSION <= 104600)
namespace boost
{
template<>
inline boost::filesystem::path lexical_cast<boost::filesystem::path, std::string>(const std::string& arg)
{
return boost::filesystem::path(arg);
}
} /* namespace boost */
#endif /* (BOOST_VERSION <= 104600) */
using namespace std;
/**

Loading…
Cancel
Save