1
0

Makefile 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. #
  2. # Copyright (C) 2013-2016 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:=dump1090
  9. PKG_VERSION:=2016-11-26
  10. PKG_RELEASE:=1
  11. PKG_SOURCE_PROTO:=git
  12. PKG_SOURCE_URL:=https://github.com/mutability/dump1090.git
  13. PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
  14. PKG_SOURCE_VERSION:=fb63bdc2a61f0169b3c21b33bcdc99f202685b78
  15. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.xz
  16. PKG_MAINTAINER:=Álvaro Fernández Rojas <noltari@gmail.com>
  17. PKG_LICENSE:=GPL-2.0
  18. PKG_LICENSE_FILES:=COPYING LICENSE
  19. PKG_BUILD_DEPENDS:=librtlsdr
  20. include $(INCLUDE_DIR)/package.mk
  21. define Package/dump1090/Default
  22. SECTION:=utils
  23. CATEGORY:=Utilities
  24. TITLE:=Mode S decoder for the Realtek RTL2832U
  25. URL:=https://github.com/mutability/dump1090
  26. DEPENDS:=+libpthread
  27. endef
  28. define Package/dump1090
  29. $(call Package/dump1090/Default)
  30. TITLE+= (dump1090)
  31. DEPENDS+= +librtlsdr +uhttpd
  32. endef
  33. define Package/view1090
  34. $(call Package/dump1090/Default)
  35. TITLE+= (view1090)
  36. endef
  37. define Package/dump1090/description
  38. Dump1090 is a Mode S decoder specifically designed for RTLSDR devices.
  39. endef
  40. define Package/view1090/description
  41. View1090 is a Mode S messages viewer for dump1090 devices.
  42. endef
  43. MAKE_FLAGS += \
  44. CFLAGS="$(TARGET_CFLAGS)" \
  45. UNAME="Linux"
  46. define Package/dump1090/install
  47. $(INSTALL_DIR) $(1)/etc/init.d
  48. $(INSTALL_BIN) files/dump1090.init $(1)/etc/init.d/dump1090
  49. $(INSTALL_DIR) $(1)/etc/config
  50. $(INSTALL_CONF) files/dump1090.config $(1)/etc/config/dump1090
  51. $(INSTALL_DIR) $(1)/etc/uci-defaults
  52. $(INSTALL_DATA) files/dump1090.default $(1)/etc/uci-defaults/00_uhttpd_dump1090
  53. $(INSTALL_DIR) $(1)/usr/share/dump1090
  54. $(CP) $(PKG_BUILD_DIR)/public_html/* $(1)/usr/share/dump1090
  55. $(LN) /var/run/dump1090 $(1)/usr/share/dump1090/data
  56. $(INSTALL_DIR) $(1)/usr/bin
  57. $(INSTALL_BIN) $(PKG_BUILD_DIR)/dump1090 $(1)/usr/bin
  58. endef
  59. define Package/view1090/install
  60. $(INSTALL_DIR) $(1)/usr/bin
  61. $(INSTALL_BIN) $(PKG_BUILD_DIR)/view1090 $(1)/usr/bin
  62. endef
  63. $(eval $(call BuildPackage,dump1090))
  64. $(eval $(call BuildPackage,view1090))