2021-01-15 13:21:58 +00:00
|
|
|
{ lib, stdenv, fetchurl, libX11, libXext, libXcursor, libXrandr, libjack2, alsaLib
|
2018-11-27 19:44:18 +00:00
|
|
|
, mpg123, releasePath ? null }:
|
2018-05-24 09:04:17 +01:00
|
|
|
|
2021-01-15 13:21:58 +00:00
|
|
|
with lib;
|
2017-08-21 23:12:28 +01:00
|
|
|
|
|
|
|
# To use the full release version:
|
2019-12-13 19:41:20 +00:00
|
|
|
# 1) Sign into https://backstage.renoise.com and download the release version to some stable location.
|
2017-08-21 23:12:28 +01:00
|
|
|
# 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 {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "renoise";
|
2021-03-04 18:14:29 +00:00
|
|
|
version = "3.3.1";
|
2015-09-15 19:31:24 +01:00
|
|
|
|
|
|
|
src =
|
2018-08-20 20:11:29 +01:00
|
|
|
if stdenv.hostPlatform.system == "x86_64-linux" then
|
2019-04-24 04:48:22 +01:00
|
|
|
if releasePath == null then
|
2021-01-15 13:21:58 +00:00
|
|
|
fetchurl {
|
|
|
|
urls = [
|
|
|
|
"https://files.renoise.com/demo/Renoise_${urlVersion version}_Demo_Linux.tar.gz"
|
|
|
|
"https://web.archive.org/web/https://files.renoise.com/demo/Renoise_${urlVersion version}_Demo_Linux.tar.gz"
|
|
|
|
];
|
2021-03-04 18:14:29 +00:00
|
|
|
sha256 = "05baicks5dx278z2dx6h5n2vabsn64niwqssgys36xy469l9m1h0";
|
2021-01-15 13:21:58 +00:00
|
|
|
}
|
2015-09-15 19:31:24 +01:00
|
|
|
else
|
2021-01-15 13:21:58 +00:00
|
|
|
releasePath
|
2021-03-16 21:36:24 +00:00
|
|
|
else throw "Platform is not supported. Use instalation native to your platform https://www.renoise.com/";
|
2015-09-15 19:31:24 +01:00
|
|
|
|
2018-11-27 19:44:18 +00:00
|
|
|
buildInputs = [ alsaLib libjack2 libX11 libXcursor libXext libXrandr ];
|
2018-05-24 08:38:06 +01:00
|
|
|
|
2015-09-15 19:31:24 +01:00
|
|
|
installPhase = ''
|
|
|
|
cp -r Resources $out
|
|
|
|
|
|
|
|
mkdir -p $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
|
2021-03-16 21:36:24 +00:00
|
|
|
|
|
|
|
# Desktop item
|
|
|
|
mkdir -p $out/share/applications
|
|
|
|
cp -r Installer/renoise.desktop $out/share/applications/renoise.desktop
|
|
|
|
|
|
|
|
# Desktop item icons
|
|
|
|
mkdir -p $out/share/icons/hicolor/{48x48,64x64,128x128}/apps
|
2021-03-17 10:32:06 +00:00
|
|
|
cp Installer/renoise-48.png $out/share/icons/hicolor/48x48/apps/renoise.png
|
|
|
|
cp Installer/renoise-64.png $out/share/icons/hicolor/64x64/apps/renoise.png
|
|
|
|
cp Installer/renoise-128.png $out/share/icons/hicolor/128x128/apps/renoise.png
|
2018-11-27 19:44:18 +00:00
|
|
|
'';
|
2015-09-15 19:31:24 +01:00
|
|
|
|
2018-11-27 19:44:18 +00:00
|
|
|
postFixup = ''
|
|
|
|
patchelf \
|
|
|
|
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
|
|
|
|
--set-rpath ${mpg123}/lib:$out/lib \
|
|
|
|
$out/renoise
|
2020-09-25 21:35:01 +01:00
|
|
|
|
|
|
|
for path in $out/AudioPluginServer*; do
|
|
|
|
patchelf \
|
|
|
|
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
|
|
|
|
--set-rpath $out/lib \
|
|
|
|
$path
|
|
|
|
done
|
2021-03-16 21:36:24 +00:00
|
|
|
|
|
|
|
substituteInPlace $out/share/applications/renoise.desktop \
|
|
|
|
--replace Exec=renoise Exec=$out/bin/renoise
|
2015-09-15 19:31:24 +01:00
|
|
|
'';
|
|
|
|
|
2018-05-24 09:04:17 +01:00
|
|
|
meta = {
|
2016-06-20 11:53:46 +01:00
|
|
|
description = "Modern tracker-based DAW";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://www.renoise.com/";
|
2018-05-24 08:38:06 +01:00
|
|
|
license = licenses.unfree;
|
|
|
|
maintainers = [];
|
2019-12-13 19:41:20 +00:00
|
|
|
platforms = [ "x86_64-linux" ];
|
2015-09-15 19:31:24 +01:00
|
|
|
};
|
|
|
|
}
|