You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

87 lines
2.0 KiB

  1. #
  2. # Copyright (C) 2007-2008 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=bzip2
  9. PKG_VERSION:=1.0.6
  10. PKG_RELEASE:=2
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=http://www.bzip.org/$(PKG_VERSION)
  13. PKG_MD5SUM:=00b516f4704d4a7cb50a1d97e6e8e15b
  14. PKG_MAINTAINER:=Steven Barth <cyrus@openwrt.org>
  15. PKG_LICENSE:=BZIP2
  16. PKG_LICENSE_FILES:=LICENSE
  17. include $(INCLUDE_DIR)/package.mk
  18. define Package/bzip2/Default
  19. SUBMENU:=Compression
  20. URL:=http://www.bzip.org/
  21. endef
  22. define Package/libbz2
  23. $(call Package/bzip2/Default)
  24. SECTION:=libs
  25. CATEGORY:=Libraries
  26. DEPENDS:=
  27. TITLE:=bzip2 library.
  28. endef
  29. define Package/libbz2/description
  30. bzip2 is a freely available, patent free, high-quality
  31. data compressor. This packages provides libbz2 library.
  32. endef
  33. define Package/bzip2
  34. $(call Package/bzip2/Default)
  35. SECTION:=utils
  36. CATEGORY:=Utilities
  37. DEPENDS:=+libbz2
  38. TITLE:=bzip2 is a compression utility.
  39. endef
  40. define Package/bzip2/description
  41. bzip2 is a freely available, patent free, high-quality
  42. data compressor. This package provides the binary.
  43. endef
  44. TARGET_CFLAGS += \
  45. $(FPIC) \
  46. $(TARGET_LDFLAGS)
  47. CONFIGURE_ARGS += --prefix=/usr
  48. MAKE_FLAGS += \
  49. -f Makefile-libbz2_so \
  50. CFLAGS="$(TARGET_CFLAGS)" \
  51. all
  52. define Build/InstallDev
  53. $(INSTALL_DIR) $(1)/usr/include
  54. $(CP) $(PKG_BUILD_DIR)/bzlib.h $(1)/usr/include/
  55. $(INSTALL_DIR) $(1)/usr/lib
  56. $(CP) $(PKG_BUILD_DIR)/libbz2.so.$(PKG_VERSION) $(1)/usr/lib/
  57. $(LN) libbz2.so.$(PKG_VERSION) $(1)/usr/lib/libbz2.so.1.0
  58. $(LN) libbz2.so.$(PKG_VERSION) $(1)/usr/lib/libbz2.so
  59. endef
  60. define Package/libbz2/install
  61. $(INSTALL_DIR) $(1)/usr/lib/
  62. $(CP) $(PKG_BUILD_DIR)/libbz2.so.$(PKG_VERSION) $(1)/usr/lib/
  63. $(LN) libbz2.so.$(PKG_VERSION) $(1)/usr/lib/libbz2.so.1.0
  64. endef
  65. define Package/bzip2/install
  66. $(INSTALL_DIR) $(1)/usr/bin/
  67. $(INSTALL_BIN) $(PKG_BUILD_DIR)/bzip2-shared $(1)/usr/bin/bzip2
  68. endef
  69. $(eval $(call BuildPackage,libbz2))
  70. $(eval $(call BuildPackage,bzip2))