2013-06-06 01:53:30 +02:00
|
|
|
################################################################################
|
2012-12-28 13:37:43 +01:00
|
|
|
#
|
|
|
|
# tvheadend
|
|
|
|
#
|
2013-06-06 01:53:30 +02:00
|
|
|
################################################################################
|
2012-12-28 13:37:43 +01:00
|
|
|
|
2014-09-03 21:48:11 +02:00
|
|
|
TVHEADEND_VERSION = ca742e00a7717787351e1a432ca9b41f93369d60
|
2014-05-05 19:20:33 +02:00
|
|
|
TVHEADEND_SITE = $(call github,tvheadend,tvheadend,$(TVHEADEND_VERSION))
|
2014-03-28 01:00:27 +01:00
|
|
|
TVHEADEND_LICENSE = GPLv3+
|
2014-06-03 08:51:55 +02:00
|
|
|
TVHEADEND_LICENSE_FILES = LICENSE.md
|
2014-03-28 01:00:27 +01:00
|
|
|
TVHEADEND_DEPENDENCIES = host-pkgconf host-python openssl
|
2012-12-28 13:37:43 +01:00
|
|
|
|
|
|
|
ifeq ($(BR2_PACKAGE_AVAHI),y)
|
2014-03-28 01:00:27 +01:00
|
|
|
TVHEADEND_DEPENDENCIES += avahi
|
2012-12-28 13:37:43 +01:00
|
|
|
endif
|
|
|
|
|
2014-06-11 15:02:06 +02:00
|
|
|
ifeq ($(BR2_PACKAGE_LIBICONV),y)
|
|
|
|
TVHEADEND_DEPENDENCIES += libiconv
|
|
|
|
endif
|
|
|
|
|
2014-03-28 01:00:27 +01:00
|
|
|
TVHEADEND_DEPENDENCIES += dtv-scan-tables
|
2012-12-28 13:37:43 +01:00
|
|
|
|
2013-12-04 01:08:41 +01:00
|
|
|
define TVHEADEND_CONFIGURE_CMDS
|
|
|
|
(cd $(@D); \
|
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
|
|
|
$(TARGET_CONFIGURE_ARGS) \
|
|
|
|
./configure \
|
|
|
|
--prefix=/usr \
|
|
|
|
--arch="$(ARCH)" \
|
|
|
|
--cpu="$(BR2_GCC_TARGET_CPU)" \
|
|
|
|
--python="$(HOST_DIR)/usr/bin/python" \
|
2014-06-09 12:56:22 +02:00
|
|
|
--disable-dvbscan \
|
2013-12-04 01:08:41 +01:00
|
|
|
)
|
|
|
|
endef
|
|
|
|
|
|
|
|
define TVHEADEND_BUILD_CMDS
|
|
|
|
$(MAKE) -C $(@D)
|
|
|
|
endef
|
|
|
|
|
|
|
|
define TVHEADEND_INSTALL_TARGET_CMDS
|
|
|
|
$(MAKE) -C $(@D) DESTDIR="$(TARGET_DIR)" install
|
|
|
|
endef
|
|
|
|
|
2012-12-28 13:37:43 +01:00
|
|
|
#----------------------------------------------------------------------------
|
|
|
|
# To run tvheadend, we need:
|
|
|
|
# - a startup script, and its config file
|
|
|
|
# - a default DB with a tvheadend admin
|
2013-04-12 09:14:19 +02:00
|
|
|
# - a non-root user to run as
|
2012-12-28 13:37:43 +01:00
|
|
|
define TVHEADEND_INSTALL_DB
|
2013-04-12 09:14:19 +02:00
|
|
|
$(INSTALL) -D -m 0600 package/tvheadend/accesscontrol.1 \
|
|
|
|
$(TARGET_DIR)/home/tvheadend/.hts/tvheadend/accesscontrol/1
|
|
|
|
chmod -R go-rwx $(TARGET_DIR)/home/tvheadend
|
2012-12-28 13:37:43 +01:00
|
|
|
endef
|
|
|
|
TVHEADEND_POST_INSTALL_TARGET_HOOKS = TVHEADEND_INSTALL_DB
|
|
|
|
|
|
|
|
define TVHEADEND_INSTALL_INIT_SYSV
|
|
|
|
$(INSTALL) -D package/tvheadend/etc.default.tvheadend $(TARGET_DIR)/etc/default/tvheadend
|
|
|
|
$(INSTALL) -D package/tvheadend/S99tvheadend $(TARGET_DIR)/etc/init.d/S99tvheadend
|
|
|
|
endef
|
|
|
|
|
2013-04-12 09:14:19 +02:00
|
|
|
define TVHEADEND_USERS
|
|
|
|
tvheadend -1 tvheadend -1 * /home/tvheadend - video TVHeadend daemon
|
|
|
|
endef
|
|
|
|
|
2013-12-04 01:08:41 +01:00
|
|
|
$(eval $(generic-package))
|