Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'intern/cycles/util/util_cache.cpp')
-rw-r--r--intern/cycles/util/util_cache.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/intern/cycles/util/util_cache.cpp b/intern/cycles/util/util_cache.cpp
index 2924ed30b88..d09e256c891 100644
--- a/intern/cycles/util/util_cache.cpp
+++ b/intern/cycles/util/util_cache.cpp
@@ -26,6 +26,10 @@
#include "util_path.h"
#include "util_types.h"
+#if (BOOST_VERSION < 104400)
+# define BOOST_FILESYSTEM_VERSION 2
+#endif
+
#include <boost/filesystem.hpp>
#include <boost/algorithm/string.hpp>
@@ -115,7 +119,11 @@ void Cache::clear_except(const string& name, const set<string>& except)
boost::filesystem::directory_iterator it(dir), it_end;
for(; it != it_end; it++) {
+#if (BOOST_FILESYSTEM_VERSION == 2)
+ string filename = it->path().filename();
+#else
string filename = it->path().filename().string();
+#endif
if(boost::starts_with(filename, name))
if(except.find(filename) == except.end())