2015-11-08 08:52:04 +00:00
|
|
|
{ stdenv, fetchurl, makeWrapper
|
|
|
|
, libzen, libmediainfo , jre8
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "ums";
|
2020-01-17 23:31:09 +00:00
|
|
|
version = "9.1.0";
|
2015-11-08 08:52:04 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2020-01-17 23:31:09 +00:00
|
|
|
url = "mirror://sourceforge/project/unimediaserver/Official%20Releases/Linux/" + stdenv.lib.toUpper "${pname}-${version}" + ".tgz";
|
|
|
|
sha256 = "07wprjpwqids96v5q5fhwcxqlg8jp1vy585vl2nqbfi1vf5v294s";
|
2019-08-15 13:41:18 +01:00
|
|
|
name = "${pname}-${version}.tgz";
|
2015-11-08 08:52:04 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ makeWrapper ];
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
cp -a . $out/
|
|
|
|
mkdir $out/bin
|
|
|
|
mv $out/documentation /$out/doc
|
|
|
|
|
2020-01-17 23:31:09 +00:00
|
|
|
# ums >= 9.0.0 ships its own JRE in the package. if we remove it, the `UMS.sh`
|
|
|
|
# script will correctly fall back to the JRE specified by JAVA_HOME
|
|
|
|
rm -rf $out/linux/jre-x64 $out/linux/jre-x86
|
|
|
|
|
2015-11-08 08:52:04 +00:00
|
|
|
makeWrapper "$out/UMS.sh" "$out/bin/ums" \
|
2016-06-07 19:18:38 +01:00
|
|
|
--prefix LD_LIBRARY_PATH ":" "${stdenv.lib.makeLibraryPath [ libzen libmediainfo] }" \
|
2015-11-08 08:52:04 +00:00
|
|
|
--set JAVA_HOME "${jre8}"
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
2016-02-27 17:24:00 +00:00
|
|
|
description = "Universal Media Server: a DLNA-compliant UPnP Media Server";
|
2015-11-08 08:52:04 +00:00
|
|
|
license = stdenv.lib.licenses.gpl2;
|
|
|
|
platforms = stdenv.lib.platforms.linux;
|
|
|
|
maintainers = [ stdenv.lib.maintainers.thall ];
|
|
|
|
};
|
|
|
|
}
|