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.

102 lines
2.3 KiB

  1. #
  2. # Copyright (C) 2014 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:=attr
  9. PKG_REV:=50fc862d69984089ce09138b3350ee7762290403
  10. PKG_VERSION:=20140610
  11. PKG_RELEASE:=1
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  13. PKG_SOURCE_URL:=git://git.sv.gnu.org/attr.git
  14. PKG_SOURCE_PROTO:=git
  15. PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
  16. PKG_SOURCE_VERSION:=$(PKG_REV)
  17. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
  18. PKG_MAINTAINER:=Maxim Storchak <m.storchak@gmail.com>
  19. PKG_INSTALL:=1
  20. include $(INCLUDE_DIR)/package.mk
  21. define Package/attr/Default
  22. TITLE:=Extended attributes (xattr) manipulation
  23. URL:=http://savannah.nongnu.org/projects/attr
  24. SUBMENU:=Filesystem
  25. endef
  26. define Package/attr/Default/description
  27. Extended attributes support
  28. endef
  29. define Package/attr
  30. $(call Package/attr/Default)
  31. SECTION:=utils
  32. CATEGORY:=Utilities
  33. TITLE+=utils
  34. DEPENDS:=+libattr
  35. endef
  36. define Package/libattr
  37. $(call Package/attr/Default)
  38. SECTION:=libs
  39. CATEGORY:=Libraries
  40. TITLE+=library
  41. KCONFIG:= \
  42. CONFIG_CIFS_XATTR=y \
  43. CONFIG_EXT4_FS_XATTR=y \
  44. CONFIG_JFFS2_FS_XATTR=y \
  45. CONFIG_REISERFS_FS_XATTR=y \
  46. CONFIG_SQUASHFS_XATTR=y \
  47. CONFIG_TMPFS_XATTR=y \
  48. endef
  49. define Package/libattr/description
  50. $(call Package/attr/Default/description)
  51. This package provides libattr
  52. endef
  53. define Package/attr/description
  54. $(call Package/attr/Default/description)
  55. This package provides xattr manipulation utilities
  56. - attr
  57. - getfattr
  58. - setfattr
  59. endef
  60. CONFIGURE_ARGS += --enable-static --enable-shared
  61. define Build/Prepare
  62. $(call Build/Prepare/Default)
  63. (cd $(PKG_BUILD_DIR); ./autogen.sh;);
  64. endef
  65. define Package/attr/install
  66. $(INSTALL_DIR) $(1)/usr/bin
  67. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
  68. endef
  69. define Package/libattr/install
  70. $(INSTALL_DIR) $(1)/usr/lib
  71. $(INSTALL_DIR) $(1)/etc
  72. $(CP) $(PKG_INSTALL_DIR)/etc $(1)/
  73. $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
  74. endef
  75. define Package/attr/conffiles
  76. /etc/xattr.conf
  77. endef
  78. define Build/InstallDev
  79. mkdir -p $(1)/usr/include
  80. mkdir -p $(1)/usr/lib/pkgconfig
  81. $(CP) -r $(PKG_INSTALL_DIR)/usr/{include,lib} $(1)/usr/
  82. endef
  83. $(eval $(call BuildPackage,attr))
  84. $(eval $(call BuildPackage,libattr))