e0ed0207fa92923838573be5f755a2ff1e6875da
[openwrt.git] / package / utils / spidev_test / Makefile
1 #
2 # Copyright (C) 2009 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 include $(INCLUDE_DIR)/kernel.mk
10
11 PKG_NAME:=spidev-test
12 PKG_RELEASE:=$(LINUX_VERSION)
13
14 PKG_LICENSE:=GPL-2.0
15 PKG_LICENSE_FILES:=
16
17 include $(INCLUDE_DIR)/package.mk
18
19 define Package/spidev-test
20   SECTION:=utils
21   CATEGORY:=Utilities
22   DEPENDS:=+kmod-spi-dev
23   TITLE:=SPI testing utility
24   VERSION:=$(LINUX_VERSION)-$(PKG_RELEASE)
25   URL:=http://www.kernel.org
26   MAINTAINER:=Florian Fainelli <florian@openwrt.org>
27 endef
28
29 define Package/spidev-test/description
30   SPI testing utility.
31 endef
32
33 define Build/Prepare
34 endef
35
36 define Build/Compile
37         $(TARGET_CC) $(TARGET_CFLAGS) -o $(PKG_BUILD_DIR)/spidev_test \
38                 $(LINUX_DIR)/Documentation/spi/spidev_test.c
39 endef
40
41 define Package/spidev-test/install
42         $(INSTALL_DIR) $(1)/sbin
43         $(INSTALL_BIN) $(PKG_BUILD_DIR)/spidev_test $(1)/sbin/
44 endef
45
46 $(eval $(call BuildPackage,spidev-test))