Signed-off-by: Alexander Gordeev <lasa...@lvk.cs.msu.su>
---
 utils/xdelta3/Makefile                             |   42 ++++++++++++++++++++
 .../patches/001-decrease-default-window-size.patch |   19 +++++++++
 2 files changed, 61 insertions(+), 0 deletions(-)
 create mode 100644 utils/xdelta3/Makefile
 create mode 100644 utils/xdelta3/patches/001-decrease-default-window-size.patch

diff --git a/utils/xdelta3/Makefile b/utils/xdelta3/Makefile
new file mode 100644
index 0000000..c330000
--- /dev/null
+++ b/utils/xdelta3/Makefile
@@ -0,0 +1,42 @@
+#
+# Copyright (C) 2011 Alexander Gordeev <lasa...@lvk.cs.msu.su>
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=xdelta3
+PKG_VERSION:=3.0.0
+PKG_RELEASE:=1
+
+PKG_SOURCE:=xdelta$(PKG_VERSION).tar.gz
+PKG_SOURCE_URL:=http://xdelta.googlecode.com/files
+PKG_MD5SUM:=5fe038be3a266d2a7913e10d1cec6d88
+
+PKG_BUILD_DIR:=$(BUILD_DIR)/xdelta$(PKG_VERSION)
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/xdelta3
+  SECTION:=utils
+  CATEGORY:=Utilities
+  URL:=http://xdelta.org
+  TITLE:=A diff utility which works with binary files
+endef
+
+define Package/xdelta3/description
+ Xdelta3 is a set of tools designed to compute changes between binary
+ files. These changes (delta files) are similar to the output of the
+ "diff" program, in that they may be used to store and transmit only
+ the changes between files. The "delta files" that Xdelta3 manages are
+ stored in RFC3284 (VCDIFF) format.
+endef
+
+define Package/xdelta3/install
+       $(INSTALL_DIR) $(1)/usr/bin
+       $(INSTALL_BIN) $(PKG_BUILD_DIR)/xdelta3 $(1)/usr/bin/
+endef
+
+$(eval $(call BuildPackage,xdelta3))
diff --git a/utils/xdelta3/patches/001-decrease-default-window-size.patch 
b/utils/xdelta3/patches/001-decrease-default-window-size.patch
new file mode 100644
index 0000000..3fd134d
--- /dev/null
+++ b/utils/xdelta3/patches/001-decrease-default-window-size.patch
@@ -0,0 +1,19 @@
+diff --git a/xdelta3.h b/xdelta3.h
+index 5dafd8d..22bc37f 100644
+--- a/xdelta3.h
++++ b/xdelta3.h
+@@ -38,12 +38,12 @@
+  * buffer is used directly.
+  */
+ #ifndef XD3_DEFAULT_WINSIZE
+-#define XD3_DEFAULT_WINSIZE (1U << 23)
++#define XD3_DEFAULT_WINSIZE (1U << 16)
+ #endif
+ 
+ /* Default total size of the source window used in xdelta3-main.h */
+ #ifndef XD3_DEFAULT_SRCWINSZ
+-#define XD3_DEFAULT_SRCWINSZ (1U << 26)
++#define XD3_DEFAULT_SRCWINSZ (1U << 19)
+ #endif
+ 
+ /* When Xdelta requests a memory allocation for certain buffers, it
-- 
1.7.5.4

_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Reply via email to