Makefile (1926B)
1 # 2 # Copyright (C) 2011-2015 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:=4 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_LICENSE:=LGPL-2.0 20 PKG_LICENSE_FILES:=COPYING.LIB 21 22 PKG_INSTALL:=1 23 PKG_USE_MIPS16:=0 24 25 include $(INCLUDE_DIR)/package.mk 26 include $(INCLUDE_DIR)/cmake.mk 27 28 define Package/libftdi 29 SECTION:=libs 30 CATEGORY:=Libraries 31 DEPENDS:=+libusb-compat 32 TITLE:=Library to talk to FTDI chips 33 URL:=http://www.intra2net.com/en/developer/libftdi/ 34 endef 35 36 define Package/libftdi/description 37 libFTDI - FTDI USB driver with bitbang mode 38 libFTDI is an open source library to talk to FTDI chips: FT232BM, FT245BM, FT2232C, FT2232H, FT4232H, FT2232D and FT245R, including the popular bitbang mode. 39 The library is linked with your program in userspace, no kernel driver required. 40 endef 41 42 define Build/InstallDev 43 $(INSTALL_DIR) $(1)/usr/include/ 44 $(CP) $(PKG_INSTALL_DIR)/usr/include/ftdi.h $(1)/usr/include/ 45 $(INSTALL_DIR) $(1)/usr/lib 46 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libftdi.{a,so*} $(1)/usr/lib/ 47 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig/ 48 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libftdi.pc $(1)/usr/lib/pkgconfig/libftdi.pc 49 $(SED) \ 50 's,/usr/include,$$$${prefix}/include,g' \ 51 $(1)/usr/lib/pkgconfig/libftdi.pc 52 $(SED) \ 53 's,/usr/lib,$$$${prefix}/lib,g' \ 54 $(1)/usr/lib/pkgconfig/libftdi.pc 55 endef 56 57 define Package/libftdi/install 58 $(INSTALL_DIR) $(1)/usr/bin 59 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/libftdi-config $(1)/usr/bin/ 60 $(INSTALL_DIR) $(1)/usr/lib 61 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libftdi.so.* $(1)/usr/lib/ 62 endef 63 64 $(eval $(call BuildPackage,libftdi))