From bb0f09dc111e08cf1002d68f8d44519ada4a1f09 Mon Sep 17 00:00:00 2001 From: Marvin Steadfast Date: Fri, 6 Nov 2020 14:24:05 +0100 Subject: [PATCH] testing/upmpdcli: enable arm build and add openrc and config file --- testing/upmpdcli/APKBUILD | 18 +- testing/upmpdcli/upmpdcli.conf | 242 ++++++++++++++++++++++++++ testing/upmpdcli/upmpdcli.initd | 13 ++ testing/upmpdcli/upmpdcli.pre-install | 7 + 4 files changed, 275 insertions(+), 5 deletions(-) create mode 100644 testing/upmpdcli/upmpdcli.conf create mode 100644 testing/upmpdcli/upmpdcli.initd create mode 100644 testing/upmpdcli/upmpdcli.pre-install diff --git a/testing/upmpdcli/APKBUILD b/testing/upmpdcli/APKBUILD index f02b18a0bf0..00cb2c4ecd0 100644 --- a/testing/upmpdcli/APKBUILD +++ b/testing/upmpdcli/APKBUILD @@ -2,15 +2,18 @@ # Maintainer: Marvin Steadfast pkgname=upmpdcli pkgver=1.4.14 -pkgrel=0 +pkgrel=1 pkgdesc="upmpdcli is a UPnP Media Renderer front-end for MPD, the Music Player Daemon" url="http://www.lesbonscomptes.com/upmpdcli" -arch="all !armhf !armv7" +arch="all" license="LGPL-2.1-or-later" options="!check" makedepends="libupnpp-dev libmpdclient-dev libmicrohttpd-dev jsoncpp-dev" -subpackages="$pkgname-doc" -source="upmpdcli-$pkgver.tar.gz::http://www.lesbonscomptes.com/upmpdcli/downloads/upmpdcli-$pkgver.tar.gz" +subpackages="$pkgname-doc $pkgname-openrc" +install="$pkgname.pre-install" +source="$pkgname-$pkgver.tar.gz::http://www.lesbonscomptes.com/upmpdcli/downloads/upmpdcli-$pkgver.tar.gz + $pkgname.initd + $pkgname.conf" build() { ./configure --prefix=/usr --sysconfdir=/etc @@ -19,6 +22,11 @@ build() { package() { make DESTDIR="$pkgdir" install + + install -Dm755 "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname + install -Dm644 "$srcdir"/$pkgname.conf "$pkgdir"/etc/$pkgname.conf } -sha512sums="9084f60a4551fb94be915e6539d59a9ac070d55745c383b1f201c0c83262634c9e6fb353f66bb2232c493752805671b19057cbcec00c5ed128e19e1d0a037976 upmpdcli-1.4.14.tar.gz" +sha512sums="9084f60a4551fb94be915e6539d59a9ac070d55745c383b1f201c0c83262634c9e6fb353f66bb2232c493752805671b19057cbcec00c5ed128e19e1d0a037976 upmpdcli-1.4.14.tar.gz +4180397a4f0b5b0bda8b1a3d6a8b1ce0399f9b881b5618e52ddff4fd99dc3bedad240dc1dbe3abdc765b92fd172328aab9eedbe2d916ec7f728e7e18e080135c upmpdcli.initd +b6815c29e8c648fd7577f9137f1552dab96710e80458a19fc332c6382471c47fdc056c8e3e1353fc982610173e498b96df8fd18de93f5546773a22e02e58886d upmpdcli.conf" diff --git a/testing/upmpdcli/upmpdcli.conf b/testing/upmpdcli/upmpdcli.conf new file mode 100644 index 00000000000..5b6d0be363d --- /dev/null +++ b/testing/upmpdcli/upmpdcli.conf @@ -0,0 +1,242 @@ +#The XML tags in the comments are used to help produce the documentation +#from the sample/reference file, and not at all at run time, where +#comments are just comments. Edit at will. +#The command line options have higher priorities than the values in +#this file. + +# Upmpdcli configuration + + +# Upmpdcli general parameters + +# Log file name. +#logfilename = +# Log level. +#loglevel = 2 +# XML and other constant data storage directory. +#pkgdatadir=/usr/share/upmpdcli +# Name of lock file used to store the current process pid. +#pidfile = /var/run/upmpdcli.pid + +# UPnP network parameters + +# Network interface to use for UPnP. +#upnpiface = +# IP address to use for UPnP, alternative to using an interface name. +#upnpip = +# Port number used for UPnP. +#upnpport = + +# Media Renderer parameters + +# "Friendly Name" for the UPnP Media Renderer. +#friendlyname = UpMpd +# Enable UPnP AV services (0/1). +#upnpav = 1 +# Enable OpenHome services (0/1). +#openhome = 1 +# For upmpdcli version 1.3: enable Lumin compatibility mode (lose ohcredentials) (0/1). +#lumincompat = 0 +# Save the streaming services login parameters to disk. +#saveohcredentials = 1 +# Check that input format is supported. +#checkcontentformat = 1 +# Path to the openssl command +#opensslcmd = +# Path to the Renderer icon. +#iconpath = /usr/share/upmpdcli/icon.png +# Directory used to store cached data +#cachedir = /var/cache/upmpdcli +# Path to the presentation HTML document +#presentationhtml = /usr/share/upmpdcli/presentation.html + +# MPD parameters + +# Host MPD runs on. +#mpdhost = localhost +# IP port used by MPD +#mpdport = 6600 +# MPD password. +#mpdpassword = +# MPD connection timeout in milliseconds. +#mpdtimeoutms = 2000 +# Set if we own the MPD queue. +#ownqueue = 1 + +# Audio control hooks + +# Command to run when playback is about to begin. +#onstart = +# Command to run when MPD state switches to "PLAY". +#onplay = +# Command to run when MPD state switches to "PAUSE". +#onpause = +# Command to run when MPD state switches to "STOP". +#onstop = +# Command to run when the setstandby action is called. +#onstandby = +# Use external command to manage the the sound volume (0/1). +#externalvolumecontrol = +# Command to run for reading the sound volume. +#getexternalvolume = +# Command to run to set the volume. +#onvolumechange = + +# UPnP/AV tweaking + +# Automatically fake a Play command when track is set. +#avtautoplay = 0 + +# OpenHome parameters + +# The name of the room where the Product is located. +#ohproductroom = Main Room +# Path to an external file with radio definitions. +radiolist = /usr/share/upmpdcli/radio_scripts/radiolist.conf +# Manufacturer name. +#ohmanufacturername = UpMPDCli heavy industries Co. +# Manufacturer information. +#ohmanufacturerinfo = Such nice guys and gals +# URL for manufacturer web site. +#ohmanufacturerurl = http://www.lesbonscomptes.com/upmpdcli +# Uri for manufacturer’s logo. +#ohmanufacturerimageuri = +# Model name. +#ohmodelname = UpMPDCli UPnP-MPD gateway +# Model information. +#ohmodelinfo = +# URL for model web site. +#ohmodelurl = http://www.lesbonscomptes.com/upmpdcli +# Uri for model’s icon. +#ohmodelimageuri = +# User-visible product name. By default this is set to ModelName. +#ohproductname = Upmpdcli +# Product information. +#ohproductinfo = +# URL for product web site. This may be the UPnP presentation page. +#ohproducturl = +# Uri for product image. +#ohproductimageuri = +# Save queue metadata to disk (0/1). +#ohmetapersist = 1 +# Mimimum interval (Seconds) between two cache saves. +#ohmetasleep = 0 + +# Media Server general parameters + +# Friendly name for the Media Server (if enabled). +#msfriendlyname = +# Hostname/IP address used in proxy URLs. +#plgmicrohttphost = +# IP port for the tidal/qobuz/gmusic local HTTP service. +#plgmicrohttpport = 49149 +# Decide if we proxy (copy: fetch/serve), or redirect the streaming services streams. +#plgproxymethod = redirect + +# Google Music streaming service parameters + +# Google Music user name. +#gmusicuser = me@gmail.com +# Google Music password. +#gmusicpass = agoodpassword +# Google Music stream quality. +#gmusicquality = med +# Google Music device id. +#gmusicdeviceid = + +# Highresaudio streaming service parameters + +# Hra user name. +#hrauser = your hra user name +# Hra password. +#hrapass = your Hra password +# Hra language setting (en/de). +#hralang = en + +# Spotify streaming service parameters + +# Spotify user name. +#spotifyuser = me@some.place +# Spotify password. +#spotifypass = agoodpassword +# Spotify preferred bitrate: 160 (default), 320 or 96. +#spotifybitrate = 160 + +# Tidal streaming service parameters + +# Tidal user name. +#tidaluser = your tidal user name +# Tidal password. +#tidalpass = your Tidal password +# Tidal API token. +#tidalapitoken = thetoken +# Tidal stream quality. +#tidalquality = low + +# Qobuz streaming service parameters + +# Qobuz user name. +#qobuzuser = me@some.place +# Qobuz password. +#qobuzpass = agoodpassword +# Qobuz stream quality. +#qobuzformatid = 5 + +# Local Media Server parameters + +# Bogus user name variable. +#uprcluser = bugsbunny +# Plugin Title. +#uprcltitle = Local Music +# HTTP host and port for serving media files +#uprclhostport = +# uprcl Recoll index directory +#uprclconfdir = /var/cache/upmpdcli/uprcl +# Name of the user Recoll config additions file +#uprclconfrecolluser = /var/cache/upmpdcli/uprcl/recoll.conf.user +# Name of the Minim Server configuration file +#uprclminimconfig = +# Media directories +#uprclmediadirs = /tmp +# Path translations. +#uprclpaths = + +# Songcast Receiver parameters + +#Parameters for the Songcast modes. These are read by either/both the +#songcast and upmpdcli processes +# Log file name for sc2mpd (default stderr) +#sclogfilename = +# Log verbosity for sc2mpd. +#scloglevel = 3 +# sc2mpd play method (mpd/alsa). +#scplaymethod = mpd +# Port used by sc2mpd for MPD to connect to. +#schttpport = 8768 +# Alsa device used by sc2mpd for playing audio. +#scalsadevice = default +# sc2mpd resampling method. +#sccvttype = SRC_SINC_FASTEST +# Scale songcast stream based on mpd volume value +#scusempdvolume = 0 +# Path to sc2mpd. +#sc2mpd = +# Path to a screceiver state file. +#screceiverstatefile = + +# Songcast Sender parameters + +#Parameters tor the Sender/Receiver mode. Only does anything if +#scplaymethod is alsa +# !!Standard Songcast receivers only support PCM!! Codec to use for the network stream. +#scstreamcodec = +# Path to starter script +#scsenderpath = +# Scale the Songcast stream. +#scstreamscaled = 1 +# localhost port to be used by the auxiliary mpd. +#scsendermpdport = 6700 +# External sources script directory. +#scripts_dir = /usr/share/upmpdcli/src_scripts +# Grace period to wait for a script process to exit before it is forcely killed. +#scscriptgracesecs = 2 diff --git a/testing/upmpdcli/upmpdcli.initd b/testing/upmpdcli/upmpdcli.initd new file mode 100644 index 00000000000..00bc1e76cc2 --- /dev/null +++ b/testing/upmpdcli/upmpdcli.initd @@ -0,0 +1,13 @@ +#!/sbin/openrc-run +supervisor=supervise-daemon + +name="upmpdcli UPnP Media Renderer" +description="UPnP Media Renderer front-end for MPD, the Music Player Daemon" + +command=/usr/bin/upmpdcli +command_user=upmpdcli:upmpdcli + +depend() { + need net localmount + after firewall +} diff --git a/testing/upmpdcli/upmpdcli.pre-install b/testing/upmpdcli/upmpdcli.pre-install new file mode 100644 index 00000000000..a015483e17a --- /dev/null +++ b/testing/upmpdcli/upmpdcli.pre-install @@ -0,0 +1,7 @@ +#!/bin/sh + +addgroup -S upmpdcli 2>/dev/null + +adduser -S -D -h /var/lib/upmpdcli -s /sbin/nologin -G upmpdcli -g upmpdcli upmpdcli 2>/dev/null + +exit 0