

Code: Select all
# Copyright 2016 Ivan The Viking, 1996-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
EAPI="5"
inherit eutils
DESCRIPTION="Universal Media Server is a DLNA-compliant UPnP Media Server."
HOMEPAGE="http://www.universalmediaserver.com/"
SRC_URI="mirror://sourceforge/project/unimediaserver/Official%20Releases/Linux/UMS-${PV}-Java8.tgz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86 ~arm64"
IUSE="multiuser +transcode tsmuxer"
DEPEND="app-arch/unzip"
RDEPEND=">=virtual/jre-1.8.0
media-libs/libmediainfo
media-libs/libzen
tsmuxer? ( media-video/tsmuxer )
transcode? ( media-video/mplayer[encode] )"Code: Select all
emerge --buildpkgonly net-misc/universalmediaserver::ivan
# Later, maybe even on a different machine after copying the tbz2
emerge --usepkgonly net-misc/universalmediaserver::ivanCode: Select all
S=${WORKDIR}/ums-${PV}
UMS_HOME=/opt/${PN}
src_prepare() {
if use multiuser; then
cat > ${PN} <<-EOF
#!/bin/sh
if [ ! -e ~/.${PN} ]; then
echo "Copying ${UMS_HOME} to ~/.${PN}"
cp -pPR "${UMS_HOME}" ~/.${PN}
fi
export UMS_HOME=\${HOME}/.${PN}
exec "\${UMS_HOME}/UMS.sh" "\$@"
EOF
else
cat > ${PN} <<-EOF
#!/bin/sh
export UMS_HOME=${UMS_HOME}
exec "\${UMS_HOME}/UMS.sh" "\$@"
EOF
fi
Code: Select all
cat > ${PN}.desktop <<-EOF
[Desktop Entry]
Name=Universal Media Server
GenericName=Media Server
Exec=${PN}
Icon=${PN}
Type=Application
Categories=Network;
EOF
unzip -j ums.jar resources/images/icon-{32,256}.png || die
}
src_install() {
dobin ${PN}
exeinto ${UMS_HOME}
doexe UMS.sh
insinto ${UMS_HOME}
doins -r ums.jar *.conf documentation plugins renderers *.xml
use tsmuxer && dosym /opt/tsmuxer/bin/tsMuxeR ${UMS_HOME}/linux/tsMuxeR
dodoc CHANGELOG.txt README.txt
newicon -s 32 icon-32.png ${PN}.png
newicon -s 256 icon-256.png ${PN}.png
domenu ${PN}.desktop
newconfd "${FILESDIR}/${PN}.confd" ${PN}
newinitd "${FILESDIR}/${PN}.initd" ${PN}
}
pkg_postinst() {
if [[ -z ${REPLACING_VERSIONS} ]]; then
ewarn "Don't forget to disable transcoding engines for software"
ewarn "that you don't have installed (such as having the VLC"
ewarn "transcoding engine enabled when you only have mencoder)."
elif use multiuser; then
ewarn "Remember to refresh the files in ~/.universalmediaserver/"
fi
}
Code: Select all
# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
EAPI="5"
inherit eutils
DESCRIPTION="Universal Media Server is a DLNA-compliant UPnP Media Server."
HOMEPAGE="http://www.universalmediaserver.com/"
SRC_URI="mirror://sourceforge/project/unimediaserver/Official%20Releases/Linux/UMS-${PV}-Java8.tgz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86 ~arm64"
IUSE="+libmediainfo +libzen multiuser +transcode tsmuxer"
DEPEND="app-arch/unzip"
RDEPEND=">=virtual/jre-1.8.0
libmediainfo? ( media-libs/libmediainfo )
libzen? ( media-libs/libzen )
tsmuxer? ( media-video/tsmuxer )
transcode? ( media-video/mplayer[encode] media-video/ffmpeg[encode] )"
S=${WORKDIR}/ums-${PV}
UMS_HOME=/opt/${PN}
src_prepare() {
if use multiuser; then
cat > ${PN} <<-EOF
#!/bin/sh
if [ ! -e ~/.${PN} ]; then
echo "Copying ${UMS_HOME} to ~/.${PN}"
cp -pPR "${UMS_HOME}" ~/.${PN}
fi
export UMS_HOME=\${HOME}/.${PN}
exec "\${UMS_HOME}/UMS.sh" "\$@"
EOF
else
cat > ${PN} <<-EOF
#!/bin/sh
export UMS_HOME=${UMS_HOME}
exec "\${UMS_HOME}/UMS.sh" "\$@"
EOF
fi
cat > ${PN}.desktop <<-EOF
[Desktop Entry]
Name=Universal Media Server
GenericName=Media Server
Exec=${PN}
Icon=${PN}
Type=Application
Categories=Network;
EOF
unzip -j ums.jar resources/images/icon-{32,256}.png || die
}
src_install() {
dobin ${PN}
exeinto ${UMS_HOME}
doexe UMS.sh
insinto ${UMS_HOME}
doins -r ums.jar *.conf documentation plugins renderers *.xml
use tsmuxer && dosym /opt/tsmuxer/bin/tsMuxeR ${UMS_HOME}/linux/tsMuxeR
dodoc CHANGELOG.txt README.txt
newicon -s 32 icon-32.png ${PN}.png
newicon -s 256 icon-256.png ${PN}.png
domenu ${PN}.desktop
newconfd "${FILESDIR}/${PN}.confd" ${PN}
newinitd "${FILESDIR}/${PN}.initd" ${PN}
}
pkg_postinst() {
if [[ -z ${REPLACING_VERSIONS} ]]; then
ewarn "Don't forget to disable transcoding engines for software"
ewarn "that you don't have installed (such as having the VLC"
ewarn "transcoding engine enabled when you only have mencoder)."
elif use multiuser; then
ewarn "Remember to refresh the files in ~/.config/UMS/"
fi
}





Ok, sorry for answering to my own question, but I found it ( and I post it since others might be looking for it, unless it is clear to everyone from some documentation i don't know about).lexflex wrote: However, I don't now how to configure/proceed. I could *probably* scan folders but I cant find any .conf file to say what folders to scan....
Basically my question is, when running headless: How /where do I do initial configuration?
Code: Select all
/home/<user>/.config/UMS


Thanks for the ebuild! It emerged fine but when I try to run I getIvan The Viking wrote:Hi All,
Added 6.6.0 to my snapshot of my local repo for those who don't want to use an overlay.
I dropped the ball on that release.
http://ivntheviking.bounceme.net/univer ... ver.tar.xz
Code: Select all
$ universalmediaserver
Exception in thread "main" java.lang.UnsupportedClassVersionError: net/pms/PMS : Unsupported major.minor version 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:803)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:442)
at java.net.URLClassLoader.access$100(URLClassLoader.java:64)
at java.net.URLClassLoader$1.run(URLClassLoader.java:354)
at java.net.URLClassLoader$1.run(URLClassLoader.java:348)Code: Select all
$ java-config -f -j -L
icedtea-bin-7
/opt/icedtea-bin-7.2.6.8/bin/jar
The following VMs are available for generation-2:
*) IcedTea JDK 7.2.6.8 [icedtea-bin-7]
2) IcedTea JDK 3.3.0 [icedtea-bin-8]
Code: Select all
Changes since 6.7.0:
General:
Fixed playback on Linux
Fixed support for OGA and 3GA files
Dependencies:
Updated MediaInfo to 0.7.96
Changes since 6.6.0:
General:
Added a button for the web interface
Expanded support for preventing sleep mode on Windows and macOS
Improved support for MusicBrainz
Improved support for CoverArtArchive
Improved support for images
Improved thumbnailing
Updated documentation
Improved DIDL-Lite implementation
Added support for more RealAudio formats
Fixed many bugs
Languages:
Synchronized translations with Crowdin
Renderers:
Added support for Chromecast Ultra
Added support for MXPlayer on Google Android
Added support for Microsoft Windows Media Player
Improved support for Chromecast
Improved support for Samsung 9 Series TVs
Improved support for Sony BRAVIA EX TVs
Improved detection of Onkyo TXNR7xx devices
Improved detection of Panasonic Viera ST60 TVs
Improved detection of Samsung J6400 TVs
Improved detection of Samsung JU6400 TVs
Improved detection of Samsung Galaxy S5 phones
Improved detection of Sony BRAVIA XE TVs
Dependencies:
Updated external-maven-plugin to 0.2
Updated FFmpeg to latest builds
Upgraded LogBack to version 1.2.3
Updated maven-surefire-plugin to 2.20
Updated MediaInfo to 0.7.94
Updated metadata-extractor to 2.10.1
Updated TwelveMonkeys ImageIO to version 3.3.1

Code: Select all
Changes since 6.7.1:
General:
Added support for WMA10
Improved splash screen timing and enabled it by default
Improved support for MediaInfo on non-Windows platforms
Improved CPU and memory logging
Improved detection of network speed
Updated comments in DefaultRenderer.conf
Updated documentation
Fixed trace logging on macOS
Fixed a crash on Windows 10
Languages:
Synchronized translations with Crowdin
Fixed Hebrew language support
Dependencies:
Updated FFmpeg
Updated JNA to 4.4.0
Updated Surefire to 2.20

Code: Select all
Changes since 6.7.2:
General:
Improved support for AVI and MJPEG
Improved general DLNA implementation
Fixed duplicate entries in transcode folders
Fixed logging in macOS
Fixed menu name in macOS
Renderers:
Added renderer configuration for conversion of 3D video to 2D
Added support for Fetch TV
Added support for Onkyo TXNR8xx
Improved support for Cambridge Audio Azur BD
Improved support for OPPO BDP
Improved support for Panasonic VIERA TXL32V10E
Improved support for Sony BRAVIA 5500 and EX TVs
Improved support for Sony SMP-N100
Improved support for Sony STR-DA5800ES
Fixed album art for Onkyo receivers (and probably others)
Fixed support for Xbox 360
Dependencies:
Updated MediaInfo to 0.7.97, which:
Improves support for HEVC (H.265), FLV, MKV, TIFF and more
Compatibility notes:
These releases work on all versions of Java 7 onwards.
The Windows releases work on Windows Vista onwards. We are working on supporting older versions.