You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 lines
1.1 KiB

  1. #
  2. # Copyright (C) 2014-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. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=spi-tools
  9. PKG_VERSION:=0.8.3
  10. PKG_RELEASE:=1
  11. PKG_SOURCE_URL:=https://codeload.github.com/cpb-/spi-tools/tar.gz/$(PKG_VERSION)?
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  13. PKG_HASH:=1f29548187c5a57ca5902d260b01ca9ce04d93e4406ff77f317e1d6423ed3610
  14. PKG_MAINTAINER:=John Crispin <blogic@openwrt.org>
  15. PKG_LICENSE:=GPL-2.0
  16. PKG_LICENSE_FILES:=LICENSE
  17. PKG_FIXUP:=autoreconf
  18. include $(INCLUDE_DIR)/package.mk
  19. define Package/spi-tools
  20. SECTION:=utils
  21. CATEGORY:=Utilities
  22. TITLE:=Command line SPI tools
  23. endef
  24. define Build/Compile
  25. cd $(PKG_BUILD_DIR) ; \
  26. $(TARGET_CC) $(TARGET_CFLAGS) $(EXTRA_CFLAGS) -Wall -Werror -o spi-config src/spi-config.c ; \
  27. $(TARGET_CC) $(TARGET_CFLAGS) $(EXTRA_CFLAGS) -Wall -Werror -o spi-pipe src/spi-pipe.c
  28. endef
  29. define Package/spi-tools/install
  30. $(INSTALL_DIR) $(1)/usr/bin
  31. $(INSTALL_BIN) $(PKG_BUILD_DIR)/spi-config $(1)/usr/bin
  32. $(INSTALL_BIN) $(PKG_BUILD_DIR)/spi-pipe $(1)/usr/bin
  33. endef
  34. $(eval $(call BuildPackage,spi-tools))