summaryrefslogtreecommitdiff
blob: 2abb31998082f34d8b3a3668adc3b72c65cba331 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
diff --git a/src/plugins/bittorrent/CMakeLists.txt b/src/plugins/bittorrent/CMakeLists.txt
index de8a2f9..45d26da 100644
--- a/src/plugins/bittorrent/CMakeLists.txt
+++ b/src/plugins/bittorrent/CMakeLists.txt
@@ -153,7 +153,6 @@ IF (WIN32)
 ENDIF (WIN32)
 #ADD_DEFINITIONS(-DBOOST_DYN_LINK)
 ADD_DEFINITIONS(-DTORRENT_LINKING_SHARED)
-ADD_DEFINITIONS(-DBOOST_FILESYSTEM_VERSION=2) #workaround for building with boost 1.46
 #ADD_DEFINITIONS(-D_DLL)
 IF (NOT LC_NO_MOC)
 	QT4_WRAP_CPP (MOC_SRCS ${HEADERS})
diff --git a/src/plugins/bittorrent/torrentmaker.cpp b/src/plugins/bittorrent/torrentmaker.cpp
index 313a6a5..467c4d8 100644
--- a/src/plugins/bittorrent/torrentmaker.cpp
+++ b/src/plugins/bittorrent/torrentmaker.cpp
@@ -40,7 +40,11 @@ namespace LeechCraft
 			{
 				bool FileFilter (const boost::filesystem::path& filename)
 				{
+#if BOOST_FILESYSTEM_VERSION == 2
 					if (filename.leaf () [0] == '.')
+#else
+					if (filename.leaf ().string () [0] == '.')
+#endif
 						return false;
 					QFileInfo fi (QString::fromUtf8 (filename.string ().c_str ()));
 					if ((fi.isDir () ||
@@ -74,7 +78,9 @@ namespace LeechCraft
 					return;
 				}
 
+#if BOOST_FILESYSTEM_VERSION == 2
 				boost::filesystem::path::default_name_check (boost::filesystem::no_check);
+#endif
 
 				libtorrent::file_storage fs;
 #if LIBTORRENT_VERSION_NUM >= 1600