Update git submodules
[LibreOffice.git] / external / clucene / patches / clucene-libcpp.patch
blob35235212c79570295c77ac547dc9d4945419212a
1 --- src/shared/CLucene/LuceneThreads.h
2 +++ src/shared/CLucene/LuceneThreads.h
3 @@ -7,6 +7,7 @@
4 #ifndef _LuceneThreads_h
5 #define _LuceneThreads_h
7 +#include "CLucene/config/_threads.h"
9 CL_NS_DEF(util)
10 class CLuceneThreadIdCompare;
11 --- src/core/CLucene/util/VoidMap.h
12 +++ src/core/CLucene/util/VoidMap.h
13 @@ -11,8 +11,13 @@
14 #include "CLucene/LuceneThreads.h"
16 #if defined(_CL_HAVE_TR1_UNORDERED_MAP) && defined(_CL_HAVE_TR1_UNORDERED_SET)
17 +#ifdef _LIBCPP_VERSION
18 + #include <unordered_map>
19 + #include <unordered_set>
20 +#else
21 #include <tr1/unordered_map>
22 #include <tr1/unordered_set>
23 +#endif
24 #elif defined(_CL_HAVE_HASH_MAP) && defined(_CL_HAVE_HASH_SET)
25 //hashing is all or nothing!
26 #include <hash_map>
27 --- src/shared/CLucene/config/repl_tchar.h
28 +++ src/shared/CLucene/config/repl_tchar.h
29 @@ -36,8 +36,13 @@
30 #define _tcsncpy wcsncpy //copy a specified amount of one string to another string.
31 #define _tcscat wcscat //copy a string onto the end of the other string
32 #define _tcsncat wcsncat
33 +#if defined(_LIBCPP_VERSION) && defined(__APPLE__)
34 + #define _tcschr ::wcschr //find location of one character
35 + #define _tcsstr ::wcsstr //find location of a string
36 +#else
37 #define _tcschr wcschr //find location of one character
38 #define _tcsstr wcsstr //find location of a string
39 +#endif
40 #define _tcslen wcslen //get length of a string
41 #define _tcscmp wcscmp //case sensitive compare two strings
42 #define _tcsncmp wcsncmp //case sensitive compare two strings