9eb978fc6dda2ff93a021d7c5d2643fbe383e89c
[librecmc/package-feed.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_MAINTAINER:=Maxim Storchak <m.storchak@gmail.com>
21
22 PKG_LICENSE:=LGPL-2.1 GPL-2.0
23 PKG_LICENSE_FILES:=doc/COPYING doc/COPYING.LGPL
24
25 PKG_INSTALL:=1
26 PKG_FIXUP:=autoreconf
27
28 include $(INCLUDE_DIR)/package.mk
29
30 define Package/attr/Default
31   TITLE:=Extended attributes (xattr) manipulation
32   URL:=http://savannah.nongnu.org/projects/attr
33   SUBMENU:=Filesystem
34 endef
35
36 define Package/attr/Default/description
37   Extended attributes support
38 endef
39
40 define Package/attr
41 $(call Package/attr/Default)
42   SECTION:=utils
43   CATEGORY:=Utilities
44   TITLE+=utils
45   DEPENDS:=+libattr
46 endef
47
48 define Package/libattr
49 $(call Package/attr/Default)
50   SECTION:=libs
51   CATEGORY:=Libraries
52   TITLE+=library
53 endef
54
55 define Package/libattr/description
56 $(call Package/attr/Default/description)
57  This package provides libattr
58 endef
59
60 define Package/attr/description
61 $(call Package/attr/Default/description)
62  This package provides xattr manipulation utilities
63  - attr
64  - getfattr
65  - setfattr
66 endef
67
68 CONFIGURE_ARGS += --enable-static --enable-shared
69
70 define Package/attr/install
71         $(INSTALL_DIR) $(1)/usr/bin
72         $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
73 endef
74
75 define Package/libattr/install
76         $(INSTALL_DIR) $(1)/usr/lib
77         $(INSTALL_DIR) $(1)/etc
78         $(CP) $(PKG_INSTALL_DIR)/etc $(1)/
79         $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
80 endef
81
82 define Package/attr/conffiles
83 /etc/xattr.conf
84 endef
85
86 define Build/InstallDev
87         mkdir -p $(1)/usr/include
88         mkdir -p $(1)/usr/lib/pkgconfig
89         $(CP) $(PKG_INSTALL_DIR)/usr/{include,lib} $(1)/usr/
90 endef
91
92 $(eval $(call BuildPackage,attr))
93 $(eval $(call BuildPackage,libattr))