Skip to content

Commit

Permalink
Lidarr: Update dotnet build for DSM 7.2 (SynoCommunity#5584)
Browse files Browse the repository at this point in the history
* Update dotnet build for DSM 7.2
* Add exclusions for ARMv7 archs
* Add build for x86 architecture
* Remove outdated mono version
  • Loading branch information
mreid-tt authored Apr 15, 2023
1 parent e6a7171 commit 80bcddb
Show file tree
Hide file tree
Showing 13 changed files with 73 additions and 151 deletions.
22 changes: 0 additions & 22 deletions cross/lidarr-mono/Makefile

This file was deleted.

1 change: 0 additions & 1 deletion cross/lidarr-mono/PLIST

This file was deleted.

3 changes: 0 additions & 3 deletions cross/lidarr-mono/digests

This file was deleted.

9 changes: 5 additions & 4 deletions cross/lidarr/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,21 @@ PKG_DIR = Lidarr

DEPENDS =

UNSUPPORTED_ARCHS = $(i686_ARCHS) $(ARMv7L_ARCHS) $(ARMv5_ARCHS) $(PPC_ARCHS)

HOMEPAGE = https://lidarr.audio/
COMMENT = Lidarr is a music collection manager for Usenet and BitTorrent users. It can monitor multiple RSS feeds for new tracks from your favorite artists and will grab, sort and rename them. It can also be configured to automatically upgrade the quality of files already downloaded when a better quality format becomes available.
LICENSE = GPLv3

INSTALL_TARGET = lidarr_install

# use digests with multiple files
PKG_DIST_ARCH_LIST = x64 arm arm64
PKG_DIST_ARCH_LIST = x86 x64 arm arm64

include ../../mk/spksrc.archs.mk
ifeq ($(findstring $(ARCH),$(i686_ARCHS)),$(ARCH))
PKG_DIST_ARCH = x86
else ifeq ($(findstring $(ARCH),$(x64_ARCHS)),$(ARCH))
PKG_DIST_ARCH = x64
ifeq ($(findstring $(ARCH),$(ARMv7_ARCHS)),$(ARCH))
else ifeq ($(findstring $(ARCH),$(ARMv7_ARCHS)),$(ARCH))
PKG_DIST_ARCH = arm
else ifeq ($(findstring $(ARCH),$(ARMv8_ARCHS)),$(ARCH))
PKG_DIST_ARCH = arm64
Expand Down
9 changes: 6 additions & 3 deletions cross/lidarr/digests
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
Lidarr.master.1.0.2.2592.linux-core-x64.tar.gz SHA1 62f5f7f418f9ff43f0ddf84e93305bee7e7406ac
Lidarr.master.1.0.2.2592.linux-core-x64.tar.gz SHA256 8ae236e204fbfd1159f7173872c77ecd61333d23ecc6a618e45fbbf085918f14
Lidarr.master.1.0.2.2592.linux-core-x64.tar.gz MD5 1435031348cd621343c188fd1e7cdfc7
Lidarr.master.1.0.2.2592.linux-core-arm.tar.gz SHA1 23504e911824674d651a60f9e018d62f3f00ca76
Lidarr.master.1.0.2.2592.linux-core-arm.tar.gz SHA256 dc59225da4490b40bea386d5ec5a305d43706447dbfea05f84505bc21b4425e5
Lidarr.master.1.0.2.2592.linux-core-arm.tar.gz MD5 a4f3c8228e219e60ea66004096963ff7
Lidarr.master.1.0.2.2592.linux-core-arm64.tar.gz SHA1 e49bb3a2b8ccbcd61321f742a1ed89b76ddebb90
Lidarr.master.1.0.2.2592.linux-core-arm64.tar.gz SHA256 c870286712de285ea6951fc0bf4107d0b8765eab8cf55c7a86e3434c4b38c325
Lidarr.master.1.0.2.2592.linux-core-arm64.tar.gz MD5 e3ba8cece9de4e48b0a0d9384e803b0a
Lidarr.master.1.0.2.2592.linux-core-x64.tar.gz SHA1 62f5f7f418f9ff43f0ddf84e93305bee7e7406ac
Lidarr.master.1.0.2.2592.linux-core-x64.tar.gz SHA256 8ae236e204fbfd1159f7173872c77ecd61333d23ecc6a618e45fbbf085918f14
Lidarr.master.1.0.2.2592.linux-core-x64.tar.gz MD5 1435031348cd621343c188fd1e7cdfc7
Lidarr.master.1.0.2.2592.linux-core-x86.tar.gz SHA1 31cd66297686064e645cf4f3bd96a561bcf1de16
Lidarr.master.1.0.2.2592.linux-core-x86.tar.gz SHA256 4e0a3828f9479c9b99210536903660839f38e5dd2764514d69b9661e0d087d00
Lidarr.master.1.0.2.2592.linux-core-x86.tar.gz MD5 0dbeb2b7ec46fcbd77b8cca87e6da6c8
14 changes: 8 additions & 6 deletions spk/lidarr/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,20 @@ SPK_VERS = $(shell date +%Y%m%d)
SPK_REV = 11
SPK_ICON = src/lidarr.png

DEPENDS = cross/lidarr cross/libstdc++ cross/sqlite
DEPENDS = cross/lidarr cross/libstdc++ cross/libicu cross/sqlite

UNSUPPORTED_ARCHS = $(DOTNET_UNSUPPORTED_ARCHS)
# Arch exclusions for dotnet 6.0
DOTNET_SERVARR_ARCHS = 1

MAINTAINER = Team Lidarr
MAINTAINER_URL = https://lidarr.audio/
DESCRIPTION = Lidarr is a music collection manager for Usenet and BitTorrent users. It can monitor multiple RSS feeds for new tracks from your favorite artists and will grab, sort and rename them. It can also be configured to automatically upgrade the quality of files already downloaded when a better quality format becomes available.
CHANGELOG = "1. Update Lidarr to v1.0.2.<br/>2. Use alternate TMP directory to provide enough space for internal updater.<br/>3. Enlarge the service start/stop timeout to 90 seconds.<br/>4. Avoid Lidarr downgrade on package update."
CHANGELOG = "1. Add dotnet dependencies for DSM 7.2.<br/>2. Fix package update.<br/>3. Add support for x86 (32-bit) architecture."
DISPLAY_NAME = Lidarr
HOMEPAGE = https://lidarr.audio/
LICENSE = GPLv3
LICENSE_FILE = $(WORK_DIR)/Lidarr/LICENSE.md
HELPURL = https://wiki.servarr.com/Lidarr_Troubleshooting
SUPPORTURL = https://lidarr.audio/\#support

STARTABLE = yes
SERVICE_USER = auto
Expand All @@ -32,6 +32,7 @@ WIZARDS_DIR = src/wizard/
POST_STRIP_TARGET = lidarr_extra_install

# use alternate TMPDIR as /tmp might be too small and not accessible on DSM >= 7.1.
# TMPDIR is used for lidarr built in backup and update
USE_ALTERNATE_TMPDIR = 1

include ../../mk/spksrc.spk.mk
Expand All @@ -41,6 +42,7 @@ PACKAGE_AUTHOR = [Team Lidarr](https://lidarr.audio/)

.PHONY: lidarr_extra_install
lidarr_extra_install:
install -m 755 -d $(STAGING_DIR)/var/.config/Lidarr
install -m 644 src/config.xml $(STAGING_DIR)/var/.config/Lidarr/config.xml
@$(MSG) "Install config.xml and provide package_info."
@install -m 755 -d $(STAGING_DIR)/var/.config/Lidarr
@install -m 644 src/config.xml $(STAGING_DIR)/var/.config/Lidarr/config.xml
@echo "PackageVersion=$(PACKAGE_VERSION)\nPackageAuthor=$(PACKAGE_AUTHOR)" > $(STAGING_DIR)/share/Lidarr/package_info
5 changes: 2 additions & 3 deletions spk/lidarr/src/config.xml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<Config>
<Branch>master</Branch>
<UpdateMechanism>BuiltIn</UpdateMechanism>
<UpdateAutomatically>True</UpdateAutomatically>
<LaunchBrowser>False</LaunchBrowser>
<Port>8686</Port>
<UpdateAutomatically>True</UpdateAutomatically>
<UpdateMechanism>BuiltIn</UpdateMechanism>
</Config>
69 changes: 0 additions & 69 deletions spk/lidarr/src/service-setup-mono.sh

This file was deleted.

18 changes: 13 additions & 5 deletions spk/lidarr/src/service-setup.sh
Original file line number Diff line number Diff line change
@@ -1,18 +1,22 @@

# Lidarr service setup
LIDARR="${SYNOPKG_PKGDEST}/share/Lidarr/bin/Lidarr"

# Lidarr uses custom Config and PID directories
HOME_DIR="${SYNOPKG_PKGVAR}"
CONFIG_DIR="${SYNOPKG_PKGVAR}/.config"
CONFIG_DIR="${HOME_DIR}/.config"
LIDARR_CONFIG_DIR="${CONFIG_DIR}/Lidarr"
PID_FILE="${LIDARR_CONFIG_DIR}/lidarr.pid"
CMD_ARGS="-nobrowser -data=${LIDARR_CONFIG_DIR}"

# Older installations have it in the wrong place for DSM 7
LEGACY_CONFIG_DIR="${SYNOPKG_PKGDEST}/.config"

# for DSM < 7 only:
GROUP="sc-download"
if [ ${SYNOPKG_DSM_VERSION_MAJOR} -lt 7 ]; then
GROUP="sc-download"
fi

SERVICE_COMMAND="env HOME=${HOME_DIR} LD_LIBRARY_PATH=${SYNOPKG_PKGDEST}/lib ${LIDARR}"
SERVICE_COMMAND="env HOME=${HOME_DIR} LD_LIBRARY_PATH=${SYNOPKG_PKGDEST}/lib ${LIDARR} ${CMD_ARGS}"
SVC_BACKGROUND=y
SVC_WAIT_TIMEOUT=90

Expand All @@ -21,7 +25,7 @@ service_postinst ()
echo "Set update required"
# Make Lidarr do an update check on start to avoid possible Lidarr
# downgrade when synocommunity package is updated
touch ${LIDARR_CONFIG_DIR}/update_required
touch ${LIDARR_CONFIG_DIR}/update_required 2>&1

if [ ${SYNOPKG_DSM_VERSION_MAJOR} -lt 7 ]; then
set_unix_permissions "${CONFIG_DIR}"
Expand Down Expand Up @@ -56,4 +60,8 @@ service_postupgrade ()
# prevent overwrite of updated package_info
rsync -aX --exclude=package_info ${SYNOPKG_TEMP_UPGRADE_FOLDER}/backup/share/ ${SYNOPKG_PKGDEST}/share 2>&1
fi

if [ ${SYNOPKG_DSM_VERSION_MAJOR} -lt 7 ]; then
set_unix_permissions "${SYNOPKG_PKGDEST}/share"
fi
}
18 changes: 9 additions & 9 deletions spk/lidarr/src/wizard/install_uifile
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
[{
"step_title": "Starting and updating Lidarr",
"items": [{
"desc": "The first time Lidarr is started it might take a few moments for the interface to become available!<br><br>Keep Lidarr up-to-date by using Lidarr's built-in updater.<br>Navigate to System>Updates in the Lidarr UI."
}]
},{
"step_title": "Attention! DSM Permissions",
"items": [{
"desc": "Permissions for all download-related packages are managed with the group <b>'sc-download'</b> in DSM.<br>Please read <a target=\"_blank\" href=\"https://github.com/SynoCommunity/spksrc/wiki/Permission-Management\">Permission Management</a> for details."
}]
"step_title": "Starting and updating Lidarr",
"items": [{
"desc": "The first time Lidarr is started it might take a few moments for the interface to become available!<br><br>Keep Lidarr up-to-date by using Lidarr's built-in updater.<br>Navigate to System>Updates in the Lidarr UI."
}]
}, {
"step_title": "DSM Permissions",
"items": [{
"desc": "Please read <a target=\"_blank\" href=\"https://github.com/SynoCommunity/spksrc/wiki/Permission-Management\">Permission Management</a> for details."
}]
}]
18 changes: 9 additions & 9 deletions spk/lidarr/src/wizard/install_uifile_fre
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
[{
"step_title": "Mettre à jour Lidarr",
"items": [{
"desc": "Au premier démarrage de Lidarr cela peut prendre un moment avant que l'interface ne soit disponible !<br><br>Garder Lidarr à jour en utilisant System>Updates dans l'interface Lidarr."
}]
},{
"step_title": "Attention! Permissions DSM",
"items": [{
"desc": "Les permissions de toutes les applications de téléchargement sont gérées par le groupe <b>'sc-download'</b> dans DSM.<br>Merci de lire <a target=\"_blank\" href=\"https://github.com/SynoCommunity/spksrc/wiki/Permission-Management\">Permission Management</a> pour plus de détails."
}]
"step_title": "Mettre à jour Lidarr",
"items": [{
"desc": "Au premier démarrage de Lidarr cela peut prendre un moment avant que l'interface ne soit disponible !<br><br>Garder Lidarr à jour en utilisant System>Updates dans l'interface Lidarr."
}]
}, {
"step_title": "Permissions DSM",
"items": [{
"desc": "Merci de lire <a target=\"_blank\" href=\"https://github.com/SynoCommunity/spksrc/wiki/Permission-Management\">Permission Management</a> pour plus de détails."
}]
}]
18 changes: 10 additions & 8 deletions spk/lidarr/src/wizard/upgrade_uifile
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
[{
"step_title": "Updating Lidarr",
"items": [{
"desc": "Keep Lidarr up-to-date by using Lidarr's built-in updater.<br>Navigate to System>Updates in the Lidarr UI."
}]
"step_title": "Updating Lidarr",
"items": [{
"desc": "This update is for additional libraries and DSM integration. It does not modify your current Lidarr version."
}, {
"desc": "Keep Lidarr up-to-date by using Lidarr's built-in updater.<br>Navigate to <b>System>Updates</b> in the Lidarr UI."
}]
}, {
"step_title": "Attention! DSM Permissions",
"items": [{
"desc": "Permissions for all download-related packages are managed with the group <b>'sc-download'</b> in DSM.<br>Please read <a target=\"_blank\" href=\"https://github.com/SynoCommunity/spksrc/wiki/Permission-Management\">Permission Management</a> for details."
}]
"step_title": "DSM Permissions",
"items": [{
"desc": "Please read <a target=\"_blank\" href=\"https://github.com/SynoCommunity/spksrc/wiki/Permission-Management\">Permission Management</a> for details."
}]
}]
20 changes: 11 additions & 9 deletions spk/lidarr/src/wizard/upgrade_uifile_fre
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
[{
"step_title": "Mettre à jour Lidarr",
"items": [{
"desc": "Garder Lidarr à jour en utilisant System>Updates dans l'interface Lidarr."
}]
},{
"step_title": "Attention! Permissions DSM",
"items": [{
"desc": "Les permissions de toutes les applications de téléchargement sont gérées par le groupe <b>'sc-download'</b> dans DSM.<br>Merci de lire <a target=\"_blank\" href=\"https://github.com/SynoCommunity/spksrc/wiki/Permission-Management\">Permission Management</a> pour plus de détails."
}]
"step_title": "Mettre à jour Lidarr",
"items": [{
"desc": "Cette mise à jour concerne les bibliothèques supplémentaires et l'intégration DSM. Il ne modifie pas votre version actuelle de Lidarr."
}, {
"desc": "Garder Lidarr à jour en utilisant <b>System>Updates</b> dans l'interface Lidarr."
}]
}, {
"step_title": "Permissions DSM",
"items": [{
"desc": "Merci de lire <a target=\"_blank\" href=\"https://github.com/SynoCommunity/spksrc/wiki/Permission-Management\">Permission Management</a> pour plus de détails."
}]
}]

0 comments on commit 80bcddb

Please sign in to comment.