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.

101 lines
2.5 KiB

  1. #
  2. # Copyright (C) 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:=tvheadend
  9. PKG_VERSION:=4.0.10
  10. PKG_RELEASE:=1
  11. PKG_SOURCE_SUBDIR:=$(PKG_NAME)
  12. PKG_SOURCE_VERSION:=v$(PKG_VERSION)
  13. PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.xz
  14. PKG_MIRROR_HASH:=afe42bcf683e8576ca8ccd4755ea308f79195e92f7c30fc5961973e238f49105
  15. PKG_SOURCE_PROTO:=git
  16. PKG_SOURCE_URL:=https://github.com/tvheadend/tvheadend.git
  17. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
  18. PKG_LICENSE:=GPL-3.0
  19. PKG_LICENSE_FILES:=LICENSE.md
  20. PKG_FIXUP:=autoreconf
  21. PKG_USE_MIPS16:=0
  22. include $(INCLUDE_DIR)/package.mk
  23. include $(INCLUDE_DIR)/nls.mk
  24. define Package/tvheadend
  25. SECTION:=multimedia
  26. CATEGORY:=Multimedia
  27. TITLE:=Tvheadend is a TV streaming server for Linux
  28. DEPENDS:=+libopenssl +librt +zlib +TVHEADEND_AVAHI_SUPPORT:libavahi-client $(ICONV_DEPENDS)
  29. URL:=https://tvheadend.org
  30. MAINTAINER:=Jan Čermák <jan.cermak@nic.cz>
  31. endef
  32. define Package/tvheadend/description
  33. Tvheadend is a TV streaming server and recorder for Linux, FreeBSD and Android
  34. supporting DVB-S, DVB-S2, DVB-C, DVB-T, ATSC, IPTV, SAT>IP and HDHomeRun as input sources.
  35. Tvheadend offers the HTTP (VLC, MPlayer), HTSP (Kodi, Movian) and SAT>IP streaming.
  36. endef
  37. define Package/tvheadend/config
  38. menu "Configuration"
  39. depends on PACKAGE_tvheadend
  40. source "$(SOURCE)/Config.in"
  41. endmenu
  42. endef
  43. ifeq ($(CONFIG_TVHEADEND_CWC_SUPPORT),)
  44. CONFIGURE_ARGS += --disable-cwc
  45. endif
  46. ifeq ($(CONFIG_TVHEADEND_LINUXDVB_SUPPORT),)
  47. CONFIGURE_ARGS += --disable-linuxdvb
  48. endif
  49. ifeq ($(CONFIG_TVHEADEND_DVBSCAN_SUPPORT),)
  50. CONFIGURE_ARGS += --disable-dvbscan
  51. endif
  52. ifeq ($(CONFIG_TVHEADEND_AVAHI_SUPPORT),)
  53. CONFIGURE_ARGS += --disable-avahi
  54. else
  55. CONFIGURE_ARGS += --enable-avahi
  56. endif
  57. CONFIGURE_ARGS += \
  58. --arch=$(ARCH) \
  59. --disable-dbus_1 \
  60. --disable-libav \
  61. --enable-bundle
  62. TARGET_CFLAGS += -Wno-error=pointer-compare
  63. define Build/Prepare
  64. $(call Build/Prepare/Default)
  65. echo 'Tvheadend $(shell echo $(PKG_SOURCE_VERSION) | sed "s/^v//")~openwrt$(PKG_RELEASE)' \
  66. > $(PKG_BUILD_DIR)/debian/changelog
  67. endef
  68. define Package/conffiles
  69. /etc/config/tvheadend
  70. endef
  71. define Package/tvheadend/install
  72. $(INSTALL_DIR) $(1)/etc/init.d
  73. $(INSTALL_BIN) ./files/tvheadend.init $(1)/etc/init.d/tvheadend
  74. $(INSTALL_DIR) $(1)/etc/config
  75. $(INSTALL_CONF) ./files/tvheadend.config $(1)/etc/config/tvheadend
  76. $(INSTALL_DIR) $(1)/usr/bin
  77. $(INSTALL_BIN) $(PKG_BUILD_DIR)/build.linux/tvheadend $(1)/usr/bin/
  78. endef
  79. $(eval $(call BuildPackage,tvheadend))