summaryrefslogtreecommitdiff
path: root/debian/patches
diff options
context:
space:
mode:
authorHilko Bengen <bengen@debian.org>2014-06-08 23:01:37 +0200
committerHilko Bengen <bengen@debian.org>2014-06-09 09:30:22 +0200
commitd981178802215457e9cc737b67342f0ea0ca3b47 (patch)
tree822f7b9e09658566f0b75b1fedbb7945486fb8fc /debian/patches
parentf4fa8baf9af9f9751169cc265da9b750d4390c28 (diff)
downloadelasticsearch-d981178802215457e9cc737b67342f0ea0ca3b47.tar.gz
Initial releasedebian/1.0.3+dfsg-1
Diffstat (limited to 'debian/patches')
-rw-r--r--debian/patches/0001-Assemble-classpath-from-.jar-files-in-usr-share-java.patch29
-rw-r--r--debian/patches/0002-Use-lzf.util.ChunkEncoderFactory-so-we-can-build-wit.patch30
-rw-r--r--debian/patches/0003-Do-not-set-build-hash.patch16
-rw-r--r--debian/patches/0004-Add-lucene-sandbox-in-pom.xml.patch34
-rw-r--r--debian/patches/series4
5 files changed, 113 insertions, 0 deletions
diff --git a/debian/patches/0001-Assemble-classpath-from-.jar-files-in-usr-share-java.patch b/debian/patches/0001-Assemble-classpath-from-.jar-files-in-usr-share-java.patch
new file mode 100644
index 0000000..cccb763
--- /dev/null
+++ b/debian/patches/0001-Assemble-classpath-from-.jar-files-in-usr-share-java.patch
@@ -0,0 +1,29 @@
+From: Hilko Bengen <bengen@debian.org>
+Date: Sat, 7 Jun 2014 12:07:50 +0200
+Subject: Assemble classpath from .jar files in /usr/share/java
+
+---
+ bin/elasticsearch.in.sh | 8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+ mode change 100644 => 100755 bin/elasticsearch.in.sh
+
+diff --git a/bin/elasticsearch.in.sh b/bin/elasticsearch.in.sh
+old mode 100644
+new mode 100755
+index 8713205..aa6a85d
+--- a/bin/elasticsearch.in.sh
++++ b/bin/elasticsearch.in.sh
+@@ -1,6 +1,12 @@
+ #!/bin/sh
+
+-ES_CLASSPATH=$ES_CLASSPATH:$ES_HOME/lib/${project.build.finalName}.jar:$ES_HOME/lib/*:$ES_HOME/lib/sigar/*
++JAR_NAMES="${project.build.finalName} sigar* jna-3.* jts-1.* log4j-1.2.* lucene*-4.* spatial4j-*"
++
++for name in $JAR_NAMES; do
++ ES_CLASSPATH=$ES_CLASSPATH:$(find /usr/share/java/ -name "$name.jar" \
++ | tr '\n' : \
++ | sed -e 's,::*,:,g' )
++done
+
+ if [ "x$ES_MIN_MEM" = "x" ]; then
+ ES_MIN_MEM=256m
diff --git a/debian/patches/0002-Use-lzf.util.ChunkEncoderFactory-so-we-can-build-wit.patch b/debian/patches/0002-Use-lzf.util.ChunkEncoderFactory-so-we-can-build-wit.patch
new file mode 100644
index 0000000..4f8d559
--- /dev/null
+++ b/debian/patches/0002-Use-lzf.util.ChunkEncoderFactory-so-we-can-build-wit.patch
@@ -0,0 +1,30 @@
+From: Hilko Bengen <bengen@debian.org>
+Date: Sun, 8 Jun 2014 22:50:08 +0200
+Subject: Use lzf.util.ChunkEncoderFactory so we can build with compress-lzf
+ 1.0.1
+
+---
+ .../elasticsearch/common/compress/lzf/LZFCompressedStreamOutput.java | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/main/java/org/elasticsearch/common/compress/lzf/LZFCompressedStreamOutput.java b/src/main/java/org/elasticsearch/common/compress/lzf/LZFCompressedStreamOutput.java
+index 00899fd..b34a82c 100644
+--- a/src/main/java/org/elasticsearch/common/compress/lzf/LZFCompressedStreamOutput.java
++++ b/src/main/java/org/elasticsearch/common/compress/lzf/LZFCompressedStreamOutput.java
+@@ -20,6 +20,7 @@
+ package org.elasticsearch.common.compress.lzf;
+
+ import com.ning.compress.BufferRecycler;
++import com.ning.compress.lzf.util.ChunkEncoderFactory;
+ import com.ning.compress.lzf.ChunkEncoder;
+ import com.ning.compress.lzf.LZFChunk;
+ import org.elasticsearch.common.compress.CompressedStreamOutput;
+@@ -39,7 +40,7 @@ public class LZFCompressedStreamOutput extends CompressedStreamOutput<LZFCompres
+ this.recycler = BufferRecycler.instance();
+ this.uncompressed = this.recycler.allocOutputBuffer(LZFChunk.MAX_CHUNK_LEN);
+ this.uncompressedLength = LZFChunk.MAX_CHUNK_LEN;
+- this.encoder = new ChunkEncoder(LZFChunk.MAX_CHUNK_LEN);
++ this.encoder = ChunkEncoderFactory.optimalInstance(LZFChunk.MAX_CHUNK_LEN);
+ }
+
+ @Override
diff --git a/debian/patches/0003-Do-not-set-build-hash.patch b/debian/patches/0003-Do-not-set-build-hash.patch
new file mode 100644
index 0000000..c5e26c4
--- /dev/null
+++ b/debian/patches/0003-Do-not-set-build-hash.patch
@@ -0,0 +1,16 @@
+From: Hilko Bengen <bengen@debian.org>
+Date: Mon, 9 Jun 2014 00:11:28 +0200
+Subject: Do not set build hash
+
+---
+ src/main/resources/es-build.properties | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/src/main/resources/es-build.properties b/src/main/resources/es-build.properties
+index 563ecdd..570373a 100644
+--- a/src/main/resources/es-build.properties
++++ b/src/main/resources/es-build.properties
+@@ -1,3 +1,2 @@
+ version=${project.version}
+-hash=${buildNumber}
+ timestamp=${timestamp}
diff --git a/debian/patches/0004-Add-lucene-sandbox-in-pom.xml.patch b/debian/patches/0004-Add-lucene-sandbox-in-pom.xml.patch
new file mode 100644
index 0000000..1adaa45
--- /dev/null
+++ b/debian/patches/0004-Add-lucene-sandbox-in-pom.xml.patch
@@ -0,0 +1,34 @@
+From: Hilko Bengen <bengen@debian.org>
+Date: Sat, 7 Jun 2014 12:07:50 +0200
+Subject: Add lucene-sandbox in pom.xml
+
+---
+ pom.xml | 15 +++++++++++++++
+ 1 file changed, 15 insertions(+)
+
+diff --git a/pom.xml b/pom.xml
+index b6be5d0..34991c0 100644
+--- a/pom.xml
++++ b/pom.xml
+@@ -143,6 +143,21 @@
+ <version>${lucene.version}</version>
+ <scope>compile</scope>
+ </dependency>
++ <!-- Adding lucene-sandbox avoids the following failures:
++ [ERROR]
++ /«BUILDDIR»/elasticsearch-1.0.3+dfsg/src/main/java/org/elasticsearch/index/query/FuzzyLikeThisFieldQueryParser.java:[23,40]
++ error: package org.apache.lucene.sandbox.queries does not
++ exist
++ [ERROR]
++ /«BUILDDIR»/elasticsearch-1.0.3+dfsg/src/main/java/org/elasticsearch/index/query/FuzzyLikeThisQueryParser.java:[24,40]
++ error: package org.apache.lucene.sandbox.queries does not
++ exist -->
++ <dependency>
++ <groupId>org.apache.lucene</groupId>
++ <artifactId>lucene-sandbox</artifactId>
++ <version>${lucene.version}</version>
++ <scope>compile</scope>
++ </dependency>
+ <dependency>
+ <groupId>com.spatial4j</groupId>
+ <artifactId>spatial4j</artifactId>
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..a3919bf
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1,4 @@
+0001-Assemble-classpath-from-.jar-files-in-usr-share-java.patch
+0002-Use-lzf.util.ChunkEncoderFactory-so-we-can-build-wit.patch
+0003-Do-not-set-build-hash.patch
+0004-Add-lucene-sandbox-in-pom.xml.patch