[package] bsdiff: add package
authorFlorian Fainelli <florian@openwrt.org>
Tue, 13 Sep 2011 17:29:24 +0000 (17:29 +0000)
committerFlorian Fainelli <florian@openwrt.org>
Tue, 13 Sep 2011 17:29:24 +0000 (17:29 +0000)
Signed-off-by: Alexander Gordeev <lasaine@lvk.cs.msu.su>
SVN-Revision: 28230

utils/bsdiff/Makefile [new file with mode: 0644]
utils/bsdiff/patches/001-makefile.patch [new file with mode: 0644]

diff --git a/utils/bsdiff/Makefile b/utils/bsdiff/Makefile
new file mode 100644 (file)
index 0000000..2dab0ac
--- /dev/null
@@ -0,0 +1,42 @@
+#
+# Copyright (C) 2011 Alexander Gordeev <lasaine@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:=bsdiff
+PKG_VERSION:=4.3
+PKG_RELEASE:=1
+
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_SOURCE_URL:=http://www.daemonology.net/bsdiff
+PKG_MD5SUM:=e6d812394f0e0ecc8d5df255aa1db22a
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/bsdiff
+  SECTION:=utils
+  CATEGORY:=Utilities
+  DEPENDS:=+libbz2
+  URL:=http://www.daemonology.net/bsdiff
+  TITLE:=Tools for building and applying patches to binary files
+endef
+
+define Package/bsdiff/description
+ bsdiff and bspatch are tools for building and applying patches to binary
+ files. By using suffix sorting (specifically, Larsson and Sadakane's
+ qsufsort) and taking advantage of how executable files change, bsdiff
+ routinely produces binary patches 50-80% smaller than those produced by
+ Xdelta, and 15% smaller than those produced by .RTPatch (a $2750/seat
+ commercial patch tool).
+endef
+
+define Package/bsdiff/install
+       $(INSTALL_DIR) $(1)/usr/bin
+       $(INSTALL_BIN) $(PKG_BUILD_DIR)/bsdiff $(PKG_BUILD_DIR)/bspatch $(1)/usr/bin/
+endef
+
+$(eval $(call BuildPackage,bsdiff))
diff --git a/utils/bsdiff/patches/001-makefile.patch b/utils/bsdiff/patches/001-makefile.patch
new file mode 100644 (file)
index 0000000..45f3d6a
--- /dev/null
@@ -0,0 +1,11 @@
+diff --git a/Makefile b/Makefile
+index a522607..7da4463 100644
+--- a/Makefile
++++ b/Makefile
+@@ -10,6 +10,3 @@ bspatch:     bspatch.c
+ install:
+       ${INSTALL_PROGRAM} bsdiff bspatch ${PREFIX}/bin
+-.ifndef WITHOUT_MAN
+-      ${INSTALL_MAN} bsdiff.1 bspatch.1 ${PREFIX}/man/man1
+-.endif