2 # Copyright (C) 2010-2016 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.bz2
15 PKG_SOURCE_URL
:=https
://github.com
/libusb
/libusb
/releases
/download
/v
$(PKG_VERSION
)
16 PKG_HASH
:=5977fc950f8d1395ccea9bd48c06b3f808fd3c2c961b44b0c2e6e29fc3a70a85
18 PKG_MAINTAINER
:= Felix Fietkau
<nbd@nbd.name
>
19 PKG_LICENSE
:=LGPL-2.1
-or-later
20 PKG_LICENSE_FILES
:=COPYING
21 PKG_CPE_ID
:=cpe
:/a
:libusb
:libusb
26 include $(INCLUDE_DIR
)/package.mk
28 define Package
/libusb-1.0
31 TITLE
:=A library for accessing Linux USB devices
32 DEPENDS
:=+libpthread
+librt
+libatomic
33 URL
:=https
://libusb.
info/
37 define Package
/libusb-1.0
/description
38 libusb is a C library that gives applications easy access to USB devices on
39 many different operating systems.
45 TITLE
:=fxload firmware loader
46 URL
:=https
://linux-hotplug.sourceforge.net
50 define Package
/fxload
/description
51 This program is conveniently able to download firmware into FX
, FX2
,
52 and FX2LP EZ-USB devices
, as well
as the original AnchorChips EZ-USB.
53 It is intended to be invoked by hotplug scripts when the unprogrammed
54 device appears on the bus.
57 TARGET_CFLAGS
+= $(FPIC
)
59 --enable-examples-build \
63 define Build
/InstallDev
64 $(INSTALL_DIR
) $(1)/usr
/include/libusb-1.0
65 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/libusb-1.0
/libusb.h
$(1)/usr
/include/libusb-1.0
/
66 $(INSTALL_DIR
) $(1)/usr
/lib
67 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libusb-1.0.
* $(1)/usr
/lib
/
68 $(INSTALL_DIR
) $(1)/usr
/lib
/pkgconfig
69 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/pkgconfig
/libusb-1.0.
pc $(1)/usr
/lib
/pkgconfig
/
72 define Package
/libusb-1.0
/install
73 $(INSTALL_DIR
) $(1)/usr
/lib
74 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libusb-1.0.so
* $(1)/usr
/lib
/
77 define Package
/fxload
/install
78 $(INSTALL_DIR
) $(1)/usr
/sbin
79 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/examples
/.libs
/fxload
$(1)/usr
/sbin
82 $(eval
$(call BuildPackage
,libusb-1.0
))
83 $(eval
$(call BuildPackage
,fxload
))