Merge pull request #8 from mstorchak/luaposix
[feed/packages.git] / libs / libftdi / Makefile
1 #
2 # Copyright (C) 2011-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
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=libftdi
11 PKG_VERSION:=0.20
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://www.intra2net.com/en/developer/libftdi/download/
16 PKG_MD5SUM:=355d4474e3faa81b485d6a604b06951f
17 PKG_MAINTAINER:=Álvaro Fernández Rojas <noltari@gmail.com>
18
19 PKG_INSTALL:=1
20
21 include $(INCLUDE_DIR)/package.mk
22 include $(INCLUDE_DIR)/cmake.mk
23
24 define Package/libftdi
25 SECTION:=libs
26 CATEGORY:=Libraries
27 DEPENDS:=+libusb-compat
28 TITLE:=Library to talk to FTDI chips
29 URL:=http://www.intra2net.com/en/developer/libftdi/
30 endef
31
32 define Package/libftdi/description
33 libFTDI - FTDI USB driver with bitbang mode
34 libFTDI is an open source library to talk to FTDI chips: FT232BM, FT245BM, FT2232C, FT2232H, FT4232H, FT2232D and FT245R, including the popular bitbang mode.
35 The library is linked with your program in userspace, no kernel driver required.
36 endef
37
38 define Build/InstallDev
39 $(INSTALL_DIR) $(1)/usr/include/
40 $(CP) $(PKG_INSTALL_DIR)/usr/include/ftdi.h $(1)/usr/include/
41 $(INSTALL_DIR) $(1)/usr/lib
42 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libftdi.{a,so} $(1)/usr/lib/
43 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libftdi.so* $(1)/usr/lib/
44 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig/
45 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libftdi.pc $(1)/usr/lib/pkgconfig/libftdi.pc
46 endef
47
48 define Package/libftdi/install
49 $(INSTALL_DIR) $(1)/usr/lib
50 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libftdi.so.* $(1)/usr/lib/
51 endef
52
53 $(eval $(call BuildPackage,libftdi))