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.

80 lines
1.9 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:=1
  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/libbz2
  19. SECTION:=libs
  20. CATEGORY:=Libraries
  21. DEPENDS:=
  22. TITLE:=bzip2 library.
  23. URL:=http://www.bzip.org/
  24. endef
  25. define Package/libbz2/description
  26. bzip2 is a freely available, patent free, high-quality
  27. data compressor. This packages provides libbz2 library.
  28. endef
  29. define Package/bzip2
  30. SECTION:=utils
  31. CATEGORY:=Utilities
  32. DEPENDS:=+libbz2
  33. TITLE:=bzip2 is a compression utility.
  34. URL:=http://www.bzip.org/
  35. endef
  36. define Package/bzip2/description
  37. bzip2 is a freely available, patent free, high-quality
  38. data compressor. This package provides the binary.
  39. endef
  40. TARGET_CFLAGS += $(FPIC)
  41. CONFIGURE_ARGS += --prefix=/usr
  42. MAKE_FLAGS += \
  43. -f Makefile-libbz2_so \
  44. CFLAGS="$(TARGET_CFLAGS)" \
  45. LDFLAGS="$(TARGET_LDLAGS)" \
  46. all
  47. define Build/InstallDev
  48. $(INSTALL_DIR) $(1)/usr/include
  49. $(CP) $(PKG_BUILD_DIR)/bzlib.h $(1)/usr/include/
  50. $(INSTALL_DIR) $(1)/usr/lib
  51. $(CP) $(PKG_BUILD_DIR)/libbz2.so.$(PKG_VERSION) $(1)/usr/lib/
  52. $(LN) libbz2.so.$(PKG_VERSION) $(1)/usr/lib/libbz2.so.1.0
  53. $(LN) libbz2.so.$(PKG_VERSION) $(1)/usr/lib/libbz2.so
  54. endef
  55. define Package/libbz2/install
  56. $(INSTALL_DIR) $(1)/usr/lib/
  57. $(CP) $(PKG_BUILD_DIR)/libbz2.so.$(PKG_VERSION) $(1)/usr/lib/
  58. $(LN) libbz2.so.$(PKG_VERSION) $(1)/usr/lib/libbz2.so.1.0
  59. endef
  60. define Package/bzip2/install
  61. $(INSTALL_DIR) $(1)/usr/bin/
  62. $(INSTALL_BIN) $(PKG_BUILD_DIR)/bzip2-shared $(1)/usr/bin/bzip2
  63. endef
  64. $(eval $(call BuildPackage,libbz2))
  65. $(eval $(call BuildPackage,bzip2))