diff --git a/cross/jackett-mono/Makefile b/cross/jackett-mono/Makefile new file mode 100644 index 00000000000..a4dd60bb08c --- /dev/null +++ b/cross/jackett-mono/Makefile @@ -0,0 +1,23 @@ +PKG_NAME = Jackett +PKG_VERS = 0.17.474 +PKG_EXT = tar.gz +PKG_DIST_NAME = $(PKG_NAME).Binaries.Mono.$(PKG_EXT) +PKG_DIST_FILE = $(PKG_NAME)-$(PKG_VERS).$(PKG_EXT) +PKG_DIST_SITE = https://github.com/Jackett/Jackett/releases/download/v$(PKG_VERS) +PKG_DIR = jackett + +DEPENDS = + +HOMEPAGE = https://github.com/Jackett/Jackett +COMMENT = Jackett works as a proxy server: it translates queries from apps into tracker-site-specific http queries, parses the html response, then sends results back to the requesting software. Jackett is a single repository of maintained indexer scraping & translation logic - removing the burden from other apps. +LICENSE = GNU GPL v2 + +CONFIGURE_TARGET = nop +COMPILE_TARGET = nop +INSTALL_TARGET = jackett_install + +include ../../mk/spksrc.cross-cc.mk + +jackett_install: + mkdir -p $(STAGING_INSTALL_PREFIX)/share + tar -cf - -C $(WORK_DIR)/$(PKG_NAME) . | tar -xf - -C $(STAGING_INSTALL_PREFIX)/share diff --git a/cross/jackett-mono/PLIST b/cross/jackett-mono/PLIST new file mode 100644 index 00000000000..14f34d0c58e --- /dev/null +++ b/cross/jackett-mono/PLIST @@ -0,0 +1 @@ +rsc:share/ diff --git a/cross/jackett-mono/digests b/cross/jackett-mono/digests new file mode 100644 index 00000000000..9990e9347c8 --- /dev/null +++ b/cross/jackett-mono/digests @@ -0,0 +1,3 @@ +Jackett-0.17.474.tar.gz SHA1 dcb3c385c0eec22c493b791d9cc95863044576dd +Jackett-0.17.474.tar.gz SHA256 c21ddc15df5785ebd986ffb94626c362083c51848f0a831b9b047e77d5fab98d +Jackett-0.17.474.tar.gz MD5 26b6ea4d6c78c6e361b94157c5e2deec diff --git a/cross/jackett/Makefile b/cross/jackett/Makefile index c2980133304..ad9675f14a5 100644 --- a/cross/jackett/Makefile +++ b/cross/jackett/Makefile @@ -1,23 +1,22 @@ PKG_NAME = Jackett -PKG_VERS = 0.16.1340 +PKG_VERS = 0.17.474 PKG_EXT = tar.gz -PKG_DIST_NAME = $(PKG_NAME).Binaries.Mono.$(PKG_EXT) -PKG_DIST_FILE = $(PKG_NAME)-$(PKG_VERS).$(PKG_EXT) -PKG_DIST_SITE = https://github.com/Jackett/Jackett/releases/download/v$(PKG_VERS) -PKG_DIR = jackett +PKG_DIST_NAME = v$(PKG_VERS).$(PKG_EXT) +PKG_DIST_FILE = $(PKG_NAME)-dotnet-$(PKG_VERS).$(PKG_EXT) +PKG_DIST_SITE = https://github.com/Jackett/Jackett/archive +PKG_DIR = Jackett-$(PKG_VERS)/src -DEPENDS = +DOTNET_VERSION = 5.0 +DEPENDS = native/dotnet-sdk-$(DOTNET_VERSION) HOMEPAGE = https://github.com/Jackett/Jackett COMMENT = Jackett works as a proxy server: it translates queries from apps into tracker-site-specific http queries, parses the html response, then sends results back to the requesting software. Jackett is a single repository of maintained indexer scraping & translation logic - removing the burden from other apps. LICENSE = GNU GPL v2 -CONFIGURE_TARGET = nop -COMPILE_TARGET = nop -INSTALL_TARGET = jackett_install +DOTNET_OPTIMIZE = 1 +DOTNET_PACKAGE_NAME = Jackett.Server +DOTNET_OUTPUT_PATH = share +SET_VERSION = /p:AssemblyVersion=$(PKG_VERS) /p:FileVersion=$(PKG_VERS) /p:InformationalVersion=$(PKG_VERS) /p:Version=$(PKG_VERS) +DOTNET_BUILD_PROPERTIES += $(SET_VERSION) -include ../../mk/spksrc.cross-cc.mk - -jackett_install: - mkdir -p $(STAGING_INSTALL_PREFIX)/share/$(PKG_DIR) - tar -cf - -C $(WORK_DIR)/$(PKG_NAME) . | tar -xf - -C $(STAGING_INSTALL_PREFIX)/share/$(PKG_DIR) +include ../../mk/spksrc.cross-dotnet.mk diff --git a/cross/jackett/PLIST b/cross/jackett/PLIST index a701422790e..14f34d0c58e 100644 --- a/cross/jackett/PLIST +++ b/cross/jackett/PLIST @@ -1 +1 @@ -rsc:share/jackett +rsc:share/ diff --git a/cross/jackett/digests b/cross/jackett/digests index 8eadf1840d8..5bb16be6143 100644 --- a/cross/jackett/digests +++ b/cross/jackett/digests @@ -1,3 +1,3 @@ -Jackett-0.16.1340.tar.gz SHA1 ac3081fb01e86fe5074edf602eae76ce6bbfc229 -Jackett-0.16.1340.tar.gz SHA256 882c729bf2cfaa6b7b23a4f1029a4751a9ab11134bb98541b351307d48c1b318 -Jackett-0.16.1340.tar.gz MD5 aa0be138f04b1af6d37fc8fc266200e3 +Jackett-dotnet-0.17.474.tar.gz SHA1 66e671ce97cae5b27129a0c2647cc6162bd813dc +Jackett-dotnet-0.17.474.tar.gz SHA256 24342dd12d21968da0514b53e68ad5720c7222bf9c69aae7f8cbebdf07199ac0 +Jackett-dotnet-0.17.474.tar.gz MD5 61aa8d774851c3df2897cd1b77829f3c diff --git a/mk/spksrc.cross-dotnet-env.mk b/mk/spksrc.cross-dotnet-env.mk new file mode 100644 index 00000000000..5a5890b1a82 --- /dev/null +++ b/mk/spksrc.cross-dotnet-env.mk @@ -0,0 +1,97 @@ +# Configuration for dotnet build +# + +# NOTE: 32bit (x86) is not supported: +# https://github.com/dotnet/core/issues/5403 +# https://github.com/dotnet/core/issues/4595 +UNSUPPORTED_ARCHS += $(PPC_ARCHS) $(ARMv5_ARCHS) $(i686_ARCHS) $(ARMv7L_ARCHS) + +DOTNET_OS = linux +DOTNET_DEFAULT_VERSION = 3.1 + +ifeq ($(strip $(DOTNET_VERSION)),) + DOTNET_VERSION=$(DOTNET_DEFAULT_VERSION) +endif + +ifeq ($(strip $(DOTNET_FRAMEWORK)),) + DOTNET_FRAMEWORK=net$(DOTNET_VERSION) + ifeq ($(call version_lt, $(DOTNET_VERSION), 5.0),1) + DOTNET_FRAMEWORK=netcoreapp$(DOTNET_VERSION) + endif +endif +DOTNET_BUILD_ARGS += -f $(DOTNET_FRAMEWORK) + +# Define DOTNET_ARCH for compiler +ifeq ($(findstring $(ARCH),$(ARMv7_ARCHS)),$(ARCH)) + DOTNET_ARCH = arm +endif +ifeq ($(findstring $(ARCH),$(ARMv8_ARCHS)),$(ARCH)) + DOTNET_ARCH = arm64 +endif +ifeq ($(findstring $(ARCH),$(i686_ARCHS)),$(ARCH)) + DOTNET_ARCH = x86 +endif +ifeq ($(findstring $(ARCH),$(x64_ARCHS)),$(ARCH)) + DOTNET_ARCH = x64 +endif +ifeq ($(DOTNET_ARCH),) + # don't report error to use regular UNSUPPORTED_ARCHS logging + $(error Unsupported ARCH $(ARCH)) +endif + +ifeq ($(strip $(DOTNET_ROOT)),) + # dotnet sdk path + DOTNET_ROOT=$(WORK_DIR)/../../../native/dotnet-sdk-$(DOTNET_VERSION)/work-native +endif + +ifeq ($(strip $(DOTNET_ROOT_X86)),) + # dotnet sdk-32bit path + DOTNET_ROOT_X86="" + # DOTNET_ROOT_X86=$(WORK_DIR)/../../../native/dotnet-x86-sdk-$(DOTNET_VERSION)/work-native +endif + + +ifeq ($(strip $(NUGET_PACKAGES)),) + # cache nuget packages + # https://github.com/dotnet/sdk/commit/e5a9249418f8387602ee8a26fef0f1604acf5911 + NUGET_PACKAGES=$(DISTRIB_DIR)/nuget/packages +endif + +ifneq ($(strip $(DOTNET_NOT_RELEASE)),1) + DOTNET_BUILD_ARGS += --configuration Release +endif +ifneq ($(strip $(DOTNET_SHARED_FRAMEWORK)),1) + # Include .NET Core into package unless DOTNET_SHARED_FRAMEWORK is set to 1 + # https://docs.microsoft.com/en-us/dotnet/core/deploying/#publish-self-contained + DOTNET_BUILD_ARGS += --self-contained +endif + +ifeq ($(strip $(DOTNET_SINGLE_FILE)),1) + # package all dlls into a single binary + DOTNET_BUILD_PROPERTIES += "-p:PublishSingleFile=true" +endif + +DOTNET_BUILD_ARGS += --runtime $(DOTNET_OS)-$(DOTNET_ARCH) +DOTNET_BUILD_ARGS += --output="$(STAGING_INSTALL_PREFIX)/$(DOTNET_OUTPUT_PATH)" + +ifeq ($(strip $(DOTNET_OPTIMIZE)),1) +# PublishReadyToRun improve the startup time of your .NET Core application +# by compiling your application assemblies as ReadyToRun (R2R) format. +# R2R is a form of ahead-of-time (AOT) compilation. +# PublishTrimmed reduce the size of apps by analyzing IL and trimming unused assemblies. +# (not aware of reflection, needs testing, shaves ~10mb of binary) + DOTNET_BUILD_PROPERTIES += "-p:UseAppHost=true;PublishReadyToRun=true;PublishReadyToRunShowWarnings=true" +endif + +DOTNET_BUILD_ARGS += $(DOTNET_BUILD_PROPERTIES) + +# https://docs.microsoft.com/en-us/dotnet/core/tools/dotnet#environment-variables +# https://github.com/dotnet/docs/blob/master/docs/core/tools/dotnet.md#environment-variables +ENV += DOTNET_PACKAGE_NAME=$(DOTNET_PACKAGE_NAME) +ENV += DOTNET_ROOT=$(DOTNET_ROOT) +ENV += DOTNET_ROOT\(x86\)=$(DOTNET_ROOT_X86) +ENV += NUGET_PACKAGES=$(NUGET_PACKAGES) +ENV += PATH=$(DOTNET_ROOT)/:$$PATH +ENV += DOTNET_ARCH=$(DOTNET_ARCH) +ENV += DOTNET_OS=$(DOTNET_OS) +ENV += DOTNET_CLI_TELEMETRY_OPTOUT=1 diff --git a/mk/spksrc.cross-dotnet.mk b/mk/spksrc.cross-dotnet.mk new file mode 100644 index 00000000000..d0e8953220d --- /dev/null +++ b/mk/spksrc.cross-dotnet.mk @@ -0,0 +1,114 @@ +# Build dotnet programs +# +# prerequisites: +# - cross/module depends on native/dotnet only +# - module does not require kernel (REQUIRE_KERNEL) +# +# remarks: +# - Restriction for minimal DSM version is not supported (toolchains are not used for dotnet builds) +# - CONFIGURE_TARGET is not supported/bypassed +# - most content is taken from spksrc.go.mk and modified for dotnet build and install +# +# NOTE: Don't strip the self-contained binary! +# aka don't use 'bin' for the PLIST use 'rsc' instead. +# It *will* break the program. + +# Common makefiles +include ../../mk/spksrc.common.mk +include ../../mk/spksrc.directories.mk + +# Configure the included makefiles +URLS = $(PKG_DIST_SITE)/$(PKG_DIST_NAME) +NAME = $(PKG_NAME) +COOKIE_PREFIX = $(PKG_NAME)- +ifneq ($(PKG_DIST_FILE),) +LOCAL_FILE = $(PKG_DIST_FILE) +else +LOCAL_FILE = $(PKG_DIST_NAME) +endif +DIST_FILE = $(DISTRIB_DIR)/$(LOCAL_FILE) +DIST_EXT = $(PKG_EXT) + +ifneq ($(ARCH),) +ARCH_SUFFIX = -$(ARCH)-$(TCVERSION) +TC = syno$(ARCH_SUFFIX) +endif + +##### dotnet specific configurations +include ../../mk/spksrc.cross-dotnet-env.mk + +# avoid run of make configure & make install +CONFIGURE_TARGET = nop + +ifeq ($(strip $(COMPILE_TARGET)),) +COMPILE_TARGET = dotnet_compile_target +endif + +ifeq ($(strip $(INSTALL_TARGET)),) +INSTALL_TARGET = nop +endif + +# default dotnet publish: +# https://docs.microsoft.com/en-us/dotnet/core/tools/dotnet-publish +dotnet_compile_target: + @$(MSG) - Compile with dotnet publish + $(RUN) dotnet publish $(DOTNET_PACKAGE_NAME) $(DOTNET_BUILD_ARGS) + +##### + +ifneq ($(REQUIRE_KERNEL),) + @$(error dotnet modules cannot build when REQUIRE_KERNEL is set) +endif + +include ../../mk/spksrc.pre-check.mk + +include ../../mk/spksrc.cross-env.mk + +include ../../mk/spksrc.download.mk + +include ../../mk/spksrc.depend.mk + +checksum: download +include ../../mk/spksrc.checksum.mk + +extract: checksum depend +include ../../mk/spksrc.extract.mk + +patch: extract +include ../../mk/spksrc.patch.mk + +configure: patch +include ../../mk/spksrc.configure.mk + +compile: configure +include ../../mk/spksrc.compile.mk + +install: compile +include ../../mk/spksrc.install.mk + +plist: install +include ../../mk/spksrc.plist.mk + + +clean: + rm -fr work work-* + + +all: install plist + +### For make digests +include ../../mk/spksrc.generate-digests.mk + +### For make dependency-tree +include ../../mk/spksrc.dependency-tree.mk + +.PHONY: all-archs +all-archs: $(addprefix arch-,$(AVAILABLE_ARCHS)) + +#### + +arch-%: + @$(MSG) Building package for arch $* + -@MAKEFLAGS= $(MAKE) ARCH=$(basename $(subst -,.,$(basename $(subst .,,$*)))) TCVERSION=$(if $(findstring $*,$(basename $(subst -,.,$(basename $(subst .,,$*))))),$(DEFAULT_TC),$(notdir $(subst -,/,$*))) + +#### diff --git a/native/dotnet-sdk-3.1/Makefile b/native/dotnet-sdk-3.1/Makefile new file mode 100644 index 00000000000..bbfedd25448 --- /dev/null +++ b/native/dotnet-sdk-3.1/Makefile @@ -0,0 +1,24 @@ +PKG_NAME = dotnet-sdk-3.1 +# PKG_VERS = SDK 3.1.404 (v3.1.10 release) +# https://github.com/dotnet/core/blob/master/release-notes/3.1/3.1.9/3.1.9.md +PKG_VERS = 3.1.404 +PKG_EXT = tar.gz +# https://download.visualstudio.microsoft.com/download/pr/ec187f12-929e-4aa7-8abc-2f52e147af1d/56b0dbb5da1c191bff2c271fcd6e6394/dotnet-sdk-3.1.404-linux-x64.tar.gz +PKG_DIST_SITE = https://dotnetcli.azureedge.net/dotnet/Sdk/${PKG_VERS} +PKG_DIST_NAME = dotnet-sdk-$(PKG_VERS)-linux-x64.$(PKG_EXT) + +HOMEPAGE = https://dotnet.microsoft.com/ +COMMENT = A developer platform for building apps. +LICENSE = MIT + +CONFIGURE_TARGET = nop +COMPILE_TARGET = nop +INSTALL_TARGET = dotnet-install + +DOTNET_PACKAGES=$(DISTRIB_DIR)/nuget/packages + +include ../../mk/spksrc.native-cc.mk + +.PHONY: dotnet-install +dotnet-install: + mkdir -p $(DOTNET_PACKAGES) diff --git a/native/dotnet-sdk-3.1/digests b/native/dotnet-sdk-3.1/digests new file mode 100644 index 00000000000..b5ac7ecea2d --- /dev/null +++ b/native/dotnet-sdk-3.1/digests @@ -0,0 +1,3 @@ +dotnet-sdk-3.1.404-linux-x64.tar.gz SHA1 3aeee34359456c2ec303ecfde16e97a47da1196c +dotnet-sdk-3.1.404-linux-x64.tar.gz SHA256 6b8dd87de54bd855968325feec9cf57e2fb4b0dba745591d48d71eb2b8d7280d +dotnet-sdk-3.1.404-linux-x64.tar.gz MD5 2078ffff254a01597009c6f9b5e9df64 diff --git a/native/dotnet-sdk-5.0/Makefile b/native/dotnet-sdk-5.0/Makefile new file mode 100644 index 00000000000..768fc2ac53d --- /dev/null +++ b/native/dotnet-sdk-5.0/Makefile @@ -0,0 +1,21 @@ +PKG_NAME = dotnet-sdk-5.0 +PKG_VERS = 5.0.100 +PKG_EXT = tar.gz +PKG_DIST_SITE = https://dotnetcli.azureedge.net/dotnet/Sdk/${PKG_VERS} +PKG_DIST_NAME = dotnet-sdk-$(PKG_VERS)-linux-x64.$(PKG_EXT) + +HOMEPAGE = https://dotnet.microsoft.com/ +COMMENT = A developer platform for building apps. +LICENSE = MIT + +CONFIGURE_TARGET = nop +COMPILE_TARGET = nop +INSTALL_TARGET = dotnet-install + +DOTNET_PACKAGES=$(DISTRIB_DIR)/nuget/packages + +include ../../mk/spksrc.native-cc.mk + +.PHONY: dotnet-install +dotnet-install: + mkdir -p $(DOTNET_PACKAGES) diff --git a/native/dotnet-sdk-5.0/digests b/native/dotnet-sdk-5.0/digests new file mode 100644 index 00000000000..2437f570230 --- /dev/null +++ b/native/dotnet-sdk-5.0/digests @@ -0,0 +1,3 @@ +dotnet-sdk-5.0.100-linux-x64.tar.gz SHA1 ab456308344dc6a18c9c8b0a394c29dfcc19553a +dotnet-sdk-5.0.100-linux-x64.tar.gz SHA256 b8278fd20a7242e711ee46910c23804babf9b38a4c1b97e2a4d9c5155d21cbd2 +dotnet-sdk-5.0.100-linux-x64.tar.gz MD5 8e69311010323e389456f1451458be45 diff --git a/spk/jackett/Makefile b/spk/jackett/Makefile index db1d79e0642..2f69955dbb9 100644 --- a/spk/jackett/Makefile +++ b/spk/jackett/Makefile @@ -1,19 +1,17 @@ SPK_NAME = jackett -SPK_VERS = 0.16.1340 +SPK_VERS = 0.17.474 SPK_REV = 12 SPK_ICON = src/jackett.png DSM_UI_DIR = app -DEPENDS = cross/busybox cross/curl cross/$(SPK_NAME) -# depend on mono 5.4 for BTLS HttpWebClient support -SPK_DEPENDS = "mono>=5.4" +DEPENDS = cross/$(SPK_NAME) -MAINTAINER = m4tt075 +MAINTAINER = SynoCommunity DESCRIPTION = "Jackett works as a proxy server. It translates queries from apps into tracker-site-specific http queries, parses the html response, then sends results back to the requesting software. Jackett is a single repository of maintained indexer scraping and translation logic - removing the burden from other apps." RELOAD_UI = yes DISPLAY_NAME = Jackett STARTABLE = yes -CHANGELOG = "Add workaround for mono bug with armv5/88f6281" +CHANGELOG = "Update Jackett 17.474 and compile using .NET" HOMEPAGE = https://github.com/Jackett/Jackett LICENSE = GPLv2 @@ -28,14 +26,17 @@ SERVICE_PORT_TITLE = Jackett(HTTP) # Admin link ADMIN_PORT = $(SERVICE_PORT) -POST_STRIP_TARGET = jackett_extra_install - -REQUIRED_DSM = 5.0 -# no PPC support for mono, see cross/mono/Makefile for details UNSUPPORTED_ARCHS = $(PPC_ARCHS) -BUSYBOX_CONFIG = usrmng daemon -ENV += BUSYBOX_CONFIG="$(BUSYBOX_CONFIG)" +# Mono build for unsupported .NET archs +include ../../mk/spksrc.archs.mk +ifeq ($(findstring $(ARCH),$(ARMv5_ARCHS) $(i686_ARCHS) $(ARMv7L_ARCHS)),$(ARCH)) +DEPENDS = cross/$(SPK_NAME)-mono +SERVICE_SETUP = src/service-setup-mono.sh +CHANGELOG = "Update Jackett 17.474 and fix mono build (88f6281 and 88f6282)" +endif + +POST_STRIP_TARGET = jackett_extra_install include ../../mk/spksrc.spk.mk @@ -44,5 +45,3 @@ jackett_extra_install: install -m 755 -d $(STAGING_DIR)/var install -m 755 -d $(STAGING_DIR)/var/.config install -m 755 -d $(STAGING_DIR)/var/.config/Jackett - install -m 755 -d $(STAGING_DIR)/app - install -m 644 src/app/config $(STAGING_DIR)/app/config diff --git a/spk/jackett/src/service-setup-mono.sh b/spk/jackett/src/service-setup-mono.sh new file mode 100644 index 00000000000..e282fce8557 --- /dev/null +++ b/spk/jackett/src/service-setup-mono.sh @@ -0,0 +1,11 @@ +MONO_PATH="/var/packages/mono/target/bin" +PATH="${SYNOPKG_PKGDEST}/bin:${MONO_PATH}:${PATH}" +MONO="${MONO_PATH}/mono" +JACKETT="${SYNOPKG_PKGDEST}/share/JackettConsole.exe" + +# workaround for mono bug with armv5 (https://github.com/mono/mono/issues/12537) +if [ "$SYNOPKG_DSM_ARCH" == "88f6281" -o "$SYNOPKG_DSM_ARCH" == "88f6282" ]; then + MONO="MONO_ENV_OPTIONS='-O=-aot,-float32' ${MONO_PATH}/mono" +fi + +COMMAND="env HOME=${HOME_DIR} PATH=${PATH} LD_LIBRARY_PATH=${SYNOPKG_PKGDEST}/lib ${MONO} ${JACKETT} --PIDFile ${PID_FILE}" diff --git a/spk/jackett/src/service-setup.sh b/spk/jackett/src/service-setup.sh index c1ac4baccc8..c6025d71d66 100644 --- a/spk/jackett/src/service-setup.sh +++ b/spk/jackett/src/service-setup.sh @@ -1,38 +1,7 @@ -# Package specific behaviors -# Sourced script by generic installer and start-stop-status scripts +PATH="${SYNOPKG_PKGDEST}/bin:${PATH}" +JACKETT="${SYNOPKG_PKGDEST}/share/jackett" +HOME_DIR="${SYNOPKG_PKGDEST}/var" -service_prestart () -{ - # Replace generic service startup - MONO_PATH="/var/packages/mono/target/bin" - PATH="${SYNOPKG_PKGDEST}/bin:${MONO_PATH}:${PATH}" - MONO="${MONO_PATH}/mono" - JACKETT="${SYNOPKG_PKGDEST}/share/${SYNOPKG_PKGNAME}/JackettConsole.exe" - HOME_DIR="${SYNOPKG_PKGDEST}/var" - - # workaround for mono bug with armv5 (https://github.com/mono/mono/issues/12537) - if [ "$SYNOPKG_DSM_ARCH" == "88f6281" -o "$SYNOPKG_DSM_ARCH" == "88f6282" ]; then - MONO="MONO_ENV_OPTIONS='-O=-aot,-float32' ${MONO_PATH}/mono" - fi - - echo "Starting Jackett as user ${EFF_USER}" >> ${LOG_FILE} - COMMAND="env HOME=${HOME_DIR} PATH=${PATH} LD_LIBRARY_PATH=${SYNOPKG_PKGDEST}/lib ${MONO} ${JACKETT} --PIDFile ${PID_FILE}" - - if [ $SYNOPKG_DSM_VERSION_MAJOR -lt 6 ]; then - su ${EFF_USER} -s /bin/sh -c "${COMMAND}" >> ${LOG_FILE} 2>&1 & - else - ${COMMAND} >> ${LOG_FILE} 2>&1 & - fi -} - -service_postinst () -{ - # Discard legacy obsolete busybox user account - BIN=${SYNOPKG_PKGDEST}/bin - $BIN/busybox --install $BIN - $BIN/delgroup "${USER}" "users" >> ${INST_LOG} - $BIN/deluser "${USER}" >> ${INST_LOG} - - echo "service_postinst ${SYNOPKG_PKG_STATUS}" >> ${INST_LOG} -} +SERVICE_COMMAND="env HOME=${HOME_DIR} PATH=${PATH} LD_LIBRARY_PATH=${SYNOPKG_PKGDEST}/lib ${JACKETT} --PIDFile ${PID_FILE}" +SVC_BACKGROUND=y