debian/0000755000000000000000000000000011735424261007173 5ustar debian/source/0000755000000000000000000000000011735423505010473 5ustar debian/source/format0000644000000000000000000000001411735423505011701 0ustar 3.0 (quilt) debian/libsnappy-java.poms0000644000000000000000000000314411735423505013015 0ustar # List of POM files for the package # Format of this file is: # [option]* # where option can be: # --ignore: ignore this POM and its artifact if any # --ignore-pom: don't install the POM. To use on POM files that are created # temporarily for certain artifacts such as Javadoc jars. [mh_install, mh_installpoms] # --no-parent: remove the tag from the POM # --package=: an alternative package to use when installing this POM # and its artifact # --has-package-version: to indicate that the original version of the POM is the same as the upstream part # of the version for the package. # --keep-elements=: a list of XML elements to keep in the POM # during a clean operation with mh_cleanpom or mh_installpom # --artifact=: path to the build artifact associated with this POM, # it will be installed when using the command mh_install. [mh_install] # --java-lib: install the jar into /usr/share/java to comply with Debian # packaging guidelines # --usj-name=: name to use when installing the library in /usr/share/java # --usj-version=: version to use when installing the library in /usr/share/java # --no-usj-versionless: don't install the versionless link in /usr/share/java # --dest-jar=: the destination for the real jar. # It will be installed with mh_install. [mh_install] # --classifier=: Optional, the classifier for the jar. Empty by default. # --site-xml=: Optional, the location for site.xml if it needs to be installed. # Empty by default. [mh_install] # pom.xml debian/README.source0000644000000000000000000000116111735423505011351 0ustar In the original upstream archive, the file ‘lib/silk-weaver.jar’ is not accompanied with its source. To simplify the process, and prevent accidental inclusion of more source-less files in future releases, the whole ‘lib’ directory is removed. Moreover the directory src/main/resources/org/xerial/snappy/native is removed as well because it contains binaries of a Debian packaged library for different OSes. Due to the fact that we are using the Debian packaged version anyway all the files are removed. The prepraration of the according orig tarball can be done by using make -f debian/rules get-orig-source debian/copyright0000644000000000000000000000324711735423505011134 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Source: http://snappy-java.googlecode.com/files/snappy-java-1.0.4.1.tar.gz Comment: lib/silk-weaver.jar is not packaged in Debian, and the other files in this directory are not useful to the Debian package, so they were removed. The native snappy library, for which the sources are not present in the snappy-java archive, was removed as well. Removed: lib src/main/resources/org/xerial/snappy/native Files: * Copyright: © 2008–2011 Taro L. Saito © 2011 xerial.org License: Apache-2.0 Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at . http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. . On Debian systems, the complete text of the Apache License version 2.0 can be found in ‘/usr/share/common-licenses/Apache-2.0’. Comment: This product includes software developed by Google Snappy: http://code.google.com/p/snappy/ (New BSD License) . . This library containd statically linked libstdc++. This inclusion is allowed by "GCC RUntime Library Exception" http://gcc.gnu.org/onlinedocs/libstdc++/manual/license.html . == Contributors == * Tatu Saloranta * Providing benchmark suite * Alec Wysoker * Performance and memory usage improvement debian/rules0000755000000000000000000000030611735423505010252 0ustar #!/usr/bin/make -f include /usr/share/cdbs/1/rules/debhelper.mk include /usr/share/cdbs/1/class/maven.mk JAVA_HOME := /usr/lib/jvm/default-java get-orig-source: uscan --verbose --force-download debian/get-orig-source0000755000000000000000000000211111735423505012127 0ustar #!/bin/sh # get source for snappy-java to enable stripping binaries without source set -e NAME=`dpkg-parsechangelog | awk '/^Source/ { print $2 }'` if ! echo $@ | grep -q upstream-version ; then VERSION=`dpkg-parsechangelog | awk '/^Version:/ { print $2 }' | sed 's/\([0-9\.]\+\)-[0-9]\+$/\1/'` else VERSION=`echo $@ | sed "s?^.*--upstream-version \([0-9.]\+\) .*${NAME}.*?\1?"` if echo "$VERSION" | grep -q "upstream-version" ; then echo "Unable to parse version number" exit fi fi mkdir -p ../tarballs cd ../tarballs mv ../${NAME}-${VERSION}.tar.gz . tar -xzf ${NAME}-${VERSION}.tar.gz # Remove native libraries for different OSes which are not needed because we link # against Debian packaged libraries rm -rf ${NAME}-${VERSION}/src/main/resources/org/xerial/snappy/native # Remove lib/ directory which was also stripped by Charles Plessy before and seems to be unneeded rm -rf ${NAME}-${VERSION}/lib GZIP="--best --no-name" tar --owner=root --group=root --mode=a+rX -czf "$NAME"_"$VERSION"~dfsg.orig.tar.gz "${NAME}-${VERSION}" rm -rf "${NAME}-$VERSION" debian/maven.properties0000644000000000000000000000017111735423505012416 0ustar # Include here properties to pass to Maven during the build. # For example: # maven.test.skip=true maven.test.skip=true debian/gbp.conf0000644000000000000000000000072611735423505010617 0ustar # This source package is manage in a Git repository with git-buildpackage. [DEFAULT] # use pristine-tar: pristine-tar = True [git-buildpackage] # call lintian after a successful build: postbuild = lintian -I --pedantic $GBP_CHANGES_FILE [git-import-orig] # import filter: filter = snappy-java-*/lib # filter out files from tarball passed to pristine tar: filter-pristine-tar = True [git-dch] # include 7 digits of the commit id in the changelog entry: id-length = 7 debian/patches/0000755000000000000000000000000011735423505010622 5ustar debian/patches/use_debian_packaged_libsnappy.patch0000644000000000000000000000115111735423505017637 0ustar Author: Andreas Tille Date: Sat, 28 Jan 2012 14:14:01 +0100 Description: Use Debian packaged libsnappy (hopefully) --- snappy-java-1.0.4.1.orig/Makefile +++ snappy-java-1.0.4.1/Makefile @@ -58,8 +58,8 @@ clean: rm -rf $(TARGET) -NATIVE_DIR:=src/main/resources/org/xerial/snappy/native/$(OS_NAME)/$(OS_ARCH) -NATIVE_TARGET_DIR:=$(TARGET)/classes/org/xerial/snappy/native/$(OS_NAME)/$(OS_ARCH) +NATIVE_DIR:=/usr/lib +NATIVE_TARGET_DIR:=$(TARGET)/usr/lib NATIVE_DLL:=$(NATIVE_DIR)/$(LIBNAME) snappy-jar-version:=snappy-java-$(shell xml_grep --text_only "/project/version" pom.xml) debian/patches/replace_silk-weaver_by_xml_grep.patch0000644000000000000000000000162711735423505020164 0ustar Description: Replace silk-weaver.jar by xml_grep from the xml-twig-tools package. No sources are included for silk-weaver.jar, it is therefore deleted from the Debian source package. Author: Charles Plessy Forwarded: why not ? diff --git a/Makefile b/Makefile index 7ad5cc6..2c65c55 100644 --- a/Makefile +++ b/Makefile @@ -62,7 +62,7 @@ NATIVE_DIR:=src/main/resources/org/xerial/snappy/native/$(OS_NAME)/$(OS_ARCH) NATIVE_TARGET_DIR:=$(TARGET)/classes/org/xerial/snappy/native/$(OS_NAME)/$(OS_ARCH) NATIVE_DLL:=$(NATIVE_DIR)/$(LIBNAME) -snappy-jar-version:=snappy-java-$(shell $(JAVA) -jar lib/silk-weaver.jar find 'project(artifactId, version)' pom.xml | grep snappy-java | awk '{ print $$2; }') +snappy-jar-version:=snappy-java-$(shell xml_grep --text_only "/project/version" pom.xml) native: $(SNAPPY_UNPACKED) $(NATIVE_DLL) snappy: native $(TARGET)/$(snappy-jar-version).jar debian/patches/replace_OSInfo_by_dpkg-architecture.patch0000644000000000000000000000266211735423505020660 0ustar Description: replace calls to OSInfo.class by calls to dpkg-architecture. The ‘lib’ directory is removed from this package, see ‘debian/README.source’. Author: Charles Plessy Forwarded: not-needed diff --git a/Makefile.common b/Makefile.common index f4a3fdd..991c5e0 100644 --- a/Makefile.common +++ b/Makefile.common @@ -11,17 +11,9 @@ JAVA := "$$JAVA_HOME/bin/java" JAVAC := "$$JAVA_HOME/bin/javac" JAVAH := "$$JAVA_HOME/bin/javah" -OSINFO_CLASS := org.xerial.snappy.OSInfo -OSINFO_PROG := lib/org/xerial/snappy/OSInfo.class - -## building OSInfo.java -#$(info compiling OSInfo.java) -#$(shell mkdir -p lib) -#$(shell $(JAVAC) src/main/java/org/sqlite/OSInfo.java -d lib) - -OS_NAME := $(shell $(JAVA) -cp lib $(OSINFO_CLASS) --os) -OS_ARCH := $(shell $(JAVA) -cp lib $(OSINFO_CLASS) --arch) -LIB_FOLDER := $(shell $(JAVA) -cp lib $(OSINFO_CLASS)) +OS_NAME := $(shell dpkg-architecture -qDEB_BUILD_ARCH_OS) +OS_ARCH := $(shell dpkg-architecture -qDEB_BUILD_ARCH) +LIB_FOLDER := $(OS_NAME)/$(OS_ARCH) # Windows uses different path separators ifeq ($(OS_NAME),Windows) @@ -41,7 +33,7 @@ endif # os=Default is meant to be generic unix/linux -known_os_archs := Linux-i386 Linux-amd64 Mac-i386 Mac-x86_64 Windows-x86 Windows-amd64 +known_os_archs := linux-i386 linux-amd64 Mac-i386 Mac-x86_64 Windows-x86 Windows-amd64 os_arch := $(OS_NAME)-$(OS_ARCH) ifeq (,$(findstring $(strip $(os_arch)),$(known_os_archs))) debian/patches/series0000644000000000000000000000016411735423505012040 0ustar replace_silk-weaver_by_xml_grep.patch replace_OSInfo_by_dpkg-architecture.patch use_debian_packaged_libsnappy.patch debian/links0000644000000000000000000000035611735423505010242 0ustar /usr/share/maven-repo/org/xerial/snappy/snappy-java/debian/snappy-java-debian.jar /usr/share/java/snappy-java.jar /usr/share/maven-repo/org/xerial/snappy/snappy-java/1.0.4.1/snappy-java-1.0.4.1.jar /usr/share/java/snappy-java-1.0.4.1.jar debian/maven.ignoreRules0000644000000000000000000000214211735423505012520 0ustar # Maven ignore rules - ignore some Maven dependencies and plugins # Format of this file is: # [group] [artifact] [type] [version] [classifier] [scope] # where each element can be either # - the exact string, for example org.apache for the group, or 3.1 # for the version. In this case, the element is simply matched # and left as it is # - * (the star character, alone). In this case, anything will # match and be left as it is. For example, using * on the # position of the artifact field will match any artifact id # All elements much match before a rule can be applied # Example rule: match jar with groupid= junit, artifactid= junit # and version starting with 3., this dependency is then removed # from the POM # junit junit jar s/3\\..*/3.x/ junit junit * * * * org.apache.maven.plugins maven-assembly-plugin * * * * org.apache.maven.plugins maven-javadoc-plugin * * * * org.apache.maven.plugins maven-release-plugin * * * * org.apache.maven.plugins maven-source-plugin * * * * org.apache.maven.wagon wagon-ssh-external * * * * org.codehaus.plexus plexus-classworlds * * * * org.xerial xerial-core * * * * debian/watch0000644000000000000000000000042611735423505010226 0ustar version=3 #http://googlecode.debian.net/p/snappy-java/snappy-java-(.*).tar.gz opts=dversionmangle=s/\~dfsg// \ http://code.google.com/p/snappy-java/downloads/list?can=1 \ .*/snappy-java-(\d[\d\.]+)\.(?:tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz))|zip) \ debian debian/get-orig-source debian/changelog0000644000000000000000000000024411735423505011045 0ustar snappy-java (1.0.4.1~dfsg-1) unstable; urgency=low * Initial release. (Closes: #636181) -- Charles Plessy Fri, 30 Mar 2012 23:34:09 +0200 debian/maven.rules0000644000000000000000000000171511735423505011361 0ustar # Maven rules - transform Maven dependencies and plugins # Format of this file is: # [group] [artifact] [type] [version] [classifier] [scope] # where each element can be either # - the exact string, for example org.apache for the group, or 3.1 # for the version. In this case, the element is simply matched # and left as it is # - * (the star character, alone). In this case, anything will # match and be left as it is. For example, using * on the # position of the artifact field will match any artifact id # - a regular expression of the form s/match/replace/ # in this case, elements that match are transformed using # the regex rule. # All elements much match before a rule can be applied # Example rule: match jar with groupid= junit, artifactid= junit # and version starting with 3., replacing the version with 3.x # junit junit jar s/3\\..*/3.x/ org.osgi s/core/org.osgi.core/ jar s/.*/debian/ * * org.xerial.snappy snappy-java bundle s/.*/debian/ * * debian/compat0000644000000000000000000000000211735423505010371 0ustar 8 debian/control0000644000000000000000000000214211735423505010575 0ustar Source: snappy-java Section: java Priority: optional Maintainer: Debian Java Maintainers Uploaders: Charles Plessy , Andreas Tille , Build-Depends: debhelper (>= 8), cdbs, default-jdk, maven-debian-helper (>= 1.4), xml-twig-tools, libsnappy-dev Build-Depends-Indep: libmaven-bundle-plugin-java Standards-Version: 3.9.3 Vcs-Git: git://git.debian.org/debian-med/snappy-java.git Vcs-Browser: http://git.debian.org/?p=debian-med/snappy-java.git Homepage: http://code.google.com/p/snappy-java/ Package: libsnappy-java Architecture: all Depends: ${misc:Depends}, ${maven:Depends}, ${shlib:Depends}, libsnappy1 Recommends: ${maven:OptionalDepends} Description: Snappy for Java, a fast compressor/decompresser Java port of Snappy, a fast compresser/decompresser written in C++, originally developed by Google. . Snappy's main target is very high-speed compression/decompression with reasonable compression size. So the compression ratio of snappy-java is modest and about the same as LZF (ranging 20%-100% according to the dataset).