2015-06-15 07:50:34 +01:00
|
|
|
{ stdenv, fetchurl, jre }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "subsonic-${version}";
|
2018-12-18 14:11:23 +00:00
|
|
|
version = "6.1.5";
|
2015-06-15 07:50:34 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://sourceforge/subsonic/subsonic-${version}-standalone.tar.gz";
|
2018-12-18 14:11:23 +00:00
|
|
|
sha256 = "1xz3flxd5hxcvvg1izzxpv5rxwb5zprk92vsgvmcniy7j7r66936";
|
2015-06-15 07:50:34 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
inherit jre;
|
|
|
|
|
|
|
|
# Create temporary directory to extract tarball into to satisfy Nix's need
|
|
|
|
# for a directory to be created in the unpack phase.
|
|
|
|
unpackPhase = ''
|
2018-12-18 14:11:23 +00:00
|
|
|
runHook preUnpack
|
2015-06-15 07:50:34 +01:00
|
|
|
mkdir ${name}
|
|
|
|
tar -C ${name} -xzf $src
|
2018-12-18 14:11:23 +00:00
|
|
|
runHook postUnpack
|
2015-06-15 07:50:34 +01:00
|
|
|
'';
|
|
|
|
installPhase = ''
|
2018-12-18 14:11:23 +00:00
|
|
|
runHook preInstall
|
2015-06-15 07:50:34 +01:00
|
|
|
mkdir $out
|
|
|
|
cp -r ${name}/* $out
|
2018-12-18 14:11:23 +00:00
|
|
|
runHook postInstall
|
2015-06-15 07:50:34 +01:00
|
|
|
'';
|
|
|
|
|
2018-12-18 14:11:23 +00:00
|
|
|
meta = with stdenv.lib; {
|
2015-06-15 07:50:34 +01:00
|
|
|
homepage = http://subsonic.org;
|
|
|
|
description = "Personal media streamer";
|
2018-12-18 14:11:23 +00:00
|
|
|
license = licenses.unfree;
|
|
|
|
maintainers = with maintainers; [ telotortium ];
|
|
|
|
platforms = platforms.unix;
|
2015-06-15 07:50:34 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
phases = ["unpackPhase" "installPhase"];
|
|
|
|
}
|