2018-05-24 09:04:17 +01:00
|
|
|
{ stdenv, fetchurl, libX11, libXext, libXcursor, libXrandr, libjack2, alsaLib, releasePath ? null }:
|
|
|
|
|
|
|
|
with stdenv.lib;
|
2017-08-21 23:12:28 +01:00
|
|
|
|
|
|
|
# To use the full release version:
|
|
|
|
# 1) Sign into https://backstage.renoise.com and download the appropriate (x86 or x86_64) version
|
|
|
|
# for your machine to some stable location.
|
|
|
|
# 2) Override the releasePath attribute to point to the location of the newly downloaded bundle.
|
|
|
|
# Note: Renoise creates an individual build for each license which screws somewhat with the
|
|
|
|
# use of functions like requireFile as the hash will be different for every user.
|
2018-05-24 08:38:06 +01:00
|
|
|
let
|
2018-05-24 09:04:17 +01:00
|
|
|
urlVersion = replaceStrings [ "." ] [ "_" ];
|
2017-08-21 23:12:28 +01:00
|
|
|
in
|
2018-05-24 08:38:06 +01:00
|
|
|
|
2015-09-15 19:31:24 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2018-05-24 08:38:06 +01:00
|
|
|
name = "renoise-${version}";
|
|
|
|
version = "3.1.0";
|
2015-09-15 19:31:24 +01:00
|
|
|
|
|
|
|
src =
|
2016-02-27 17:56:18 +00:00
|
|
|
if stdenv.system == "x86_64-linux" then
|
2017-08-21 23:12:28 +01:00
|
|
|
if builtins.isNull releasePath then
|
2015-09-15 19:31:24 +01:00
|
|
|
fetchurl {
|
2018-05-24 09:04:17 +01:00
|
|
|
url = "http://files.renoise.com/demo/Renoise_${urlVersion version}_Demo_x86_64.tar.bz2";
|
|
|
|
sha256 = "0pan68fr22xbj7a930y29527vpry3f07q3i9ya4fp6g7aawffsga";
|
2015-09-15 19:31:24 +01:00
|
|
|
}
|
|
|
|
else
|
2017-08-21 23:12:28 +01:00
|
|
|
releasePath
|
2016-02-27 17:56:18 +00:00
|
|
|
else if stdenv.system == "i686-linux" then
|
2017-08-21 23:12:28 +01:00
|
|
|
if builtins.isNull releasePath then
|
2015-09-15 19:31:24 +01:00
|
|
|
fetchurl {
|
2018-05-24 09:04:17 +01:00
|
|
|
url = "http://files.renoise.com/demo/Renoise_${urlVersion version}_Demo_x86.tar.bz2";
|
2018-05-24 08:38:06 +01:00
|
|
|
sha256 = "1lccjj4k8hpqqxxham5v01v2rdwmx3c5kgy1p9lqvzqma88k4769";
|
2015-09-15 19:31:24 +01:00
|
|
|
}
|
|
|
|
else
|
2017-08-21 23:12:28 +01:00
|
|
|
releasePath
|
|
|
|
else throw "Platform is not supported by Renoise";
|
2015-09-15 19:31:24 +01:00
|
|
|
|
2018-05-24 08:38:06 +01:00
|
|
|
buildInputs = [ libX11 libXext libXcursor libXrandr alsaLib libjack2 ];
|
|
|
|
|
2015-09-15 19:31:24 +01:00
|
|
|
installPhase = ''
|
|
|
|
cp -r Resources $out
|
|
|
|
|
|
|
|
mkdir -p $out/lib/
|
|
|
|
|
|
|
|
mv $out/AudioPluginServer* $out/lib/
|
|
|
|
|
|
|
|
cp renoise $out/renoise
|
|
|
|
|
|
|
|
for path in ${toString buildInputs}; do
|
|
|
|
ln -s $path/lib/*.so* $out/lib/
|
|
|
|
done
|
|
|
|
|
2016-04-30 21:56:43 +01:00
|
|
|
ln -s ${stdenv.cc.cc.lib}/lib/libstdc++.so.6 $out/lib/
|
2015-09-15 19:31:24 +01:00
|
|
|
|
|
|
|
mkdir $out/bin
|
|
|
|
ln -s $out/renoise $out/bin/renoise
|
|
|
|
|
|
|
|
patchelf --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) --set-rpath $out/lib $out/renoise
|
|
|
|
'';
|
|
|
|
|
2018-05-24 09:04:17 +01:00
|
|
|
meta = {
|
2016-06-20 11:53:46 +01:00
|
|
|
description = "Modern tracker-based DAW";
|
2015-09-15 19:31:24 +01:00
|
|
|
homepage = http://www.renoise.com/;
|
2018-05-24 08:38:06 +01:00
|
|
|
license = licenses.unfree;
|
|
|
|
maintainers = [];
|
|
|
|
platforms = [ "i686-linux" "x86_64-linux" ];
|
2015-09-15 19:31:24 +01:00
|
|
|
};
|
|
|
|
}
|