Merge pull request #4429 from sdwalker/cleanup
[feed/packages.git] / utils / attr / Makefile
1 #
2 # Copyright (C) 2014-2016 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=attr
11 PKG_REV:=315af30d0c1a198dc662a90e6e6ae2456abf2489
12 PKG_VERSION:=20160302
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=http://git.savannah.gnu.org/r/attr.git
17 PKG_SOURCE_PROTO:=git
18 PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
19 PKG_SOURCE_VERSION:=$(PKG_REV)
20 PKG_MIRROR_HASH:=9ee01f36a81ccab5f003fc62afdcebfaa422c4f110d0a501e47617eb1c697768
21 PKG_MAINTAINER:=Maxim Storchak <m.storchak@gmail.com>
22
23 PKG_LICENSE:=LGPL-2.1 GPL-2.0
24 PKG_LICENSE_FILES:=doc/COPYING doc/COPYING.LGPL
25
26 PKG_INSTALL:=1
27 PKG_FIXUP:=autoreconf
28
29 include $(INCLUDE_DIR)/package.mk
30
31 define Package/attr/Default
32 TITLE:=Extended attributes (xattr) manipulation
33 URL:=http://savannah.nongnu.org/projects/attr
34 SUBMENU:=Filesystem
35 endef
36
37 define Package/attr/Default/description
38 Extended attributes support
39 endef
40
41 define Package/attr
42 $(call Package/attr/Default)
43 SECTION:=utils
44 CATEGORY:=Utilities
45 TITLE+=utils
46 DEPENDS:=+libattr
47 endef
48
49 define Package/libattr
50 $(call Package/attr/Default)
51 SECTION:=libs
52 CATEGORY:=Libraries
53 TITLE+=library
54 endef
55
56 define Package/libattr/description
57 $(call Package/attr/Default/description)
58 This package provides libattr
59 endef
60
61 define Package/attr/description
62 $(call Package/attr/Default/description)
63 This package provides xattr manipulation utilities
64 - attr
65 - getfattr
66 - setfattr
67 endef
68
69 CONFIGURE_ARGS += --enable-static --enable-shared
70
71 define Package/attr/install
72 $(INSTALL_DIR) $(1)/usr/bin
73 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
74 endef
75
76 define Package/libattr/install
77 $(INSTALL_DIR) $(1)/usr/lib
78 $(INSTALL_DIR) $(1)/etc
79 $(CP) $(PKG_INSTALL_DIR)/etc $(1)/
80 $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
81 endef
82
83 define Package/attr/conffiles
84 /etc/xattr.conf
85 endef
86
87 define Build/InstallDev
88 mkdir -p $(1)/usr/include
89 mkdir -p $(1)/usr/lib/pkgconfig
90 $(CP) $(PKG_INSTALL_DIR)/usr/{include,lib} $(1)/usr/
91 endef
92
93 $(eval $(call BuildPackage,attr))
94 $(eval $(call BuildPackage,libattr))