[package] faifa: package libfaifa (#8506)
[packages.git] / net / faifa / Makefile
1 #
2 # Copyright (C) 2006-2012 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:=faifa
11 PKG_REV:=82
12 PKG_VERSION:=r$(PKG_REV)
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=https://svn.open-plc.org/trunk/
17 PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
18 PKG_SOURCE_VERSION:=$(PKG_REV)
19 PKG_SOURCE_PROTO:=svn
20
21 PKG_INSTALL:=1
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/faifa/Default
26   TITLE:=configure HomePlug 1.0/AV PLC devices
27   URL:=http://open-plc.org/
28 endef
29
30 define Package/libfaifa
31   $(call Package/faifa/Default)
32   TITLE+= (library)
33   SECTION:=libs
34   CATEGORY:=Libraries
35 endef
36
37 define Package/libfaifa/description
38   Faifa companion library.
39 endef
40
41 define Package/faifa
42   $(call Package/faifa/Default)
43   SECTION:=net
44   CATEGORY:=Network
45   DEPENDS:=+libpthread +libopenssl +libpcap +libfaifa
46   TITLE+= (command line)
47 endef
48
49 define Package/faifa/description
50   Faifa can configure any Intellon-based Power Line Communication device using
51   Intellon INT5000 and INT6000 series chips (6000 and 6300 chips). It supports all
52   Intellon-specific management and control frames as well as standard management
53   frames.
54 endef
55
56 TARGET_CFLAGS += $(FPIC)
57
58 MAKE_FLAGS += \
59         OS=LINUX \
60         SVN_REV=$(PKG_REV) \
61         CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)" \
62         LDFLAGS="$(TARGET_LDFLAGS)"
63
64 define Build/Configure
65         (cd $(PKG_BUILD_DIR); ./autogen.sh)
66         $(call Build/Configure/Default)
67 endef
68
69 define Package/faifa/install
70         $(INSTALL_DIR) $(1)/usr/bin
71         $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/faifa $(1)/usr/bin/
72 endef
73
74 define Package/libfaifa/install
75         $(INSTALL_DIR) $(1)/usr/lib
76         $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfaifa.so* $(1)/usr/lib
77 endef
78
79 $(eval $(call BuildPackage,faifa))
80 $(eval $(call BuildPackage,libfaifa))