summaryrefslogtreecommitdiff
path: root/clucene
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@suse.cz>2012-03-10 15:34:24 +0100
committerLuboš Luňák <l.lunak@suse.cz>2012-03-10 16:39:22 +0100
commit41d7a444bee3ba8ed7c8d5fbbc57fd29c86ddb19 (patch)
treee4966369e908c900c6f4befac35d4adddb7be88c /clucene
parent4dd7a3f12e81e3db272bc3049c6c33661d81678c (diff)
patch clucene to avoid narrowing conversions
clang errors out on this
Diffstat (limited to 'clucene')
-rw-r--r--clucene/patches/clucene-narrowing-conversions.patch25
-rw-r--r--clucene/source/Makefile1
2 files changed, 26 insertions, 0 deletions
diff --git a/clucene/patches/clucene-narrowing-conversions.patch b/clucene/patches/clucene-narrowing-conversions.patch
new file mode 100644
index 000000000000..f0e971c55dd9
--- /dev/null
+++ b/clucene/patches/clucene-narrowing-conversions.patch
@@ -0,0 +1,25 @@
+--- src/core/CLucene/queryParser/QueryParser.cpp.sav 2011-03-17 01:21:07.000000000 +0100
++++ src/core/CLucene/queryParser/QueryParser.cpp 2012-03-09 18:20:58.000000000 +0100
+@@ -79,7 +79,7 @@
+ _T("<RANGEEX_GOOP>")
+ };
+
+-const int32_t QueryParser::jj_la1_0[] = {0x180,0x180,0xe00,0xe00,0x1f69f80,0x48000,0x10000,0x1f69000,0x1348000,0x80000,0x80000,0x10000,0x18000000,0x2000000,0x18000000,0x10000,0x80000000,0x20000000,0x80000000,0x10000,0x80000,0x10000,0x1f68000};
++const int32_t QueryParser::jj_la1_0[] = {0x180,0x180,0xe00,0xe00,0x1f69f80,0x48000,0x10000,0x1f69000,0x1348000,0x80000,0x80000,0x10000,0x18000000,0x2000000,0x18000000,0x10000,int32_t(0x80000000),0x20000000,int32_t(0x80000000),0x10000,0x80000,0x10000,0x1f68000};
+ const int32_t QueryParser::jj_la1_1[] = {0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x1,0x0,0x1,0x0,0x0,0x0,0x0};
+
+ struct QueryParser::JJCalls {
+--- src/core/CLucene/queryParser/QueryParserTokenManager.cpp.sav 2011-03-17 01:21:07.000000000 +0100
++++ src/core/CLucene/queryParser/QueryParserTokenManager.cpp 2012-03-09 18:20:24.000000000 +0100
+@@ -15,9 +15,9 @@
+
+ CL_NS_DEF(queryParser)
+
+-const int64_t QueryParserTokenManager::jjbitVec2[]={0x0L, 0x0L, _ILONGLONG(0xffffffffffffffff), _ILONGLONG(0xffffffffffffffff)};
++const int64_t QueryParserTokenManager::jjbitVec2[]={0x0L, 0x0L, int64_t(_ILONGLONG(0xffffffffffffffff)), int64_t(_ILONGLONG(0xffffffffffffffff))};
+ const int64_t QueryParserTokenManager::jjbitVec0[] = {
+- _ILONGLONG(0xfffffffffffffffe), _ILONGLONG(0xffffffffffffffff), _ILONGLONG(0xffffffffffffffff), _ILONGLONG(0xffffffffffffffff)
++ int64_t(_ILONGLONG(0xfffffffffffffffe)), int64_t(_ILONGLONG(0xffffffffffffffff)), int64_t(_ILONGLONG(0xffffffffffffffff)), int64_t(_ILONGLONG(0xffffffffffffffff))
+ };
+ const int32_t QueryParserTokenManager::jjnextStates[]={
+ 15, 17, 18, 29, 32, 23, 33, 30, 20, 21, 32, 23, 33, 31, 34, 27,
diff --git a/clucene/source/Makefile b/clucene/source/Makefile
index 2e06a84abe59..f3826ee68436 100644
--- a/clucene/source/Makefile
+++ b/clucene/source/Makefile
@@ -43,6 +43,7 @@ done :
$(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-warnings.patch
$(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-gcc-atomics.patch
$(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-debug.patch
+ $(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-narrowing-conversions.patch
#FIXME ?, our rules expect .cxx
for i in `find . -name "*.cpp"`; do mv $$i $${i%%cpp}cxx; done
ifneq ($(OS),WNT)